cancel
Showing results for 
Search instead for 
Did you mean: 

Flash Erase without interrupting the ruining application for updating the firmware over UART

RSakh.1
Associate II

Hi Team,

System Overview:-

We have a system which contains two controller, out of which one is STM32G071. Second controller handles all the wireless operations i.e. Wi-Fi. both the controller communicate over UART to exchange information. Data received over Wi-Fi second controller will be transfer to STM32G071 over UART, and vice-versa.

We are planning to add Over The Air feature to system. Binary for the STM32G071 will be received by the Wi-Fi Controller and it will get stored in its memory. Once complete binary is receive by the Wi-Fi controller, it will send data to STM32 over UART, and STM32 will write 64 bit data at at a time to allocated OTA section of flash in run time (As per flash information minimum of 64 bit can be written to flash). STM32 application runs in cycles of 8 mSec, and it takes around 7 mSec to complete operation in each cycle.

Problem Statement:-

STM32G071 is containing safety critical application which need to run without interruption. Time required to write 64 bit of data to flash is 85 uSec only which can be executed without any application interruption.

As we have to erase OTA section of flash before writing binary received over Wi-Fi., but as per specification, Flash erase takes 22ms to erase 1 page (2Kb), (we may need to erase multiple pages) which causes the application to enter into halt until flash erase completion which dose not meet the system requirement.

Question:

  1. Is it possible to have erase operation runs parallelly with application so that running application will not get interrupt ?
  2. Is it possible to reduce erase operation with lesser time ?
  3. Is possible to have byte erase option ?
  4. Is there any other better option or way to have OTA for STM32G071 ?

1 REPLY 1

Run entirely from RAM

No

No

Use QSPI device to stage the update​

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..