2024-07-15 12:47 AM
Hello,
After updating STM32CubeIDE to version 1.16, starting a debugging session doesn't load program into the STM32L5 target and jumps directly to the reset Handler.
I tried programming the bin file using STM32CubeProgrammer and it works well.
However, erasing the FLASH using STM32CubeProgrammer and launching a debug session then reading back the FLASH using STM32CubeProgrammer shows that it's empty.
Im trying to load the program to the address 0x08020000, here is the memories definition.
/* Memories definition */
MEMORY
{
RAM (xrw) : ORIGIN = 0x20000000, LENGTH = 192K
SRAM2 (xrw) : ORIGIN = 0x20030000, LENGTH = 64K
BOOTLOADER (rx) : ORIGIN = 0x08000000, LENGTH = 128K
FLASH (rx) : ORIGIN = 0x08020000, LENGTH = 352K
}
2024-07-15 02:54 AM
@ABouk.1 wrote:starting a debugging session doesn't load program into the STM32L5 target
Is downloading enabled in your Debug Config:
2024-07-15 04:47 AM
2024-07-15 08:11 AM
Hello @ABouk.1 ,
Which file have you modified? Is it the STM32xxxx_FLASH.ld or have you create a new one?
If so, have you updated the project settings to select the proper linker script ?
2024-07-15 08:16 AM
Hi @SMarie ,
I modified the STM32L562VETXQ_FLASH.ld and selected it in the linker script (in projet properties) as you can see in the attached screenshot.
In OpenOCD the program is loaded before debugging but in GDB server mode it jumps directly to debugging without erasing/programming the flash.