cancel
Showing results for 
Search instead for 
Did you mean: 

OpenOCD Process Killed Unexpectedly During STM32U5 Programming

Fabi82
Associate

I'm trying to program an STM32U5 microcontroller with Open On-Chip Debugger 0.12.0+dev-00597-ga5a21219f (2024-06-03-11:08), but the process is terminated abruptly. The problem seems to occur without a clear error message.

I am using a stlink to flash the script, and it works fine with the STM32CubeProgrammer and STM32_Programmer_CLI, in the cfg file I added:

 

 

source [find interface/stlink.cfg]
transport select hla_swd

 

 

The debug output proceeds normally until the process is terminated with:

 

 

[1] 5501 killed /opt/homebrew/bin/openocd -d -s /opt/homebrew/share/openocd/scripts -f -c -

 

 

 

 

I have attached the full log (very long). Thanks for any help on how to flash the chip with OpenOCD.

 

 

 

 

/opt/homebrew/bin/openocd -s /opt/homebrew/share/openocd/scripts -f /opt/homebrew/Cellar/open-ocd/0.12.0_1/share/openocd/scripts/target/stm32u5x_mod.cfg -c "tcl_port disabled" -c "gdb_port disabled" -c "tcl_port disabled" -c "program \"/Users/KarlFri/Downloads/MyApplication-CLion/cmake-build-debug/Riverdi_50STM32U5G9.elf\"" -c reset -c shutdown
Open On-Chip Debugger 0.12.0+dev-00597-ga5a21219f (2024-06-03-11:08) [https://github.com/STMicroelectronics/OpenOCD]
Licensed under GNU GPL v2
For bug reports, read
        http://openocd.org/doc/doxygen/bugs.html
Info : The selected transport took over low-level target control. The results might differ compared to plain JTAG/SWD
Warn : The selected adapter does not support debugging this device in secure mode
Info : clock speed 500 kHz
Info : STLINK V2J28S7 (API v2) VID:PID 0483:3748
Info : Target voltage: 3.218397
Info : [stm32u5x.cpu] Cortex-M33 r0p4 processor detected
Info : [stm32u5x.cpu] target has 8 breakpoints, 4 watchpoints
Info : [stm32u5x.cpu] Examination succeed
Info : gdb port disabled
CPU in Non-Secure state
[stm32u5x.cpu] halted due to debug-request, current mode: Thread 
xPSR: 0xf9000000 pc: 0xfffffffe msp: 0xfffffffc
** Programming Started **
Info : device idcode = 0x10016476 (STM32U5F/U5Gxx - Rev Z : 0x1001)
Info : TZEN = 0 : TrustZone disabled by option bytes
Info : RDP level 0 (0xAA)
Info : flash size = 4096 KiB
Info : flash mode : dual-bank
Warn : Adding extra erase range, 0x0800d4b0 .. 0x0800dfff
[1]    5318 killed     /opt/homebrew/bin/openocd -s /opt/homebrew/share/openocd/scripts -f  -c  -c  

 

 

0 REPLIES 0