2020-07-13 09:47 PM
I've been having trouble connecting my board through the STM IDE. I've decided that I want to in a sense 'factory reset' the board. Would a full chip erase do this or would it ruin my board?
2020-07-13 10:59 PM
No, you can always load a new firmware after a full erase.
2020-07-13 11:00 PM
How do you load new firmware after a full erase? (The original, 'out of the box' firmware)
2020-07-13 11:51 PM
If you had saved it, then just load it using the ST-Link Utility, Cubeprogrammer, or one of the dozen programmer software out there.
If you had not, then you have to find it on the net, maybe on the ST homepage, or ask ST support nicely to mail you the binary. Be sure to get the one for your board, loading a firmware meant for another board might damage yours.
If you have more than one identical boards, you can save it (using ST-Link Utility) from one still having the original firmware.
The source code for the original firmware is usually distributed in the STM32Cube_FW package for your MCU series, you might be able to compile and run it.
2020-07-14 01:18 AM
Hello, what you mean with "original firmware"?
'm thinking Arduino usage of 40 yr old hardware introduced some wrong concept to.
Bootloader on oldest machines was loaded by hand thru front panel keyboard or switches.
PDP 11 Front panel switches (bootloader was loaded word by word)
After advent of uProcessor bootloader where on prom.
On some microcontroller where loaded on eprom or flash.
Nowaday modern hardware bootloader reside in ROM, so never got cancelled.
Also JTAG nor SWD need bootloader. Bootloader serve to upgrade firmware when JTAG or debug hardware went disabled by code protection. (as when bought)
Hey this is not Arduino! This is not 40Yr old microController.
Code protection is reversible so full erase clear all flash then clear protection bit. (Factory reset)
Regards
2020-07-14 01:30 AM
Out of the box firmware:
On ST board some sort of demonstration is loaded, this is available on ST site or repository of IDE.
On chip bought from distribution just erased flash no frimware other than ROM bootloader.
On non ST board some sort of demo firmware available or not.
Bought a couple of cheap stm32F030 board from china, all of them carry'd hello world demo.
No reason to, many of them where code protected so must be "full chip erased" to use. No need to know how original firmware was.
2020-07-14 01:31 AM
Some ST boards are shipped with a demo firmware loaded, a blinky on simpler boards, some graphical application on boards with a LCD display.
2020-07-14 01:43 AM
When people order MCU from distributor, the flash is erased: at power on the bootloader will automatically activate.
Do a mass erase with cube programmer or else and you'll get back to normal.
Mass erase is a logical step if some chip protections have been activated.
Otherwise, I just from IDE go to debug mode and the STLink will program the flash with my SW automatically.
2020-07-14 05:18 AM
Hi Berendi, agree as I wrote, about this some note on ST board:
Large board Demonstration use old ADAFruit LCD, this one is obsoleted and hard to find in time
Nano form use Gravitech board more hard to find.
Demo on 429 series preclude network and ADAFruit shield.
Lot of time to adapt examples and board require rework to use network and shield. Good learning to use part on custom board.
IDE need more attention on product usability.