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:
Bertrand Songis
2019-11-21 11:50:33 +01:00
committed by GitHub
parent 103534bdcf
commit 4cdd17f0d7
41 changed files with 235 additions and 190 deletions
+4 -4
View File
@@ -148,11 +148,11 @@ include_directories(${CMAKE_CURRENT_BINARY_DIR}/bitmaps/${GUI_DIR})
add_subdirectory(lua)
include(gui/CMakeLists.txt)
if(RAMBACKUP)
add_definitions(-DRAMBACKUP)
if(RTC_BACKUP_RAM)
add_definitions(-DRTC_BACKUP_RAM)
set(SRC ${SRC} storage/rlc.cpp)
set(FIRMWARE_SRC ${FIRMWARE_SRC} storage/rambackup.cpp)
set(GTEST_SRC ${GTEST_SRC} ${RADIO_SRC_DIRECTORY}/storage/rambackup.cpp)
set(FIRMWARE_SRC ${FIRMWARE_SRC} storage/rtc_backup.cpp)
set(GTEST_SRC ${GTEST_SRC} ${RADIO_SRC_DIRECTORY}/storage/rtc_backup.cpp)
endif()
if(NOT LUA STREQUAL NO)