Index: firmware/App/Modes/ModeFault.c =================================================================== diff -u -rc1e2dfcd544f59788ad1a58e1e8339a475ba4266 -rcd5be724d5a3ba7457e761191d82f278654d7f5c --- firmware/App/Modes/ModeFault.c (.../ModeFault.c) (revision c1e2dfcd544f59788ad1a58e1e8339a475ba4266) +++ firmware/App/Modes/ModeFault.c (.../ModeFault.c) (revision cd5be724d5a3ba7457e761191d82f278654d7f5c) @@ -1,14 +1,14 @@ /************************************************************************** * -* Copyright (c) 2019-2023 Diality Inc. - All Rights Reserved. +* Copyright (c) 2019-2024 Diality Inc. - All Rights Reserved. * * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. * * @file ModeFault.c * -* @author (last) Sean Nash -* @date (last) 04-May-2023 +* @author (last) Dara Navaei +* @date (last) 12-Jun-2023 * * @author (original) Dara Navaei * @date (original) 05-Nov-2019 @@ -74,6 +74,7 @@ doorClosedRequired( FALSE, FALSE ); syringeDetectionRequired( FALSE ); setVenousBubbleDetectionEnabled( FALSE ); + setCurrentSubState( NO_SUB_STATE ); // Set user alarm recovery actions allowed in this mode setAlarmUserActionEnabled( ALARM_USER_ACTION_RESUME, FALSE ); @@ -150,7 +151,13 @@ break; case HD_FAULT_STATE_COMPLETE: - // Do nothing. Done with the NV operations + // Do nothing unless the test configuration to recover treatment is enabled + if ( ( TRUE == getTestConfigStatus( TEST_CONFIG_RECOVER_TREATMENT ) ) && ( TRUE == hasRecoverFromFaultModeBeenSet() ) ) + { + HD_OP_MODE_T prevMode = getPreviousOperationMode(); + + requestNewOperationMode( prevMode ); + } break; default: