Index: firmware/App/Modes/SelfTests.c =================================================================== diff -u -rcc067242d41776eb2a598212413e25df5a58b1fe -r83a8a0e1e8630939e6a173f1313cceb7f39e00dd --- firmware/App/Modes/SelfTests.c (.../SelfTests.c) (revision cc067242d41776eb2a598212413e25df5a58b1fe) +++ firmware/App/Modes/SelfTests.c (.../SelfTests.c) (revision 83a8a0e1e8630939e6a173f1313cceb7f39e00dd) @@ -359,6 +359,19 @@ selfTestStartTime = getMSTimerCount(); selfTestPreviousPublishDataTime = getMSTimerCount(); + // Pumps should be off + signalBloodPumpHardStop(); + signalDialInPumpHardStop(); + signalDialOutPumpHardStop(); + stopSyringePump(); + + // Set valves to default positions + setValveAirTrap( STATE_CLOSED ); + setValvePosition( VDI, VALVE_POSITION_A_INSERT_EJECT ); + setValvePosition( VDO, VALVE_POSITION_A_INSERT_EJECT ); + setValvePosition( VBA, VALVE_POSITION_A_INSERT_EJECT ); + setValvePosition( VBV, VALVE_POSITION_A_INSERT_EJECT ); + resetSelfTestsFlags(); } @@ -498,7 +511,6 @@ *************************************************************************/ void transitionToWetSelfTests() { - signalDialInPumpHardStop(); // turn off DPi that was on in previous dialysate bypass state wetSelfTestsResult = FALSE; currentWetSelfTestsState = WET_SELF_TESTS_START_STATE; settleStartTime = 0; @@ -508,6 +520,19 @@ selfTestStartTime = getMSTimerCount(); selfTestPreviousPublishDataTime = getMSTimerCount(); + // Pumps should be off + signalBloodPumpHardStop(); + signalDialInPumpHardStop(); + signalDialOutPumpHardStop(); + stopSyringePump(); + + // Set valves to default positions + setValveAirTrap( STATE_CLOSED ); + setValvePosition( VDI, VALVE_POSITION_C_CLOSE ); + setValvePosition( VDO, VALVE_POSITION_C_CLOSE ); + setValvePosition( VBA, VALVE_POSITION_C_CLOSE ); + setValvePosition( VBV, VALVE_POSITION_C_CLOSE ); + resetSelfTestsFlags(); }