-
Couldn't load subscription status.
- Fork 7.7k
Global RAM structure variable gets corrupted and then auto recovers #11458
Unanswered
mightChamp
asked this question in
Q&A
-
we’re facing an issue related to RAM corruption, and I’d appreciate your input on how to handle it.
Here’s a summary of the situation:
- The entire application runs on a single core of the ESP32.
- We initialize EEPROM with 4000 bytes using EEPROM.begin(4000)
- At startup, we read a configuration structure (225 bytes) from EEPROM and store it in a global variable in RAM.
- This structure is read only once after reboot — we do not access EEPROM again afterward.
- The structure is then used in various parameter calculations.
- Initially, everything works correctly — calculations are accurate for the first 5–6 hours.
- Suddenly, calculations become incorrect, indicating that the structure variable has been corrupted in RAM.
- We do not modify or update this structure during runtime.
- Interestingly, after around 10 minutes, the calculations return to normal — suggesting that the structure variable somehow "corrects itself."
- This hardware has been running fine for 10 days, and this issue has occurred only once.
How can we detect and handle such a case where a global RAM variable gets corrupted and then seemingly recovers, even though we don’t explicitly touch it?
Beta Was this translation helpful? Give feedback.
All reactions
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment