Go Down

Topic: How to write and protect strings inside ATmega328 flash memory  (Read 713 times) previous topic - next topic

AntonioTesta

I would like to reserve and protect an specific area inside ATmega328's flash memory for keep strings and numbers safe. Does anybody know how to do that ? Thanks for any help

sterretje

Please explain in more detail. Stuff in flash memory does not get overwritten during program execution.
If you understand an example, use it.
If you don't understand an example, don't use it.

Electronics engineer by trade, software engineer by profession. Trying to get back into electronics after 15 years absence.

didiergm

I am interested too as mkr boards dont have separate flash memory

sterretje

I am interested too as mkr boards dont have separate flash memory
In that case, you should start your own thread as the MKR uses a different processor from the one in the title. There is a dedicated MKR section on the forum where it might fit better.
If you understand an example, use it.
If you don't understand an example, don't use it.

Electronics engineer by trade, software engineer by profession. Trying to get back into electronics after 15 years absence.

AntonioTesta

Please explain in more detail. Stuff in flash memory does not get overwritten during program execution.
I need to keep some data safe in flash always, even after new programs uploads. I wonder if there is a way to protect a address range in flash memory against possible overwritten during uploads... Any idea about how to do that ? Thanks a lot

Juraj

I need to keep some data safe in flash always, even after new programs uploads. I wonder if there is a way to protect a address range in flash memory against possible overwritten during uploads... Any idea about how to do that ? Thanks a lot
https://github.com/Optiboot/optiboot/blob/master/optiboot/examples/test_dospm/test_dospm.ino
You can't write an Arduino sketch if you didn't learn programming. Not the language, but the concepts of programming - algorithms and data types.

Go Up