Index: firmware/App/Services/SystemCommMessages.c =================================================================== diff -u -rd4a77f3ce8f62c8911b1f4f3a673be6de802f50b -r255e10103b009abce4489ebe0adda8d45137e2f1 --- firmware/App/Services/SystemCommMessages.c (.../SystemCommMessages.c) (revision d4a77f3ce8f62c8911b1f4f3a673be6de802f50b) +++ firmware/App/Services/SystemCommMessages.c (.../SystemCommMessages.c) (revision 255e10103b009abce4489ebe0adda8d45137e2f1) @@ -1989,19 +1989,19 @@ /*********************************************************************//** * @brief - * The sendMaxRORejectionRatioRequestToHD function handles sending the max RO - * rejection ratio request to HD + * The sendDGInstitutionalValuesRequestToHD function handles sending the + * request to the DG institutional values from HD * @details Inputs: none * @details Outputs: none * @return none *************************************************************************/ -void sendMaxRORejectionRatioRequestToHD( void ) +void sendDGInstitutionalValuesRequestToHD( void ) { MESSAGE_T msg; // Create a message record blankMessage( &msg ); - msg.hdr.msgID = MSG_ID_DG_MAX_RO_REJ_RATIO_FROM_HD_INSTIT_RECORD_REQUEST; + msg.hdr.msgID = MSG_ID_DG_INSTIT_VALUES_FROM_HD_INSTIT_RECORD_REQUEST; msg.hdr.payloadLen = 0; // Serialize the message (w/ sync, CRC, and appropriate CAN padding) and add serialized message data to appropriate comm buffer @@ -2010,23 +2010,24 @@ /*********************************************************************//** * @brief - * The handleMaxRORejectionResponseFromHDInstitRecord function handles receiving - * max RO rejection ratio response from HD institutional record + * The handleDGInstitutionalValuesResponseFromHDInstitRecord function handles + * receiving DG institutional values from HD institutional record * @details Inputs: none * @details Outputs: message handled * @param message a pointer to the message to handle * @return none *************************************************************************/ -void handleMaxRORejectionResponseFromHDInstitRecord( MESSAGE_T* message ) +void handleDGInstitutionalValuesResponseFromHDInstitRecord( MESSAGE_T* message ) { BOOL status = FALSE; - if ( message->hdr.payloadLen == sizeof(F32) ) + if ( message->hdr.payloadLen == sizeof(DG_INSTITUTIONAL_VALUES_T) ) { - F32 roRejectionRatio; + DG_INSTITUTIONAL_VALUES_T institValues; - memcpy( &roRejectionRatio, message->payload, sizeof(F32) ); - setMaxRORejectionRatio( roRejectionRatio ); + memcpy( &institValues, message->payload, sizeof(DG_INSTITUTIONAL_VALUES_T) ); + setMaxRORejectionRatio( institValues.maxRORejectionRatio ); + setMinInletWaterConductivityAlarmLimitUSPCM( institValues.minInletWaterCondAlarmLimitUSPCM ); status = TRUE; } @@ -5220,4 +5221,27 @@ sendTestAckResponseMsg( (MSG_ID_T)message->hdr.msgID, result ); } +/*********************************************************************//** + * @brief + * The handleTestEnableModeFillChemsTest function handles a request + * to enable the mode fill chemicals test. + * @details Inputs: none + * @details Outputs: message handled + * @param message a pointer to the message to handle + * @return none + *************************************************************************/ +void handleTestEnableModeFillChemsTest( MESSAGE_T* message ) +{ + BOOL result = FALSE; + + // verify payload length + if ( 0 == message->hdr.payloadLen ) + { + result = testSetEnableTestChemsCondValuesStatus(); + } + + // respond to request + sendTestAckResponseMsg( (MSG_ID_T)message->hdr.msgID, result ); +} + /**@}*/