Loading...
 

Zephyr project on STM32

   Zephyr Workbench, a VSCode extension to manage Zephyr on STM32.
It enables users to easily create, develop, and debug Zephyr applications.
Main features:
  • Install host dependencies.
  • Import toolchain and SDK.
  • Create, configure, build and manage apps.
  • Debug STM32.
You can directly download it from the VSCode marketplace
For more details, visit the Zephyr Workbench

System Workbench for STM32


Issue on debug session NUCLEO-F091RC

Hi,
I have a NUCLEO-F091RC and “System Workbench for STM32 AC6 Tools based on Eclipse”. I created a new project from an existing BOOTLOADER. I compile and build all correctly, but when I start the debug session the program stops all with this information:

Error in final launch sequence
Failed to execute MI command:
load C:\Users\andreacavazzoni\Desktop\FW_AN\en.stm32cubef0\STM32Cube_FW_F0_V1.9.0\Projects\STM32F091RC-Nucleo\Examples\GPIO\GPIO_IOToggle\SW4STM32\STM32F091RC-Nucleo_BTLD\Debug\STM32F091RC-Nucleo_BTLD.elf

Error message from debugger back end:
Load failed
Load failed

How can I fix it?
Thank you.
Andrea Cavazzoni

I adding information from console in debug mode before error appears:

Open On-Chip Debugger 0.10.0-dev-00004-gcef2a8c-dirty (2017-08-31-14:07)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
srst_only separate srst_nogate srst_open_drain connect_assert_srst
Info : The selected transport took over low-level target control. The results might differ compared to plain JTAG/SWD
adapter speed: 950 kHz
adapter_nsrst_delay: 100
Info : tcl server disabled
Info : telnet server disabled
Info : clock speed 950 kHz
Info : STLINK v2 JTAG v29 API v2 M v18 VID 0x0483 PID 0x374B
Info : using stlink api v2
Info : Target voltage: 3.271287
Info : Stlink adapter speed set to 950 kHz
Info : STM32F091RCTx.cpu: hardware has 4 breakpoints, 2 watchpoints
Info : accepting ‘gdb’ connection on tcp/3333
Info : Stlink adapter speed set to 950 kHz
adapter speed: 950 kHz
STM32F091RCTx.cpu: target state: halted
target halted due to debug-request, current mode: Thread
xPSR: 0xc1000000 pc: 0x080021e8 msp: 0x20008000
Info : Stlink adapter speed set to 950 kHz
adapter speed: 950 kHz
Info : device id = 0x10006442
Info : flash size = 256kbytes
Info : Stlink adapter speed set to 950 kHz
adapter speed: 950 kHz
STM32F091RCTx.cpu: target state: halted
target halted due to debug-request, current mode: Thread
xPSR: 0xc1000000 pc: 0x080021e8 msp: 0x20008000
Info : dropped ‘gdb’ connection

Hi,

Did you change the linker script file FLASH addresses ?
I mean, is your program starting at 0x0800 0000 like a normal program ?

Is it a bootloader program you’re trying to debug or a simple GPIO toggle ?
If you want to debug a simple GPIO toggle, just import it from the HAL FW examples.

Rgds,
Laurent

Hi Laurent,
the simple GPIO toggle works well. I changed the memory because I want to create a bootloader firmware starting from the GPIO toggle.

/* Memories definition */
MEMORY
{
RAM (xrw) : ORIGIN = 0x20000000, LENGTH = 32K - 192
ROM (rx) : ORIGIN = 0x8000000, LENGTH = 12K
}

Best regards,
Andrea


 

Newest Forum Posts

  1. SPI on Nucleo_STMH533RE by royjamil, 2025-05-04 20:13
  2. SPI on Nucleo_STMH533RE by higginsa1, 2025-03-25 07:37
  3. SPI on Nucleo_STMH533RE by royjamil, 2025-03-23 11:31
  4. SPI on Nucleo_STMH533RE by higginsa1, 2025-03-23 09:33
  5. Configuring DMA for ADC in SW? by sam.hodgson, 2025-03-04 12:58
  6. Build a project in "release" mode by info@creosrl.it, 2025-02-20 18:12
  7. Build a project in "release" mode by info@creosrl.it, 2025-02-20 17:05
  8. Build a project in "release" mode by tang, 2025-02-20 10:36
  9. Build a project in "release" mode by info@creosrl.it, 2025-02-19 17:35
  10. Fail to debug in Win 11 C/C++ by mortenlund, 2024-12-26 20:27

Last-Modified Blogs