2025-09-25 4:56 PM
Hello,
I have a STM32G0B1KBU3N MCU for my USB-C PD board. I am a new with this so learning. I am currently finished assemble my own PCB and have some issue with programming the controller. I can program controller with ST link V3-minie but have Zero luck to go connect with ST LInk v2. Is my controller supports only V3 hardware? I saw in the Programmer menu with V2 hardware there is only 4 kHz frequency and V3 hardware offers 8 kHz (same as controller internal clock) am I right? Thank you.
2025-10-16 6:58 AM
Hello,
there is nothing special to do for an ST-Link/V2 to work in SWD compared to a V3MINIE. Double checking the connection, and if possible, probing signals might help understanding what happens. According to UM1075, you "only" need to connect pin7 (SWDIO), pin9 (SWCLK), pin1 or pin2 for VTarget input to the ST-Link, one GND. I recommend to also connect pin15 to NRST, to ensure the debug pin status on target side in hardware reset configuration mode (and/or "init under reset" mode depending on tools). This allows to get rid of the impact of an application potentially modifying the default configuration of debug pins, and to have a more predictable target state when the tool attempts connecting. You don't need to connect 11 GND, and I would suggest to remove the ones on pin3 and pin5 as a try because you face some issue.
If you are using the same configuration in the tool with a correct connection, I see no reason for the ST-Link/V2 to fail compared to V3MINIE. May you please precise the ST-Link/V2 firmware version, and which programming tool you are using ? [I'm surprised by the proposed frequency list]. Having a description of the error might also help, as long as the verification how the ST-Link/V2 appears in your system (in the Device manager if you are on Windows). A failure of the ST-Link/V2 itself is also possible, all the more if you never saw it working.
2025-10-16 7:15 AM
@grisom13 wrote:STM Programmer offers "Hardware reset". Is this with a manual Reset switch?
It means using the NRST hardware signal to reset the Target.
As @S C said, this isn't mandatory but can get you out of some tricky situations - hence it is highly recommended to include NRST on your programming/debug access