Index: firmware/App/Controllers/SyringePump.c =================================================================== diff -u -rcc74851d8c52b147dcaa0279d4e4a310525db77b -re08f11fd64eac113df59ce3e3786380104473837 --- firmware/App/Controllers/SyringePump.c (.../SyringePump.c) (revision cc74851d8c52b147dcaa0279d4e4a310525db77b) +++ firmware/App/Controllers/SyringePump.c (.../SyringePump.c) (revision e08f11fd64eac113df59ce3e3786380104473837) @@ -515,6 +515,7 @@ if ( ( syringePumpState != SYRINGE_PUMP_CONFIG_FORCE_SENSOR_STATE ) && ( syringePumpState != SYRINGE_PUMP_OFF_STATE ) ) { syringePumpState = SYRINGE_PUMP_OFF_STATE; + syringePumpSetRate = 0.0; } if ( ( HEPARIN_STATE_INITIAL_BOLUS == heparinDeliveryState ) || ( HEPARIN_STATE_DISPENSING == heparinDeliveryState ) ) { @@ -527,6 +528,7 @@ sendTreatmentLogEventData( HEPARIN_STOP_PAUSE_EVENT, syringePumpSetRate, 0.0 ); } heparinDeliveryState = HEPARIN_STATE_STOPPED; + syringePumpSetRate = 0.0; } syringePumpSetRate = 0.0; } @@ -645,6 +647,8 @@ *************************************************************************/ BOOL startHeparinBolus( void ) { + F32 bolusVol = getTreatmentParameterF32( TREATMENT_PARAM_HEPARIN_BOLUS_VOLUME ); + // If valid to start a bolus, kick it off if ( FALSE == isSyringePumpHome() ) { @@ -655,8 +659,12 @@ if ( ( TRUE == isSyringeDetected() ) && ( TRUE == syringePumpPrimeCompleted ) && ( SYRINGE_PUMP_OFF_STATE == syringePumpState ) && ( HEPARIN_STATE_STOPPED == heparinDeliveryState ) ) { - syringePumpSetRate = getHeprinBolusTargetRate(); - syringePumpBolusRequested = TRUE; + // if user set a Heparin bolus volume and not complete, start now + if ( ( bolusVol > 0.0F ) && ( getSyringePumpVolumeDelivered() < bolusVol ) ) + { + syringePumpSetRate = getHeprinBolusTargetRate(); + syringePumpBolusRequested = TRUE; + } } } else