Skip to main content
ABals.2
Associate II
November 28, 2022
Question

Can we emulate the EEPROM mechanism using the on-chip Flash memory (Flash Emulated EEPROM) in the STM32F302 series?

  • November 28, 2022
  • 2 replies
  • 1257 views

1. Can we emulate the EEPROM mechanism using the on-chip Flash memory (Flash Emulated EEPROM) in the STM32F302 series?

2. Went through the document "AN4894 Application note: EEPROM emulation techniques and software for STM32 microcontrollers", the STM32F302 is not listed under the Applicable STM32 Series Products Table.

#EEPROM​  #Flash​ 

This topic has been closed for replies.

2 replies

S.Ma
Principal
November 28, 2022

How long power keeps mcu on after power removal? How many writes over lifecycle? Is there max writw time constrain? How many eeprom bytes are needed?

Based on these questions you will know if you can, need dual bank, and needed sector size.

ABals.2
ABals.2Author
Associate II
December 5, 2022
  1. There is enough power to keep MCU ON after power removal.
  2. The usage might require approximately 300 writes over a year.
  3. No time constraint.
S.Ma
Principal
December 5, 2022

In this case you could use an external flash, so you don't need eeprom. Basic principle would be to use 2 flash sectors, one being always erased and ready to write, and rotate every write.

Of course this is basic idea, it can be refined.

I assumed your data size is big enough and should not use temporary ram, so the 2 sectors (old and new).