Index: firmware/App/Controllers/DrainPump.c =================================================================== diff -u -r31aa23b12f37b9d16b5160369ccb7dab6c6eca4d -r8defcfa32034c4068b733930c2e8b0989c55daba --- firmware/App/Controllers/DrainPump.c (.../DrainPump.c) (revision 31aa23b12f37b9d16b5160369ccb7dab6c6eca4d) +++ firmware/App/Controllers/DrainPump.c (.../DrainPump.c) (revision 8defcfa32034c4068b733930c2e8b0989c55daba) @@ -119,7 +119,8 @@ static DRAIN_PUMP_STATE_T pendingDrainPumpCmd = DRAIN_PUMP_OFF_STATE; ///< Delayed (pending) drain pump command. static F32 pendingDrainPumpCmdTarget = 0.0; ///< Delayed (pending) drain pump command target (rpm or PSI depending on command). static U32 pendingDrainPumpCmdCountDown = 0; ///< Delayed (pending) drain pump command count down timer (in task intervals). -static DG_DRAIN_LINE_VOLUME_T drainLineVolumeRecord; +static DG_DRAIN_LINE_VOLUME_T drainLineVolumeRecord; ///< Drain line volume record. +static DG_DRAIN_PUMP_CAL_RECORD_T drainPumpCalRecord; ///< Drain pump calibration record. /// ADC to RPM conversion coefficient or RPM to ADC conversion. static const F32 CONVERSION_COEFF = SEC_PER_MIN / ( 2 * TOGGLE_PERIOD_RESOLUTION_SECONDS * ROTATIONAL_TO_TOGGLE_PERIOD_CONVERSION ); @@ -446,11 +447,15 @@ SELF_TEST_STATUS_T execDrainPumpSelfTest( void ) { SELF_TEST_STATUS_T result = SELF_TEST_STATUS_IN_PROGRESS; + BOOL calStatus = FALSE; // This is only one record the number of items to check is 0 since the get NV data function does not do a for loop to check the calibration time - BOOL calStatus = getNVRecord2Driver( GET_CAL_DRAIN_LINE_VOLUME_RECORD, (U08*)&drainLineVolumeRecord, sizeof( DG_DRAIN_LINE_VOLUME_T ), 0, - ALARM_ID_DG_DRAIN_LINE_VOLUME_INVALID_CAL_RECORD ); + calStatus |= getNVRecord2Driver( GET_CAL_DRAIN_LINE_VOLUME_RECORD, (U08*)&drainLineVolumeRecord, sizeof( DG_DRAIN_LINE_VOLUME_T ), 0, + ALARM_ID_DG_DRAIN_LINE_VOLUME_INVALID_CAL_RECORD ); + calStatus |= getNVRecord2Driver( GET_CAL_DRAIN_PUMP_RECORD, (U08*)&drainPumpCalRecord, sizeof( DG_DRAIN_PUMP_CAL_RECORD_T ), 0, + ALARM_ID_NO_ALARM ); + if ( TRUE == calStatus ) { result = SELF_TEST_STATUS_PASSED;