Skip to content
Snippets Groups Projects
Commit c3d0461c authored by Jean-Claude BAU's avatar Jean-Claude BAU
Browse files

wrsLeapSecStatus: Change behavior

If wrsLeapSecStatusDetails returns 'leapSecFileExpired' then it will be
propagated to wrsLeapSecStatus as follow:
- Timing mode is GM or FR : Warning
- Timing mode is BC: Ok
parent b5c5ca28
Branches
Tags
No related merge requests found
......@@ -366,6 +366,7 @@ static void get_wrsSystemClockStatus(void){
static void get_wrsLeapSecondStatus(void){
struct wrsCurrentTime_s *t=&wrsCurrentTime_s;
struct wrsSpllStatus_s *s=&wrsSpllStatus_s;
int status=0;
switch (t->wrsLeapSecStatusDetails ) {
......@@ -383,8 +384,9 @@ static void get_wrsLeapSecondStatus(void){
status=WRS_LEAP_SEC_STATUS_ERROR;
break;
case WRS_LEAP_SEC_STATUS_DETAILS_FILE_EXPIRED:
// TODO: Check GM
status=WRS_LEAP_SEC_STATUS_WARNING;
status = ( s->wrsSpllMode == WRS_SPLL_MODE_GRAND_MASTER
|| s->wrsSpllMode == WRS_SPLL_MODE_MASTER)
? WRS_LEAP_SEC_STATUS_WARNING : WRS_LEAP_SEC_STATUS_DETAILS_OK;
break;
}
wrsTimingStatus_s.wrsLeapSecStatus = status;
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment