Index: RTC.c =================================================================== diff -u -r4ecbb2c37b64a4b09f3173aa9e505749d156d466 -re5296380d7baeedb25d6d3ebcc36def801997fcb --- RTC.c (.../RTC.c) (revision 4ecbb2c37b64a4b09f3173aa9e505749d156d466) +++ RTC.c (.../RTC.c) (revision e5296380d7baeedb25d6d3ebcc36def801997fcb) @@ -114,6 +114,7 @@ #define FPGA_ACCURACY_TOLERANCE 12U ///< FPGA accuracy tolerance in ms #define RTC_PUBLISH_INTERVAL 18U ///< RTC publish interval in counts (18) #define RTC_REG_ERROR_TIMEOUT_MS ( 3 * MS_PER_SECOND ) ///< RTC register error timeout in milliseconds. +#define RTC_BATTERY_LOW_TIMEOUT_MS ( 3 * MS_PER_SECOND ) ///< RTC battery low timeout in milliseconds. #define TIMER_COUNTER_TO_REQUEST_READ 18U ///< Timer counter for reading time from RTC (18) #define MAX_ALLOWED_FAILED_RTC_TRANSFERS 3U ///< Max allowed failed RTC transfers (3) @@ -279,9 +280,11 @@ #ifdef _DG_ initPersistentAlarm( ALARM_ID_DG_RTC_CONFIG_ERROR, RTC_REG_ERROR_TIMEOUT_MS, RTC_REG_ERROR_TIMEOUT_MS ); + initPersistentAlarm( ALARM_ID_DG_RTC_BATTERY_LOW, RTC_BATTERY_LOW_TIMEOUT_MS, RTC_BATTERY_LOW_TIMEOUT_MS ); #endif #ifdef _HD_ initPersistentAlarm( ALARM_ID_HD_RTC_CONFIG_ERROR, RTC_REG_ERROR_TIMEOUT_MS, RTC_REG_ERROR_TIMEOUT_MS ); + initPersistentAlarm( ALARM_ID_HD_RTC_BATTERY_LOW, RTC_BATTERY_LOW_TIMEOUT_MS, RTC_BATTERY_LOW_TIMEOUT_MS ); #endif }