简体   繁体   中英

Flash downloaded code into STM32F4 MCU; how do I remove the downloaded code?

I'm new embedded electronics and am learning via online tutorials. I built and downloaded a code (with the uVision IDE) which made the blue and orange LEDs flash. I want these LEDs to stop flashing, and I want the MCU to go back to the state it was at before I downloaded the code. How would I do that?

How to return:

  1. Write FLASH mass erase function
  2. Copy mass flash erase function to the RAM.
  3. Jump to it
  4. Do the software reset

If I am not mistaken, You want to erase your micro-controller.

  • For STM32 you have different options, If you are using ST-LINK, I think the best solution would be "STM32 ST-LINK UTILITY" which you can download here

  • Or you can use built-in Bootloader which can be enabled by BOOT pins and so on.

  • And you can also use your development environments such as IAR, KEIL or something like that.

Additionally, Never worry about the downloaded program, you can always erase your application even you enabled the read-out protection option.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM