Index: firmware/App/Services/SystemCommMessages.c =================================================================== diff -u -r9426334142cbfdea9ee99e3040fc08ff0247da7b -reae0635792a827b7cf9197cf6f6e253f2a094260 --- firmware/App/Services/SystemCommMessages.c (.../SystemCommMessages.c) (revision 9426334142cbfdea9ee99e3040fc08ff0247da7b) +++ firmware/App/Services/SystemCommMessages.c (.../SystemCommMessages.c) (revision eae0635792a827b7cf9197cf6f6e253f2a094260) @@ -2770,7 +2770,7 @@ } else { - requestConcentratePumpOff( ( CONCENTRATE_PUMPS_T )payload.index ); + requestConcentratePumpOff( ( CONCENTRATE_PUMPS_T )payload.index, FALSE ); } } @@ -3893,4 +3893,93 @@ sendTestAckResponseMsg( (MSG_ID_T)message->hdr.msgID, result ); } +/*********************************************************************//** +* The handleTestDGConcPumpParkStatusOverrideRequest function handles a +* request to override the parked status of a given concentrate pump. +* @details Inputs: none +* @details Outputs: message handled +* @param message a pointer to the message to handle +* @return none +*************************************************************************/ +void handleTestDGConcPumpParkStatusOverrideRequest( 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 = testSetConcentratePumpParkedOverride( payload.index, (U16)payload.state.u32 ); + } + else + { + result = testResetConcentratePumpParkedOverride( payload.index ); + } + } + + // respond to request + sendTestAckResponseMsg( (MSG_ID_T)message->hdr.msgID, result ); +} + +/*********************************************************************//** +* The handleTestDGConcPumpParkFaultStatusOverrideRequest function handles a +* request to override the park faulted status of a given concentrate pump. +* @details Inputs: none +* @details Outputs: message handled +* @param message a pointer to the message to handle +* @return none +*************************************************************************/ +void handleTestDGConcPumpParkFaultStatusOverrideRequest( 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 = testSetConcentratePumpParkCmdFaultedOverride( payload.index, (U16)payload.state.u32 ); + } + else + { + result = testResetConcentratePumpParkCmdFaultedOverride( payload.index ); + } + } + + // respond to request + sendTestAckResponseMsg( (MSG_ID_T)message->hdr.msgID, result ); +} + +/*********************************************************************//** +* The handleTestDGConcPumpParkCommandRequest function handles a command +* to park a given concentrate pump. +* @details Inputs: none +* @details Outputs: message handled +* @param message a pointer to the message to handle +* @return none +*************************************************************************/ +void handleTestDGConcPumpParkCommandRequest( MESSAGE_T *message ) +{ + U32 pumpIdx; + BOOL result = FALSE; + + // verify payload length + if ( sizeof( U32 ) == message->hdr.payloadLen ) + { + memcpy( &pumpIdx, message->payload, sizeof( U32 ) ); + + result = testSetConcentratePumpParkCommand( pumpIdx ); + } + + // respond to request + sendTestAckResponseMsg( (MSG_ID_T)message->hdr.msgID, result ); +} + /**@}*/