Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
9 years, 5 months ago.
FOTA bootloader for STM32 Nucleo F411RE
How would we implement an IAP (In Application Programmer) on the STM32 NUCLEO platform using the native STM32 "System Memory Bootloader" inside an mbed application? This is also called bootstrap loaders or simply boot loaders.
See the following links for details: http://www.st.com/web/en/resource/technical/document/application_note/CD00167594.pdf
There are mbed IAP libraries for Freescale and NXP, but not STM32. http://developer.mbed.org/search/?type=&q=IAP
The following library allows for a custom bootloader for Freescale FRDM-K64F that would support FOTA (Firmware Over The Air). http://developer.mbed.org/users/Sissors/code/Bootloader_K64F/
What is the best way to implement similar functionality for the STM32 NUCLEO platforms?
Information
The basic requirements would be:
1. A custom circuit board with a single STM32 chip running mbde code that could respond to bootloading over USB serial.
2. Native mbed code where the user program and bootloader code are one and the same compiled bin file.
3. Download a new program over USB serial using TerraTerm (CoolTerm) to transmit the program bin file.
4. The mbed bootloader code which is part of the user program copies the new program data to Flash program memory and then reboots into the new program.
5. Ability to use XBee Series 2 radios in API mode for transmitting a new program to a remote STM32 mbed platform for remote re-programming.
4 Answers
7 years, 7 months ago.
Hi Andrew,
Is it possible to do this with WiFi instead of BLE? Is it using the same principle?
7 years, 7 months ago.
I have a similar task in front of me with the STM32L4 MCU. My idea is to do it as follows - Download the new firmware into an extern flash chip - Download a special upgrade-installer into the SRAM - Reboot the MCU from the SRAM. - Flash the new firmware from the external flash chip into the MCU - Checksum the new firmware - Reboot.
I need to figure out how to change the boot from Flash to SRAM by software without changing the boot Pins.
A complete other option is to develop a boot loader (lets say 16kB) which can handle the upgrades. In this case the mbed start address would be 0x08000000 + 16kB (via a custom mbed build).
7 years, 9 months ago.
I used BlueNRG from ST to do this in a custom embedded system based on SM32F4 a couple years back. Its a good starting point. http://www.st.com/content/ccc/resource/technical/document/application_note/09/45/83/e0/7d/67/46/2c/DM00115333.pdf/files/DM00115333.pdf/jcr:content/translations/en.DM00115333.pdf