Index: firmware/App/Controllers/DrainPump.c =================================================================== diff -u -rb545c1e7b85d4bb6a7c79920877d1eaa7e36fdff -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Controllers/DrainPump.c (.../DrainPump.c) (revision b545c1e7b85d4bb6a7c79920877d1eaa7e36fdff) +++ firmware/App/Controllers/DrainPump.c (.../DrainPump.c) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -422,7 +422,7 @@ checkPersistentAlarm( ALARM_ID_DRAIN_PUMP_RPM_OUT_OF_RANGE, FALSE, getDrainPumpMeasuredRPM(), MAX_ALLOWED_OPEN_LOOP_RPM_OUT_OF_RANGE ); checkPersistentAlarm( ALARM_ID_DRAIN_PUMP_OFF_FAULT, FALSE, getDrainPumpMeasuredRPM(), MIN_DRAIN_PUMP_RPM ); checkPersistentAlarm( ALARM_ID_DG_DRAIN_PUMP_DIRECTION_INVALID, FALSE, getFPGADrainPumpDirection(), DRAIN_PUMP_FORWARD_DIR ); - break; + break; } #ifndef _RELEASE_ Index: firmware/App/Controllers/Fans.c =================================================================== diff -u -rad6b3443575d3f6bbac52237866e19a212d36bc1 -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Controllers/Fans.c (.../Fans.c) (revision ad6b3443575d3f6bbac52237866e19a212d36bc1) +++ firmware/App/Controllers/Fans.c (.../Fans.c) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -149,7 +149,7 @@ * @brief * The execFansSelfTest function executes the fans self test. * @details Inputs: none - * @details Outputs: isPOSTComplete, fansCalReocrd + * @details Outputs: fansCalReocrd * @return Status of self test *************************************************************************/ SELF_TEST_STATUS_T execFansSelfTest( void ) Index: firmware/App/Controllers/FlowSensors.c =================================================================== diff -u -r44f739bf3e9dfe0bfb5910a6a32fc4c5b1533af3 -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Controllers/FlowSensors.c (.../FlowSensors.c) (revision 44f739bf3e9dfe0bfb5910a6a32fc4c5b1533af3) +++ firmware/App/Controllers/FlowSensors.c (.../FlowSensors.c) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -319,12 +319,15 @@ { BOOL result = FALSE; - if ( TRUE == isTestingActivated() ) + if ( sensorId < NUM_OF_FLOW_SENSORS ) { - flowSensorStatus[ sensorId ].measuredFlowLPM.ovInitData = flowSensorStatus[ sensorId ].measuredFlowLPM.data; - flowSensorStatus[ sensorId ].measuredFlowLPM.ovData = flowLPM; - flowSensorStatus[ sensorId ].measuredFlowLPM.override = OVERRIDE_KEY; - result = TRUE; + if ( TRUE == isTestingActivated() ) + { + flowSensorStatus[ sensorId ].measuredFlowLPM.ovInitData = flowSensorStatus[ sensorId ].measuredFlowLPM.data; + flowSensorStatus[ sensorId ].measuredFlowLPM.ovData = flowLPM; + flowSensorStatus[ sensorId ].measuredFlowLPM.override = OVERRIDE_KEY; + result = TRUE; + } } return result; @@ -343,13 +346,16 @@ { BOOL result = FALSE; - if ( TRUE == isTestingActivated() ) + if ( sensorId < NUM_OF_FLOW_SENSORS ) { - flowSensorStatus[ sensorId ].measuredFlowLPM.data = flowSensorStatus[ sensorId ].measuredFlowLPM.ovInitData; - flowSensorStatus[ sensorId ].measuredFlowLPM.override = OVERRIDE_RESET; - flowSensorStatus[ sensorId ].measuredFlowLPM.ovInitData = 0.0; - flowSensorStatus[ sensorId ].measuredFlowLPM.ovData = 0.0; - result = TRUE; + if ( TRUE == isTestingActivated() ) + { + flowSensorStatus[ sensorId ].measuredFlowLPM.data = flowSensorStatus[ sensorId ].measuredFlowLPM.ovInitData; + flowSensorStatus[ sensorId ].measuredFlowLPM.override = OVERRIDE_RESET; + flowSensorStatus[ sensorId ].measuredFlowLPM.ovInitData = 0.0F; + flowSensorStatus[ sensorId ].measuredFlowLPM.ovData = 0.0F; + result = TRUE; + } } return result; Index: firmware/App/Controllers/FlowSensors.h =================================================================== diff -u -r44f739bf3e9dfe0bfb5910a6a32fc4c5b1533af3 -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Controllers/FlowSensors.h (.../FlowSensors.h) (revision 44f739bf3e9dfe0bfb5910a6a32fc4c5b1533af3) +++ firmware/App/Controllers/FlowSensors.h (.../FlowSensors.h) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -15,7 +15,6 @@ * ***************************************************************************/ - #ifndef _FLOW_SENSORS_H_ #define _FLOW_SENSORS_H_ @@ -31,7 +30,7 @@ */ // ********** public definitions ********** -#define MAX_FLOWRATE_LPM 2.00F ///< Maximum flow rate in L/min. +#define MAX_FLOWRATE_LPM 2.00F ///< Maximum flow rate in L/min. #define MIN_DIALYSATE_FLOWRATE_LPM 0.05F ///< Minimum target flow rate in L/min. /// Flow meters name Index: firmware/App/Controllers/Heaters.c =================================================================== diff -u -re398b4bd8bfacd05a021d6008dbccf3c38f2c5d1 -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Controllers/Heaters.c (.../Heaters.c) (revision e398b4bd8bfacd05a021d6008dbccf3c38f2c5d1) +++ firmware/App/Controllers/Heaters.c (.../Heaters.c) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -49,7 +49,7 @@ #define HEATERS_MAX_DUTY_CYCLE 1.00F ///< Heaters max duty cycle (100%). #define HEATERS_MIN_DUTY_CYCLE 0.00F ///< Heaters minimum duty cycle (0.00%). -#define HEATERS_DISINFECT_DUTY_CYCLE 0.60F ///< Heaters disinfect cycle. +#define HEATERS_DISINFECT_DUTY_CYCLE 0.70F ///< Heaters disinfect cycle. #define HEATERS_DISINFECT_TEMPERATURE_DRIFT_C 3.0F ///< Heaters disinfect temperature drift in C. #define HEATERS_MIN_EST_GAIN 0.2F ///< Heaters minimum estimation gain. #define HEATERS_MAX_EST_GAIN 5.0F ///< Heaters maximum estimation gain. @@ -871,8 +871,24 @@ *************************************************************************/ static void monitorHeatersVoltage( void ) { - F32 mainPriVoltage = getMonitoredLineLevel( MONITORED_LINE_24V_GND_MAIN_PRIM_HTR_V ); + F32 mainPriVoltage = getMonitoredLineLevel( MONITORED_LINE_24V_GND_MAIN_PRIM_HTR_V ); + F32 smallPriVoltage = getMonitoredLineLevel( MONITORED_LINE_24V_GND_SMALL_PRIM_HTR_V ); + F32 trimmerVoltage = getMonitoredLineLevel( MONITORED_LINE_24V_GND_TRIM_HTR_V ); + // Voltage to PWM is reverse. If PWM = 0 -> V = 24V + F32 mainPriDC = heatersStatus[ DG_PRIMARY_HEATER ].dutyCycle; + F32 smallPriDC = heatersStatus[ DG_PRIMARY_HEATER ].dutyCycle; + F32 trimmerDC = heatersStatus[ DG_TRIMMER_HEATER ].dutyCycle; + + // The expected voltage is the inverse of the duty cycle + F32 mainPriExpectedVoltage = HEATERS_MAX_OPERATING_VOLTAGE_V * ( 1.0F - mainPriDC ); + F32 smallPriExpectedVoltage = HEATERS_MAX_OPERATING_VOLTAGE_V * ( 1.0F - smallPriDC ); + F32 trimmerExpectedVoltage = HEATERS_MAX_OPERATING_VOLTAGE_V * ( 1.0F - trimmerDC ); + + BOOL isMainPriOut = FALSE; + BOOL isSmallPriOut = FALSE; + BOOL isTrimmerOut = FALSE; + #ifndef _RELEASE_ if ( SW_CONFIG_ENABLE_VALUE == getSoftwareConfigStatus( SW_CONFIG_ENABLE_V3_SYSTEM ) ) { @@ -887,22 +903,10 @@ //checkFPGAPersistentAlarms( FPGA_PERS_ERROR_MAIN_PRIMARY_HEATER_VOLTAGE_ADC, getFPGAHeaterGateADCErrorCount(), getFPGAHeaterGateADCReadCount() ); } - F32 smallPriVoltage = getMonitoredLineLevel( MONITORED_LINE_24V_GND_SMALL_PRIM_HTR_V ); - F32 trimmerVoltage = getMonitoredLineLevel( MONITORED_LINE_24V_GND_TRIM_HTR_V ); + isMainPriOut = ( fabs( mainPriExpectedVoltage - mainPriVoltage ) > HEATERS_VOLTAGE_TOLERANCE_V ? TRUE : FALSE ); + isSmallPriOut = ( fabs( smallPriExpectedVoltage - smallPriVoltage ) > HEATERS_VOLTAGE_TOLERANCE_V ? TRUE : FALSE ); + isTrimmerOut = ( fabs( trimmerExpectedVoltage - trimmerVoltage ) > HEATERS_VOLTAGE_TOLERANCE_V ? TRUE : FALSE ); - // Voltage to PWM is reverse. If PWM = 0 -> V = 24V - F32 mainPriDC = heatersStatus[ DG_PRIMARY_HEATER ].dutyCycle; - F32 smallPriDC = heatersStatus[ DG_PRIMARY_HEATER ].dutyCycle; - F32 trimmerDC = heatersStatus[ DG_TRIMMER_HEATER ].dutyCycle; - - F32 mainPriExpectedVoltage = HEATERS_MAX_OPERATING_VOLTAGE_V * ( 1.0F - mainPriDC ); - F32 smallPriExpectedVoltage = HEATERS_MAX_OPERATING_VOLTAGE_V * ( 1.0F - smallPriDC ); - F32 trimmerExpectedVoltage = HEATERS_MAX_OPERATING_VOLTAGE_V * ( 1.0F - trimmerDC ); - - BOOL isMainPriOut = ( fabs( mainPriExpectedVoltage - mainPriVoltage ) > HEATERS_VOLTAGE_TOLERANCE_V ? TRUE : FALSE ); - BOOL isSmallPriOut = ( fabs( smallPriExpectedVoltage - smallPriVoltage ) > HEATERS_VOLTAGE_TOLERANCE_V ? TRUE : FALSE ); - BOOL isTrimmerOut = ( fabs( trimmerExpectedVoltage - trimmerVoltage ) > HEATERS_VOLTAGE_TOLERANCE_V ? TRUE : FALSE ); - if ( getCurrentOperationMode() != DG_MODE_INIT ) { checkPersistentAlarm( ALARM_ID_DG_MAIN_PRIMARY_HEATER_VOLTAGE_OUT_OF_RANGE, isMainPriOut, mainPriDC, HEATERS_VOLTAGE_TOLERANCE_V ); Index: firmware/App/Controllers/LoadCell.c =================================================================== diff -u -rb0127e7ae2faa9cbdf4bf13e52ea4c526d38f411 -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Controllers/LoadCell.c (.../LoadCell.c) (revision b0127e7ae2faa9cbdf4bf13e52ea4c526d38f411) +++ firmware/App/Controllers/LoadCell.c (.../LoadCell.c) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -377,7 +377,7 @@ *************************************************************************/ F32 getLoadCellWeight( LOAD_CELL_ID_T loadCellID ) { - F32 result = 0.0; + F32 result = 0.0F; if ( loadCellID < NUM_OF_LOAD_CELLS ) { Index: firmware/App/Controllers/ROPump.c =================================================================== diff -u -r44f739bf3e9dfe0bfb5910a6a32fc4c5b1533af3 -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Controllers/ROPump.c (.../ROPump.c) (revision 44f739bf3e9dfe0bfb5910a6a32fc4c5b1533af3) +++ firmware/App/Controllers/ROPump.c (.../ROPump.c) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -457,7 +457,7 @@ *************************************************************************/ SELF_TEST_STATUS_T execROPumpSelfTest( void ) { - SELF_TEST_STATUS_T result = SELF_TEST_STATUS_IN_PROGRESS; + SELF_TEST_STATUS_T result = SELF_TEST_STATUS_PASSED; // TODO is there anything else needed in POST for the RO pump? @@ -495,7 +495,7 @@ * The getTargetROPumpPressurePSI function gets the current target RO pump * pressure. * @details Inputs: none - * @details Outputs: targetROPumpMaxPressure + * @details Outputs: none * @return the current target RO pump pressure in psi. *************************************************************************/ F32 getTargetROPumpPressurePSI( void ) Index: firmware/App/Controllers/UVReactors.c =================================================================== diff -u -rc470051d8185a96286083123bc65489747c391f7 -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Controllers/UVReactors.c (.../UVReactors.c) (revision c470051d8185a96286083123bc65489747c391f7) +++ firmware/App/Controllers/UVReactors.c (.../UVReactors.c) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -420,21 +420,19 @@ BOOL isVPIClosed = ( VALVE_STATE_CLOSED == getValveStateName( VPI ) ? TRUE : FALSE ); checkPersistentAlarm( ALARM_ID_DG_INLET_UV_REACTOR_ON_WITH_NO_FLOW, isVPIClosed, (F32)VALVE_STATE_CLOSED, (F32)VALVE_STATE_OPEN ); } - break; + break; case OUTLET_UV_REACTOR: { F32 flow = getMeasuredFlowRateLPM( RO_FLOW_SENSOR ); BOOL isFlowBelowMin = ( flow < MIN_RO_UV_FLOWRATE_LPM ? TRUE : FALSE ); checkPersistentAlarm( ALARM_ID_DG_OUTLET_UV_REACTOR_ON_WITH_NO_FLOW, isFlowBelowMin, flow, MIN_RO_UV_FLOWRATE_LPM ); } - break; + break; -#ifndef _VECTORCAST_ default: SET_ALARM_WITH_1_U32_DATA( ALARM_ID_DG_SOFTWARE_FAULT, SW_FAULT_ID_UV_REACTORS_INVALID_REACTOR_SELECTD ) break; -#endif } // Check if it has been requested to turn off a reactor Index: firmware/App/Controllers/Voltages.h =================================================================== diff -u -r08d27319b4b5f6f15e5de0758d9f528db1db6b3a -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Controllers/Voltages.h (.../Voltages.h) (revision 08d27319b4b5f6f15e5de0758d9f528db1db6b3a) +++ firmware/App/Controllers/Voltages.h (.../Voltages.h) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -78,9 +78,9 @@ F32 adc24VGndMainPrimHtr; ///< FPGA ADC channel for 24V to primary heater F32 adc24VGndSmallPrimHtr; ///< Internal ADC channel for 24V to secondary heater F32 adc24VGndTrimmerHtr; ///< Internal ADC channel for 24V to trimmer heater - F32 fpgaIntVCC; ///< FPGA internal VCC for 3V - F32 fpgaAuxVCC; ///< FPGA auxiliary VCC for 3V - F32 fpgaVPVN; ///< FPGA VPVN for 1V + F32 fpgaIntVCC; ///< FPGA internal VCC for 1V + F32 fpgaAuxVCC; ///< FPGA auxiliary VCC for 1.8V + F32 fpgaVPVN; ///< FPGA VPVN for 0V } VOLTAGES_DATA_PAYLOAD_T; // ********** public function prototypes ********** Index: firmware/App/DGCommon.h =================================================================== diff -u -rad6b3443575d3f6bbac52237866e19a212d36bc1 -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/DGCommon.h (.../DGCommon.h) (revision ad6b3443575d3f6bbac52237866e19a212d36bc1) +++ firmware/App/DGCommon.h (.../DGCommon.h) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -33,7 +33,6 @@ #ifndef _VECTORCAST_ // #define BOARD_WITH_NO_HARDWARE 1 // Build switch // #define TASK_TIMING_OUTPUT_ENABLED 1 // Build switch // re-purposes drain pump enable pin for task timing - #define DISABLE_ACK_ALARM 1 // Build switch #include #include Index: firmware/App/Modes/ModeFault.c =================================================================== diff -u -rbc4dcf8909e6c3fec54748ebd0cd9068e700061e -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Modes/ModeFault.c (.../ModeFault.c) (revision bc4dcf8909e6c3fec54748ebd0cd9068e700061e) +++ firmware/App/Modes/ModeFault.c (.../ModeFault.c) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -82,6 +82,10 @@ } setCPLDCleanLEDColor( CPLD_CLEAN_LED_OFF ); + + // Release RTC in case the RTC semaphore was not released prior to transitioning to fault mode. + // In fault mode, the non-volatile data mgmt POST might be run again so the RTC has to be available. Also, + // the RTC time is read every second which requires the semaphore. releaseSemaphore( SEMAPHORE_RTC ); return faultState; Index: firmware/App/Modes/ModeFill.c =================================================================== diff -u -r44f739bf3e9dfe0bfb5910a6a32fc4c5b1533af3 -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Modes/ModeFill.c (.../ModeFill.c) (revision 44f739bf3e9dfe0bfb5910a6a32fc4c5b1533af3) +++ firmware/App/Modes/ModeFill.c (.../ModeFill.c) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -76,7 +76,7 @@ #define PRIME_CONCENTRATE_LINES_TIME_OUT_MS ( 95 * MS_PER_SECOND ) ///< Time required to prime the concentrate lines. #define FLUSH_BUBBLES_PUMP_TIME_OUT_MS ( 2 * MS_PER_SECOND ) ///< RO pump on during flush bubble interval in ms. #define DIALYSATE_TEMPERATURE_TOLERANCE_C 2.0F ///< Dialysate temperature tolerance in degree C. -#define DIALYSATE_TEMPERATURE_SENSORS_MAX_DRIFT_C 1.0F ///< Dialysate temperature sensors maximum allowed drift in C. +#define DIALYSATE_TEMPERATURE_SENSORS_MAX_DEVIATION_C 1.0F ///< Dialysate temperature sensors maximum allowed deviation in C. #define DIALYSATE_TEMP_SNSRS_OUT_OF_RANGE_TIMEOUT_MS ( 10 * MS_PER_SECOND ) ///< Dialysate temperature sensors drift timeout in milliseconds. #define DATA_PUBLISH_COUNTER_START_COUNT 63 ///< Data publish counter start count. @@ -900,14 +900,14 @@ { F32 TDi = getTemperatureValue( TEMPSENSORS_INLET_DIALYSATE ); F32 TRo = getTemperatureValue( TEMPSENSORS_OUTLET_REDUNDANT ); - BOOL isDriftOut = ( fabs( TDi - TRo ) >= DIALYSATE_TEMPERATURE_SENSORS_MAX_DRIFT_C ? TRUE : FALSE ); + BOOL isDriftOut = ( fabs( TDi - TRo ) >= DIALYSATE_TEMPERATURE_SENSORS_MAX_DEVIATION_C ? TRUE : FALSE ); #ifndef _RELEASE_ if ( getSoftwareConfigStatus( SW_CONFIG_DISABLE_TEMPERATURE_SENSORS_ALARM ) != SW_CONFIG_ENABLE_VALUE ) #endif { checkPersistentAlarm( ALARM_ID_DG_DIALYSATE_TEMPERATURE_SENSORS_OUT_OF_RANGE, isDriftOut, fabs( TDi - TRo ), - DIALYSATE_TEMPERATURE_SENSORS_MAX_DRIFT_C ); + DIALYSATE_TEMPERATURE_SENSORS_MAX_DEVIATION_C ); } } Index: firmware/App/Services/AlarmMgmtSWFaults.h =================================================================== diff -u -rd8dbfa71fd70064ffe00d09ffa270f477c8f7af2 -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Services/AlarmMgmtSWFaults.h (.../AlarmMgmtSWFaults.h) (revision d8dbfa71fd70064ffe00d09ffa270f477c8f7af2) +++ firmware/App/Services/AlarmMgmtSWFaults.h (.../AlarmMgmtSWFaults.h) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -133,7 +133,7 @@ SW_FAULT_ID_ILLEGAL_MEM_ACCESS, SW_FAULT_ID_INVALID_CHEMICAL_BOTTLE_SELECTED, SW_FAULT_ID_INVALID_FPGA_SENSOR_GROUP_SELECTED, - SW_FAULT_ID_INVALID_FLOW_SENSOR_SELECTED, // 106 + SW_FAULT_ID_INVALID_FLOW_SENSOR_SELECTED, // 105 SW_FAULT_ID_INVALID_SERVICE_STATE_SELECTED, SW_FAULT_ID_INVALID_NV_RECORD_SELECTED, SW_FAULT_ID_WRITE_USAGE_INFO_TO_NV_FAILURE, Index: firmware/App/Services/Reservoirs.c =================================================================== diff -u -re6c4c61c793a91f9ed9dfe969e01bdeee565347d -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Services/Reservoirs.c (.../Reservoirs.c) (revision e6c4c61c793a91f9ed9dfe969e01bdeee565347d) +++ firmware/App/Services/Reservoirs.c (.../Reservoirs.c) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -157,9 +157,9 @@ NUM_OF_CAL_DATA_RSRVRS, ALARM_ID_DG_HEATING_INVALID_CAL_RECORD ); } + // If the mode is fault or it is standby and the RO volume has not been written already, write it if ( ( ( DG_MODE_FAUL == getCurrentOperationMode() ) || ( DG_MODE_STAN == getCurrentOperationMode() ) ) && ( FALSE == nvOps.hasROGenVolBeenWrittenToNV ) ) { - // If the mode is fault or it is standby and the RO volume has not been written already, write it DG_OP_MODE_T prevMode = getPreviousOperationMode(); switch( prevMode ) Index: firmware/App/Services/SystemComm.c =================================================================== diff -u -re6c4c61c793a91f9ed9dfe969e01bdeee565347d -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Services/SystemComm.c (.../SystemComm.c) (revision e6c4c61c793a91f9ed9dfe969e01bdeee565347d) +++ firmware/App/Services/SystemComm.c (.../SystemComm.c) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -25,6 +25,7 @@ #include "SystemComm.h" #include "Comm.h" #include "Interrupts.h" +#include "OperationModes.h" #include "Timers.h" #include "Utilities.h" #include "SystemCommMessages.h" @@ -772,8 +773,8 @@ for ( i = 0; i < PENDING_ACK_LIST_SIZE; i++ ) { // pending ACK expired? if ( ( TRUE == pendingAckList[ i ].used ) && ( TRUE == didTimeout( pendingAckList[ i ].timeStamp, MSG_NOT_ACKED_TIMEOUT_MS ) ) ) - { // if retries left, reset and resend pending message - if ( pendingAckList[ i ].retries > 0 ) + { // if retries left, reset and resend pending message. Do not retry when in POST since the UI might not still be responsive + if ( ( pendingAckList[ i ].retries > 0 ) && ( getCurrentOperationMode() != DG_MODE_INIT ) ) { // re-queue message for transmit pendingAckList[ i ].retries--; pendingAckList[ i ].timeStamp = getMSTimerCount(); @@ -785,9 +786,7 @@ U16 msgID; memcpy( &msgID, &pendingAckList[ i ].msg[ sizeof( U08 ) + sizeof( U16 ) ], sizeof( U16 ) ); -#ifndef DISABLE_ACK_ALARM SET_ALARM_WITH_1_U32_DATA( ALARM_ID_DG_CAN_MESSAGE_NOT_ACKED, (U32)msgID ); -#endif pendingAckList[ i ].used = FALSE; // take pending message off of list } } @@ -912,11 +911,8 @@ break; } -#ifndef _VECTORCAST_ // handle any test messages if tester has logged in successfully - // NOTE: END_OF_MSG_IDS = 65536 which is out of the range of a U16 so it is subtracted by 1. This is unreachable in development testing - if ( ( msgID > MSG_ID_FIRST_DG_TESTER_MESSAGE ) && ( msgID <= END_OF_MSG_IDS - 1 ) && ( TRUE == isTestingActivated() ) ) -#endif + if ( ( msgID > MSG_ID_FIRST_DG_TESTER_MESSAGE ) && ( TRUE == isTestingActivated() ) ) { switch ( msgID ) { Index: firmware/App/Services/SystemCommMessages.c =================================================================== diff -u -r8525a30b488d13d24af34379fe81d759026663bb -r696e732c9742535a58b9c65f243df7cd797d1423 --- firmware/App/Services/SystemCommMessages.c (.../SystemCommMessages.c) (revision 8525a30b488d13d24af34379fe81d759026663bb) +++ firmware/App/Services/SystemCommMessages.c (.../SystemCommMessages.c) (revision 696e732c9742535a58b9c65f243df7cd797d1423) @@ -548,13 +548,12 @@ { MESSAGE_T msg; DG_SERVICE_RECORD_T service; + U08 *payloadPtr = msg.payload; // Get the service record. There are no arrays of service to check and also, raise no alarm since the service record // has been already checked in POST getNVRecord2Driver( GET_SRV_RECORD, (U08*)&service, sizeof( DG_SERVICE_RECORD_T ), 0, ALARM_ID_NO_ALARM ); - U08 *payloadPtr = msg.payload; - // Create a message record blankMessage( &msg ); msg.hdr.msgID = MSG_ID_DG_SERVICE_SCHEDULE_DATA;