Index: firmware/App/Services/AlarmMgmt.c =================================================================== diff -u -r758497628fa5839a2b6661a9d7c32fd3b11db2bd -rd861abb04031160933d318d0fc21c8ffd2fec544 --- firmware/App/Services/AlarmMgmt.c (.../AlarmMgmt.c) (revision 758497628fa5839a2b6661a9d7c32fd3b11db2bd) +++ firmware/App/Services/AlarmMgmt.c (.../AlarmMgmt.c) (revision d861abb04031160933d318d0fc21c8ffd2fec544) @@ -1096,6 +1096,15 @@ HD_OP_MODE_T currentMode = getCurrentOperationMode(); ALARM_ID_T a; + // Set user alarm recovery actions allowed by state flags + alarmButtonBlockers[ ALARM_BUTTON_STATE_BLOCK_RESUME ] = ( TRUE == alarmUserRecoveryActionEnabled[ ALARM_USER_ACTION_RESUME ] ? FALSE : TRUE ); + alarmButtonBlockers[ ALARM_BUTTON_STATE_BLOCK_RINSEBACK ] = ( TRUE == alarmUserRecoveryActionEnabled[ ALARM_USER_ACTION_RINSEBACK ] ? FALSE : TRUE ); + alarmButtonBlockers[ ALARM_BUTTON_STATE_BLOCK_END_TREATMENT ] = ( TRUE == alarmUserRecoveryActionEnabled[ ALARM_USER_ACTION_END_TREATMENT ] ? FALSE : TRUE ); + // Reset user alarm recovery actions allowed by active alarms flags + alarmButtonBlockers[ ALARM_BUTTON_TABLE_BLOCK_RESUME ] = FALSE; + alarmButtonBlockers[ ALARM_BUTTON_TABLE_BLOCK_RINSEBACK ] = FALSE; + alarmButtonBlockers[ ALARM_BUTTON_TABLE_BLOCK_END_TREATMENT ] = FALSE; + // Determine alarm flags for ( a = ALARM_ID_NO_ALARM; a < NUM_OF_ALARM_IDS; a++ ) { @@ -1105,12 +1114,9 @@ stop = ( TRUE == ALARM_TABLE[ a ].alarmStops ? TRUE : stop ); noClear = ( TRUE == ALARM_TABLE[ a ].alarmNoClear ? TRUE : noClear ); // Set user alarm recovery actions allowed flags - alarmButtonBlockers[ ALARM_BUTTON_TABLE_BLOCK_RESUME ] = ALARM_TABLE[ a ].alarmNoResume; - alarmButtonBlockers[ ALARM_BUTTON_TABLE_BLOCK_RINSEBACK ] = ALARM_TABLE[ a ].alarmNoRinseback; - alarmButtonBlockers[ ALARM_BUTTON_TABLE_BLOCK_END_TREATMENT ] = ALARM_TABLE[ a ].alarmNoEndTreatment; - alarmButtonBlockers[ ALARM_BUTTON_STATE_BLOCK_RESUME ] = ( TRUE == alarmUserRecoveryActionEnabled[ ALARM_USER_ACTION_RESUME ] ? FALSE : TRUE ); - alarmButtonBlockers[ ALARM_BUTTON_STATE_BLOCK_RINSEBACK ] = ( TRUE == alarmUserRecoveryActionEnabled[ ALARM_USER_ACTION_RINSEBACK ] ? FALSE : TRUE ); - alarmButtonBlockers[ ALARM_BUTTON_STATE_BLOCK_END_TREATMENT ] = ( TRUE == alarmUserRecoveryActionEnabled[ ALARM_USER_ACTION_END_TREATMENT ] ? FALSE : TRUE ); + alarmButtonBlockers[ ALARM_BUTTON_TABLE_BLOCK_RESUME ] |= ALARM_TABLE[ a ].alarmNoResume; + alarmButtonBlockers[ ALARM_BUTTON_TABLE_BLOCK_RINSEBACK ] |= ALARM_TABLE[ a ].alarmNoRinseback; + alarmButtonBlockers[ ALARM_BUTTON_TABLE_BLOCK_END_TREATMENT ] |= ALARM_TABLE[ a ].alarmNoEndTreatment; if ( TRUE == alarmUserRecoveryActionEnabled[ ALARM_USER_ACTION_RESUME ] ) { noResume = ( TRUE == ALARM_TABLE[ a ].alarmNoResume ? TRUE : noResume );