Can't flash STM32F101
mike at sowbug.com
Thu Feb 22 18:39:45 CET 2018
This guide is very helpful: https://nx3d.org/gnuk-st-link-v2/ In
particular, pay attention to the photo at the bottom showing how to trigger
the reset functionality.
I was having trouble getting the reset timing right, so I did something
$ for i in `seq 1 500`; do stlink reset; stlink erase; stlink write [bin
filename] 0x08000000; done
which gave me enough time to hold the CLK/IO jumpers in place with one hand
and then drag another jumper across pins 7 and 8 on the STM32 chip to reset
it. Note that I was using https://github.com/texane/stlink/ with the
C8T6HACK modification at https://github.com/cabo/stlink. The arguments in
the bash command above are by memory and are likely incorrect, but you get
the idea: wrap a reset/erase/write sequence in a big loop.
Finally, note that there are at least three different manufacturers of
ST-Link v2 clones, and for some unknown reason they do not all use the same
pinout for the four terminal points. You will need a continuity tester to
establish the function of the four points, or if you are reckless, you can
use trial and error and hope you figure it out without shorting out a
component. For one of mine, the power terminals were the outer two points,
and SWDIO was the middle one closer to the USB plug, and SWCLK was the
other one in the middle.
On Sat, Feb 10, 2018 at 3:48 PM Fox <f at 0x52.eu> wrote:
> I have a St-link v2 STM32F101 from aliexpress (clone), and Im trying to
> flash it with another one.
> When I run tools/stlinkv2.py I get:
> ST-Link/V2 version info: 2 17 4
> Change ST-Link/V2 mode 0002 -> 0001
> Core does not halt, try API V2 halt.
> ValueError('Status of core is not halt.', 128)
> What am I doing wrong?
> Gnuk-users mailing list
> Gnuk-users at gnupg.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Gnuk-users