Index: firmware/App/Controllers/BloodLeak.c =================================================================== diff -u -rca8a4a4cf6d2c59d9296c3abdf314765550a2624 -rda8a230122d868cadb2513ac418017ade0dfddf5 --- firmware/App/Controllers/BloodLeak.c (.../BloodLeak.c) (revision ca8a4a4cf6d2c59d9296c3abdf314765550a2624) +++ firmware/App/Controllers/BloodLeak.c (.../BloodLeak.c) (revision da8a230122d868cadb2513ac418017ade0dfddf5) @@ -21,6 +21,7 @@ #include "AlarmMgmt.h" #include "BloodLeak.h" +#include "DialInFlow.h" #include "FPGA.h" #include "NVDataMgmtHDRecords.h" #include "OperationModes.h" @@ -930,7 +931,10 @@ bloodLeakStatus.data = getFPGABloodDetectProcessedStatus(); - if ( BLOOD_LEAK_NOT_DETECTED == getBloodLeakStatus() ) + // Check if the blood is not detected but at the same time the Dialin pump should be running to make sure we are in the + // blood recovery state of the treatment stop so the blood detection recovery is not done on the stagnant fluid + // NOTE: should we check of the measured flow is about 600 mL/min? + if ( ( BLOOD_LEAK_NOT_DETECTED == getBloodLeakStatus() ) && ( TRUE == isDialInPumpRunning() ) ) { if ( TRUE == didTimeout( bloodLeakRecoveryStartTimeMS, BLOOD_LEAK_DETECT_RECOVERY_MIN_TIME_MS ) ) {