Index: firmware/App/Services/SystemComm.c =================================================================== diff -u -r8c195e4b22d63a6b8de9089ff6bf704282f54885 -re5fc9a1e8898da7bc6d26f1e333ee44f6544d214 --- firmware/App/Services/SystemComm.c (.../SystemComm.c) (revision 8c195e4b22d63a6b8de9089ff6bf704282f54885) +++ firmware/App/Services/SystemComm.c (.../SystemComm.c) (revision e5fc9a1e8898da7bc6d26f1e333ee44f6544d214) @@ -7,8 +7,8 @@ * * @file SystemComm.c * -* @author (last) Dara Navaei -* @date (last) 13-Feb-2023 +* @author (last) Sean Nash +* @date (last) 10-Mar-2023 * * @author (original) Dara Navaei * @date (original) 05-Nov-2019 @@ -761,21 +761,21 @@ } } - // Only alarm on DG comm loss while in the treatment workflow - if ( MODE_PRET == opMode || MODE_TREA == opMode || MODE_POST == opMode ) + if ( TRUE == didTimeout( timeOfLastDGCheckIn, DG_COMM_TIMEOUT_IN_MS ) ) { - if ( TRUE == didTimeout( timeOfLastDGCheckIn, DG_COMM_TIMEOUT_IN_MS ) ) - { #ifndef RUN_WITHOUT_DG + // Only alarm on DG comm loss while in the treatment workflow + if ( MODE_PRET == opMode || MODE_TREA == opMode || MODE_POST == opMode ) + { activateAlarmNoData( ALARM_ID_DG_COMM_TIMEOUT ); - dgIsCommunicating = FALSE; -#endif } + else // Otherwise clear the alarm + { + clearAlarmCondition( ALARM_ID_DG_COMM_TIMEOUT ); + } + dgIsCommunicating = FALSE; +#endif } - else // Otherwise clear the alarm - { - clearAlarmCondition( ALARM_ID_DG_COMM_TIMEOUT ); - } } }