cancel
Showing results for 
Search instead for 
Did you mean: 

STLink V2 works - STLink V3Mods doesnt (STM32H7 programming)

mwp
Senior

I'm attempting to erase & program a STM32H7x using a STLink V3Mods and OpenOCD (a recent official release).
It fails with a "read version fails".

When i try using a STLink V2 (host, openocd script and target device unchanged), it works just fine.

I've scoped the SWD CLK & IO lines to find the SWD init differences between V3Mods and V2.
The only difference is the V3Mods is doing the SWD init "magic switch" at 3.4Mhz, and the V2 is doing it at 1.4Mhz.

I've tried setting "adaptor speed 1000" in the openocd script to slow the clock rate when using the V3Mods, but it has no effect at all.

Does anyone know how to force slow the clock rate?

Thanks in advance.

1 REPLY 1
AScha.3
Super User

Hi,

i have the H743, with OpenOCD , st-linkV3 (mods + miniE + onboard nucleo) at 24MHz running,

with SWV (2Mbit...or so) , no problem.

Except one thing: V3 is much more sensible to spikes , even only on ground connection !

So try without any external ground connection, just PC->stLink-> target ; and power for target also from this PC, cables close together (or short), to reduce magnetic pickup at RF frequencies.

I got it working fine by connecting the target power supply on same mains outlet as the PC is connected;

otherwise not much fun with starting debug...almost never worked mor than some seconds.

So try with mod or improved ground connection.

If you feel a post has answered your question, please click "Accept as Solution".