Index: firmware/App/Services/SystemCommMessages.c =================================================================== diff -u -r031091f5f48c6a096ee954c5ef2633295bc0f3b6 -r7e4025c730935b8e857fc999f70ef957e8ecec41 --- firmware/App/Services/SystemCommMessages.c (.../SystemCommMessages.c) (revision 031091f5f48c6a096ee954c5ef2633295bc0f3b6) +++ firmware/App/Services/SystemCommMessages.c (.../SystemCommMessages.c) (revision 7e4025c730935b8e857fc999f70ef957e8ecec41) @@ -94,10 +94,10 @@ static volatile U16 nextSeqNo = 1; ///< Next sequence number. /// List of message IDs that are requested not to be transmitted. static BLOCKED_MSGS_DATA_T blockedMessagesForXmit = { 0, 0, 0, 0, 0, 0, 0, 0 }; - -// ********** private function prototypes ********** - -static BOOL sendTestAckResponseMsg( MSG_ID_T msgID, BOOL ack ); + +// ********** private function prototypes ********** + +static BOOL sendTestAckResponseMsg( MSG_ID_T msgID, BOOL ack ); static BOOL sendAckResponseMsg( MSG_ID_T msgID, COMM_BUFFER_T buffer, BOOL ack ); static BOOL sendUIResponseMsg( MSG_ID_T msgID, UI_RESPONSE_PAYLOAD_T *uiResponse ); @@ -416,7 +416,6 @@ return result; } - // *********************************************************************** // **************** Message Handling Helper Functions ******************** // *********************************************************************** @@ -450,21 +449,17 @@ *************************************************************************/ void handleRTCSyncFromHD( MESSAGE_T *message ) { - // TODO - remove the code below until the issue for the synchronization - // of the DG RTC to the HD RTC is resolved. -/* - // Only sync RTC to HD date/time when ... if ( TRUE == syncDG2HDDateTime() ) { if ( sizeof( RTC_DATA_T ) == message->hdr.payloadLen ) { RTC_DATA_T epoch; memcpy( &epoch, message->payload, sizeof( RTC_DATA_T ) ); + isEpochValid ( epoch.epochTime ); setRTCEpoch( epoch.epochTime ); } } -*/ } /*********************************************************************//** @@ -3695,37 +3690,6 @@ } /*********************************************************************//** - * @brief - * The handleFansRPMOverride function handles a request to override a fans RPM value. - * @details Inputs: none - * @details Outputs: message handled - * @param message a pointer to the message to handle - * @return none - *************************************************************************/ -void handleFansRPMOverride( MESSAGE_T *message ) -{ - TEST_OVERRIDE_ARRAY_PAYLOAD_T payload; - BOOL result = FALSE; - - // verify payload length - if ( sizeof(TEST_OVERRIDE_ARRAY_PAYLOAD_T) == message->hdr.payloadLen ) - { - memcpy( &payload, message->payload, sizeof(TEST_OVERRIDE_ARRAY_PAYLOAD_T) ); - if ( FALSE == payload.reset ) - { - result = testSetFanRPMOverride( payload.index, payload.state.f32 ); - } - else - { - result = testResetFanRPMOverride( payload.index ); - } - } - - // respond to request - sendTestAckResponseMsg( (MSG_ID_T)message->hdr.msgID, result ); -} - -/*********************************************************************//** * @brief * The handleStopDGRTCClock function handles a request to stop the RTC clock. * @details Inputs: none @@ -3864,10 +3828,41 @@ /*********************************************************************//** * @brief - * The handleTestFansRPMAlarmStartTimeOffsetRequest function handles a - * request to set the fans RPM alarm start time offset. + * The handleFansRPMOverride function handles a request to override a fans RPM value. * @details Inputs: none * @details Outputs: message handled + * @param message a pointer to the message to handle + * @return none + *************************************************************************/ +void handleFansRPMOverride( MESSAGE_T *message ) +{ + TEST_OVERRIDE_ARRAY_PAYLOAD_T payload; + BOOL result = FALSE; + + // verify payload length + if ( sizeof(TEST_OVERRIDE_ARRAY_PAYLOAD_T) == message->hdr.payloadLen ) + { + memcpy( &payload, message->payload, sizeof(TEST_OVERRIDE_ARRAY_PAYLOAD_T) ); + if ( FALSE == payload.reset ) + { + result = testSetFanRPMOverride( payload.index, payload.state.f32 ); + } + else + { + result = testResetFanRPMOverride( payload.index ); + } + } + + // respond to request + sendTestAckResponseMsg( (MSG_ID_T)message->hdr.msgID, result ); +} + +/*********************************************************************//** + * @brief + * The handleTestFansRPMAlarmStartTimeOverrideRequest function handles a + * request to override the fan RPM alarm start time. + * @details Inputs: none + * @details Outputs: message handled * @param message : a pointer to the message to handle * @return none *************************************************************************/ @@ -3890,7 +3885,6 @@ } /*********************************************************************//** - * @brief * The handleTestUsedAcidVolumeMLOverrideRequest function handles a * request to override the acid volume. * @details Inputs: none