cancel
Showing results for 
Search instead for 
Did you mean: 

dfuse and the STM32F427 and openocd and option byte problems

victor239955_stm1
Associate
Posted on December 10, 2013 at 19:21

I have a board of my own design using the STM32F427 and several 407 demo boards (Olimex H407 and Disco4).

I am pretty sure that my design is working correctly.  I am also pretty sure that the dfuse tester and demonstrator programs (latest release 3.0.3) do NOT work correctly.

a) in demonstrator, while the program correctly sees, for example,  that there are 24 flash sectors and 2 sets of option bytes, it does not correctly access the option bytes.  It has no way to access the second (427 unique) set of option bytes, nor does it provide the bank bit or provide a way to set the read or write protect flags or the write protect bits for the upper set of flash sectors.

b) a general problem not restricted to the 427: dfuse demonstrator only works if you have a dfu link to the chip.  Why does it give you a warning when you download a dfu file into your chip saying you are in dfu mode?  There isn't any alternative to being connected in dfu mode for this program to even work.   It doesn't make sense.  Same thing for verify.

c) in tester, which DOES work better with the 427, things are still not quite right.  If you try to set (or clear) the option bits, you can do this in the first set but not the second set.  Once set they won't clear.

d) in tester, with the 407, you can set the nWRP bits, but when you do, it gives you an error. It does set the bits, but you get a spurious error.  OTOH, demonstrator works cleanly with the 407 (but not, as I say, the 427).

So, it looks like ST really needs to take a Disco4 board and solder a 427 on it and then use it to fix tester and demonstrator so it works correctly;

e) I have not been able to get demonstrator or tester to erase or overwrite the pre-loaded demo code in the 427. 

f) Openocd cannot successfully do this either - it always says the part is locked or protected or other oddnesses and none of the usual commands work to release the memory.  And, BTW, both tester and demonstrator say that all 24 sectors are RWE.

f) I have seen other weirdnesses in the version 7 freddie release of the openocd when trying to run with the 427

General question:

Has anyone been able to successfully set the option bytes in the 427 by using some interactive program like tester or demonstrator or openocd?  If so, please explain.

#stm32f427-dfuse-openocd-tester
2 REPLIES 2
Posted on December 11, 2013 at 00:26

B) I assume you are using the standard VID/PID of the device, and the warning your are talking about is presumably the one that indicates you are going to nuke ANY F4 rather than one that has your unique VID/PID?

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Herve LE GUEN
Associate
Posted on March 09, 2017 at 17:43

You can't set readonly flash with dfuse