cancel
Showing results for 
Search instead for 
Did you mean: 

How to retain some data in flash memory during appplication running on STM32F405 ?

TKopp.67
Associate II

Hi everyone, 

For some reasons, i need to store 3 uint16 in flash (once) when my application is running. Of course the goal is that those values will remain after a power down / reset. Does someone knows how to do this properly ?

Do i need to define a new area in the linker (located in flash area) ?

Thanks for your answer,

Best Regards,

Thomas

4 REPLIES 4
TKopp.67
Associate II

Or better a zone in the memory area that would be retain after a reflash of the MCU ?

TDK
Guru

You can store memory to flash, which is retained through power resets. There is an EEPROM emulation library you can search for. People often use the last (or last two) pages in flash to do this.

If you feel a post has answered your question, please click "Accept as Solution".
TKopp.67
Associate II

Oh thanks guys,

Will check about that feature right now.

Best Regards,

Thomas