Page 1 of 1

ESP-IDF : Esp32S3 - Is there a part of RAM that is not resetted at reset ?

Posted: Wed Jul 12, 2023 2:30 pm
by ThomasESP32
Good afternoon,

I am working on an Esp32S3 and I would like to know if there is a section/part of the RAM memory
that is not resetted at chip reset (Only when the Chip is powered down electrically) please ?

My goal would be to put a counter in RAM (In this partition) and increment it sometimes,
then, after a chip reset, I would like to count the value that is stored in this counter.

Only if the chip is powered down electrically, I would like that this value is resetted to 0.

Do you think it is possible please ?
Thank you for your help,

Best regards,


Thomas TRUILHE

Re: ESP-IDF : Esp32S3 - Is there a part of RAM that is not resetted at reset ?

Posted: Wed Jul 12, 2023 2:42 pm
by ESP_igrr
You can use RTC_NOINIT_ATTR attribute which will place the variable into RTC memory, and exclude it from initialization at start-up.

RTC RAM will be lost on power-on reset, or if EN pin is toggled (which is also considered a power-on reset in ESP chips).