Index: firmware/App/Modes/ModeStandby.c =================================================================== diff -u -r9442bd6040af2120640805cdaf2cdb7c59d0afa8 -rf1adb311cbf9bcf5863864d165f68e4a497ae627 --- firmware/App/Modes/ModeStandby.c (.../ModeStandby.c) (revision 9442bd6040af2120640805cdaf2cdb7c59d0afa8) +++ firmware/App/Modes/ModeStandby.c (.../ModeStandby.c) (revision f1adb311cbf9bcf5863864d165f68e4a497ae627) @@ -7,8 +7,8 @@ * * @file ModeStandby.c * -* @author (last) Vijay Pamula -* @date (last) 27-Jul-2026 +* @author (last) Varshini Nagabooshanam +* @date (last) 14-Aug-2026 * * @author (original) Sean Nash * @date (original) 01-Aug-2024 @@ -30,6 +30,7 @@ #include "ModeTreatment.h" #include "OperationModes.h" #include "Switches.h" +#include "SyringePump.h" #include "SystemCommTD.h" #include "SyringePump.h" #include "TxParams.h" @@ -180,26 +181,26 @@ * then transitions to Wait For Treatment after homing completes and * then initiates homing of pumps and valves and transitions to the * wait for treatment state. - * @details \b Inputs: - * @details \b Outputs: + * @details \b Inputs: homingInitiated + * @details \b Outputs: homingInitiated * @return next state of the standby mode state machine *************************************************************************/ static TD_STANDBY_STATE_T handleStandbyModeStartState( void ) { TD_STANDBY_STATE_T state = STANDBY_START_STATE; // If we haven't already initiated homing of actuators, initiate now - if ( homingInitiated != TRUE ) + if ( FALSE == homingInitiated ) { - - // Home pumps and valves + // Home Standby pinch valves. homeValve( H1_VALV, FALSE, TRUE ); homeValve( H19_VALV, FALSE, TRUE ); if ( FALSE == isSyringePumpHome() ) { retractSyringePump(); } + homingInitiated = TRUE; } else @@ -568,9 +569,11 @@ signalBloodPumpHardStop(); stopSyringePump(); - // Set valves to safe positions + // Set air trap valves to safe positions set3WayValveState( H13_VALV, VALVE_3WAY_COMMON_TO_CLOSED_STATE ); set3WayValveState( H20_VALV, VALVE_3WAY_COMMON_TO_CLOSED_STATE ); + + // Set pinch valves to safe positions setValvePosition( H1_VALV, VALVE_POSITION_C_CLOSE ); setValvePosition( H19_VALV, VALVE_POSITION_C_CLOSE ); }