ST-LINK
Configuration
- Configuration > System Core > SYS > Debug mode >> 'Serial Wire'
- Editing the code
- Click 'Hammer' icon on STM32CubeIDE to build
- Clikc 'Run' icon
- Select 'Debugger' > debug probe 'ST-LINK(OpenOCD)' > show generator options > connection interface >> Swd && Reset mode >> Software system reset
- unplug st-link and replug in.
Open On-Chip Debugger 0.12.0+dev-00608-gd8ed48fef (2025-02-06-11:17) [https://github.com/STMicroelectronics/OpenOCD]
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
Info : Listening on port 6666 for tcl connections
Info : Listening on port 4444 for telnet connections
Info : STLINK V2J46S7 (API v2) VID:PID 0483:3748
Info : Target voltage: 3.227200
Info : Unable to match requested speed 8000 kHz, using 4000 kHz
Info : Unable to match requested speed 8000 kHz, using 4000 kHz
Info : clock speed 4000 kHz
Info : stlink_dap_op_connect(connect)
Info : SWD DPIDR 0x1ba01477
Info : [STM32F103C8Tx.cpu] Cortex-M3 r1p1 processor detected
Info : [STM32F103C8Tx.cpu] target has 6 breakpoints, 4 watchpoints
Info : [STM32F103C8Tx.cpu] Examination succeed
Info : starting gdb server for STM32F103C8Tx.cpu on 3333
Info : Listening on port 3333 for gdb connections
Info : accepting 'gdb' connection on tcp/3333
Info : device id = 0x20036410
Info : flash size = 64 KiB
Warn : GDB connection 1 on target STM32F103C8Tx.cpu not halted
undefined debug reason 8 (UNDEFINED) - target needs reset
Info : accepting 'gdb' connection on tcp/3333
Warn : GDB connection 2 on target STM32F103C8Tx.cpu not halted
undefined debug reason 8 (UNDEFINED) - target needs reset
[STM32F103C8Tx.cpu] halted due to breakpoint, current mode: Thread
xPSR: 0x01000000 pc: 0x08000358 msp: 0x20005000
Info : Unable to match requested speed 8000 kHz, using 4000 kHz
Info : Unable to match requested speed 8000 kHz, using 4000 kHz
[STM32F103C8Tx.cpu] halted due to breakpoint, current mode: Thread
xPSR: 0x01000000 pc: 0x08000354 msp: 0x20005000
Info : dropped 'gdb' connection
[STM32F103C8Tx.cpu] halted due to debug-request, current mode: Thread
xPSR: 0x21000000 pc: 0x08000490 msp: 0x20004fe0
shutdown command invoked
Info : dropped 'gdb' connection
Page Source