STM32 UART boot-loader Go command is unclear AN3155
Hello,
I am implemented UART bootloader on my windows controlled test bench. All is great and working, but some uncertain exist with jump command.
Its says in app note:
jumps to the memory location programmed in the received ‘address + 4’
(corresponding to the address of the application reset handler).
For example if the received address is 0x0800 0000, the bootloader jumps to the
memory location programmed at address 0x0800 0004.
In general, the host must send the base address where the application to jump to is
programmed.My understanding is that my program starts at 0x0800 0000. So I should jump to 0x0800000-4 ?
If I do so, I get NACK, and nothing happens. But if I jump to 0x0800000, all it's good. My program seems to be running, but based on application note, it means I am jumping to 0x08000004 address
So what is in that first 4 bytes of data at the start of the flash It says reset handler, so I suppose to jump over this point ? So this is why I am jumping just a bit further into flash, since bootloader already does this for me ?
In app note:
-> initializes the main stack pointer of the user applicationAny insight will be welcome !
