Index: firmware/App/Controllers/SyringePump.c =================================================================== diff -u -rafe402337b84d8843c6ab544643fc403cb382c43 -r2f4f66fcceb986cc592693b08f1b57767cb1c515 --- firmware/App/Controllers/SyringePump.c (.../SyringePump.c) (revision afe402337b84d8843c6ab544643fc403cb382c43) +++ firmware/App/Controllers/SyringePump.c (.../SyringePump.c) (revision 2f4f66fcceb986cc592693b08f1b57767cb1c515) @@ -8,7 +8,7 @@ * @file SyringePump.c * * @author (last) Sean Nash -* @date (last) 01-Dec-2022 +* @date (last) 05-Feb-2023 * * @author (original) Sean Nash * @date (original) 04-Mar-2021 @@ -472,6 +472,18 @@ /*********************************************************************//** * @brief + * The resetPreLoadStatus function resets the syringe pump pre-load status. + * @details Inputs: none + * @details Outputs: syringePumpPreLoadCompleted + * @return none + *************************************************************************/ +void resetPreLoadStatus( void ) +{ + syringePumpPreLoadCompleted = FALSE; +} + +/*********************************************************************//** + * @brief * The stopSyringePump function requests syringe pump be stopped. * @details Inputs: none * @details Outputs: syringePumpSetRate, syringePumpState, heparinDeliveryState @@ -1392,7 +1404,6 @@ syringePumpPlungerFound = FALSE; syringeVolumeAdequate = FALSE; syringePumpPrimeCompleted = FALSE; - syringePumpPreLoadCompleted = FALSE; syringePumpVolumeRequired = 0.0F; // Clear insufficient volume alarm condition in case we're retracting to allow user to resolve alarm clearAlarmCondition( ALARM_ID_HD_SYRINGE_PUMP_NOT_ENOUGH_HEPARIN_ALARM ); @@ -1512,10 +1523,9 @@ syringePumpVolumeDelivered.data = 0.0; syringePumpSafetyVolumeDelivered = 0.0; syringePumpVolumeStartPosition = pos; - syringePumpPreLoadCompleted = FALSE; - // Check estimated syringe volume needed for treatment vs. volume detected - if insufficient for treatment needs, alarm - if ( syringeVol >= txVolume ) + // Check estimated syringe volume needed for treatment vs. volume detected - if insufficient for treatment needs, alarm (check only applies in pre-tx mode) + if ( ( syringeVol >= txVolume ) || ( getCurrentOperationMode() != MODE_PRET ) ) { syringePumpPlungerFound = TRUE; syringeVolumeAdequate = TRUE; @@ -1574,7 +1584,6 @@ syringePumpVolumeDelivered.data = 0.0; syringePumpSafetyVolumeDelivered = 0.0; syringePumpVolumeStartPosition = syringePumpPosition.data; - syringePumpPreLoadCompleted = FALSE; } // Has syringe been removed?