Target doesn't properly reset on custom board with STM32cubeIDE
I am using the STM32F030F4P6 MCU and ST-Link V2 with tag connect (6- pin for SWD) and am having trouble bootloading the board. I have tried multiple configurations, with this one being ST-LINK GDB server:
STM32CubeProgrammer v2.12.0 ------------------------------------------------------------------- Log output file: C:\Users\ricci\AppData\Local\Temp\STM32CubeProgrammer_a19324.log ST-LINK SN : 38FF6A06304E4B3031321143 ST-LINK FW : V2J40S7 Board : -- Voltage : 3.25V SWD freq : 950 KHz Connect mode: Under Reset Reset mode : Hardware reset Device ID : 0x444 Revision ID : Rev 1.0 Device name : STM32F03x Flash size : 16 KBytes Device type : MCU Device CPU : Cortex-M0 BL Version : 0x10 Memory Programming ... Opening and parsing file: ST-LINK_GDB_server_a19324.srec File : ST-LINK_GDB_server_a19324.srec Size : 6.30 KB Address : 0x08000000 Erasing memory corresponding to segment 0: Erasing internal memory sectors [0 6] Download in Progress: File download complete Time elapsed during download operation: 00:00:00.945 Verifying ... Download verified successfully
And have seen the results above however the ST-Link V2 LED is still flashing even when the program claims it "download verified successfully"
I tried ST-Link with OpenOCD in the debugger menu and got this as a result:
Open On-Chip Debugger 0.12.0-00029-gf77e7cb03 (2023-12-15-13:25) [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 V2J45S7 (API v2) VID:PID 0483:3748 Info : Target voltage: 3.213158 Info : clock speed 1800 kHz Info : stlink_dap_op_connect(connect) Info : SWD DPIDR 0x0bb11477 Info : [STM32F030F4Px.cpu] Cortex-M0 r0p0 processor detected Info : [STM32F030F4Px.cpu] target has 4 breakpoints, 2 watchpoints Info : starting gdb server for STM32F030F4Px.cpu on 3333 Info : Listening on port 3333 for gdb connections Info : accepting 'gdb' connection on tcp/3333 Info : device id = 0x10006444 Info : flash size = 16 KiB Warn : GDB connection 1 on target STM32F030F4Px.cpu not halted undefined debug reason 8 - target needs reset Info : accepting 'gdb' connection on tcp/3333 Warn : GDB connection 2 on target STM32F030F4Px.cpu not halted undefined debug reason 8 - target needs reset [STM32F030F4Px.cpu] halted due to debug-request, current mode: Thread xPSR: 0xc1000000 pc: 0x0800060c msp: 0x20001000 [STM32F030F4Px.cpu] halted due to debug-request, current mode: Thread xPSR: 0xc1000000 pc: 0x0800060c msp: 0x20001000 Info : [STM32F030F4Px.cpu] external reset detected Info : [STM32F030F4Px.cpu] external reset detected shutdown command invoked shutdown command invoked
(Note: Shutdown command invoked was when I stopped the program)
It seems that for whatever reason the ST-Link cannot reset properly, and I am unsure as to how to fix this.
Here is the schematic portion of the MCU:


