Index: firmware/App/Controllers/DGInterface.c =================================================================== diff -u -r5fa843c018ed7c4b19013bbecf694b5a1596d166 -r06f7d5571359c1707fc32bb4e2f2e23f6ea32a2e --- firmware/App/Controllers/DGInterface.c (.../DGInterface.c) (revision 5fa843c018ed7c4b19013bbecf694b5a1596d166) +++ firmware/App/Controllers/DGInterface.c (.../DGInterface.c) (revision 06f7d5571359c1707fc32bb4e2f2e23f6ea32a2e) @@ -204,7 +204,7 @@ dgTdiTempCounter.prevTdiTempDownCounter = 0; dgTdiTempCounter.clearAlarmStartTime = 0; dgTdiTempCounter.dgPrevActiveReservoir = DG_RESERVOIR_2; - dgTdiTempCounter.dgTempActiveReservoir = DG_RESERVOIR_2; + dgTdiTempCounter.dgCurrentActiveReservoir = DG_RESERVOIR_2; } /**********************************************************************//** @@ -1285,7 +1285,7 @@ BOOL isTDiTempBelowDialysateTarget = ( dgDialysateTemp <= TDiLow ? TRUE : FALSE ); BOOL isTempBelowTrigger = (BOOL)( isTDITempBelowLowSafety || isTDiTempBelowDialysateTarget ); BOOL isTempAboveTrigger = (BOOL)( isTDiTempAboveLowSafety || isTDiTempAboveDialysateTarget ); - DG_RESERVOIR_ID_T CurrentActiveRes = getDGActiveReservoir(); + DG_RESERVOIR_ID_T currentActiveRes = getDGActiveReservoir(); #ifndef _RELEASE_ if ( getSoftwareConfigStatus( SW_CONFIG_DISABLE_DIALYSATE_TEMP_CHECK ) != SW_CONFIG_ENABLE_VALUE ) @@ -1314,7 +1314,7 @@ } // Tdi high temp alarm handling - if ( CurrentActiveRes != dgTdiTempCounter.dgPrevActiveReservoir ) + if ( currentActiveRes != dgTdiTempCounter.dgPrevActiveReservoir ) { //Increment up count when temperature is exceeded the defined threshold if ( TRUE == isTempAboveTrigger ) @@ -1329,8 +1329,8 @@ dgTdiTempCounter.tdiTempDownCounter++; } - //hold current reservoir in a temporary variable - dgTdiTempCounter.dgTempActiveReservoir = CurrentActiveRes; + //get current reservoir value + dgTdiTempCounter.dgCurrentActiveReservoir = currentActiveRes; } else { @@ -1348,8 +1348,8 @@ dgTdiTempCounter.prevTdiTempDownCounter = dgTdiTempCounter.tdiTempDownCounter; dgTdiTempCounter.tdiTempUpCounter = 0; dgTdiTempCounter.tdiTempDownCounter = 0; - // assign last temp reservoir to previous Active reservoir value once reservoir switch happened - dgTdiTempCounter.dgPrevActiveReservoir = dgTdiTempCounter.dgTempActiveReservoir; + // assign last current reservoir to previous Active reservoir value once reservoir switch happened + dgTdiTempCounter.dgPrevActiveReservoir = dgTdiTempCounter.dgCurrentActiveReservoir; } // check clear condition first