2025-08-08 9:31 PM
I'm using STM32H750
Is it possible to read and write like EEPROM in a specific part of the program (the last part of the internal flash area?)?
I think it's impossible because there's only one sector
If possible, I would appreciate it if you could give me an example
2025-08-09 1:34 AM - edited 2025-08-09 1:51 AM
@SMj.1 wrote:Is it possible to read and write like EEPROM example
No - not exactly.
The biggest difference between Flash and what's commonly called "EEPROM"[1] is that Flash can only be erased a page at a time; that's general - not specific to STM32.
In STM32s, there's also often a limitation that you can't write just a single byte.
But, of course, there are software workarounds to give something which looks like "EEPROM" - ie, to emulate EEPROM.
See:
and more ...
[1] Literally, EEPROM stands for Electrically-Erasable and Programmable Read-Only Memory so, on that basis, Flash is EEPROM.
But I take it that you're talking about "EEPROM" in the sense of non-volatile memory where you can read & write individual bytes at will?
2025-08-09 2:02 AM
Simply no, but too with one sector you can do it, with good power reserve control safe.
Simply on point you fill and require erase , place code to ram and copy of boot to ram erase and write boot back...
2025-08-09 2:29 AM
The ST implementation uses (at least) two sectors - so you won't lose everything if power dies during erasing one of them.
Using multiple sectors also helps with wear-levelling ...
2025-08-09 3:47 AM
FYI H750 is one sector model.