MAGIC value for powerReason should be stored in RTC backup on Horus (#7096)
- Allows the radio main application to start correctly when coming from an app in RAM - Refactoring of the `UNEXPECTED_SHUTDOWN()` process - Saves the RTC battery as BACKUP RAM is not needed on normal shutdown - On PWR OFF on an ALERT, the radio won't show the next alert before shutting down - Bootloader flashable through the SD Manager
This commit is contained in:
+3
-3
@@ -167,8 +167,8 @@ void checkEeprom()
|
||||
#else
|
||||
void checkEeprom()
|
||||
{
|
||||
#if defined(RAMBACKUP) && !defined(SIMU)
|
||||
if (TIME_TO_RAMBACKUP()) {
|
||||
#if defined(RTC_BACKUP_RAM) && !defined(SIMU)
|
||||
if (TIME_TO_BACKUP_RAM()) {
|
||||
rambackupWrite();
|
||||
rambackupDirtyMsk = 0;
|
||||
}
|
||||
@@ -504,7 +504,7 @@ void perMain()
|
||||
|
||||
event_t evt = getEvent(false);
|
||||
|
||||
#if defined(RAMBACKUP)
|
||||
#if defined(RTC_BACKUP_RAM)
|
||||
if (globalData.unexpectedShutdown) {
|
||||
drawFatalErrorScreen(STR_EMERGENCY_MODE);
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user