When I try to debug a Nucleo STM32F302R8 board I get this error:
OpenOCD: GDB Server Quit Unexpectedly. See gdb-server output for more details.
Multiple debug attempts generate multiple gdb-server instances. Compile and Upload work fine except compile generates a LOT of warnings.
I can debug a Bluepill board (using an ST-LINK V2 with the IDE) without problems.
BTW, no problems with this board using the terminal (gcc, gdb, openOCD, etc.)
Arduino IDE 2.3.3 on a MacBook Air M2, macOS 15.0.1.
[2024-11-01T23:26:23.933Z] SERVER CONSOLE DEBUG: onBackendConnect: gdb-server session connected. You can switch to "DEBUG CONSOLE" to see GDB interactions.
/Users/tom/Library/Arduino15/packages/STMicroelectronics/tools/xpack-openocd/0.12.0-3/bin/openocd -c "gdb_port 50000" -c "tcl_port 50001" -c "telnet_port 50002" -s /Users/tom/Documents/Arduino/Blink -f "/Applications/Arduino IDE.app/Contents/Resources/app/plugins/cortex-debug/extension/support/openocd-helpers.tcl" -f interface/stlink.cfg -f /Users/tom/Library/Arduino15/packages/STMicroelectronics/hardware/stm32/2.8.1/debugger/select_hla.cfg -f target/stm32c0x.cfg
xPack Open On-Chip Debugger 0.12.0+dev-01557-gdd1758272-dirty (2024-04-02-10:28)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
CDRTOSConfigure
hla_swd
Info : The selected transport took over low-level target control. The results might differ compared to plain JTAG/SWD
Info : Listening on port 50001 for tcl connections
Info : Listening on port 50002 for telnet connections
Info : clock speed 2000 kHz
Info : STLINK V2J33M25 (API v2) VID:PID 0483:374B
Info : Target voltage: 3.244473
Warn : UNEXPECTED idcode: 0x2ba01477
Error: expected 1 of 1: 0x0bc11477
[2024-11-01T23:26:24.130Z] SERVER CONSOLE DEBUG: onBackendConnect: gdb-server session closed
GDB server session ended. This terminal will be reused, waiting for next session to start...