Index: firmware/App/Services/SystemCommMessages.c =================================================================== diff -u -rc9d31dbec2547fe2779ecc61d6be089f37da7d3f -rbe5079c95b05c303878763b458dc0854a600317e --- firmware/App/Services/SystemCommMessages.c (.../SystemCommMessages.c) (revision c9d31dbec2547fe2779ecc61d6be089f37da7d3f) +++ firmware/App/Services/SystemCommMessages.c (.../SystemCommMessages.c) (revision be5079c95b05c303878763b458dc0854a600317e) @@ -1,20 +1,19 @@ -/************************************************************************** - * - * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. - * - * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN - * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. - * - * @file SystemComm.c - * - * @date 10-Oct-2019 - * @author S. Nash - * - * @brief SystemComm service module. Provides system message communication \n - * functionality. Messages can be queued for transmission. Incoming messages \n - * are processed. - * - **************************************************************************/ +/************************************************************************** +* +* Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. +* +* THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN +* WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. +* +* @file SystemCommMessages.c +* +* @author (last) Sean Nash +* @date (last) 29-Jun-2020 +* +* @author (original) Dara Navaei +* @date (original) 05-Nov-2019 +* +***************************************************************************/ #include // for memcpy() @@ -758,12 +757,14 @@ { BOOL result = FALSE; - if ( message->hdr.payloadLen == sizeof(RESERVOIR_ID_T) ) + if ( message->hdr.payloadLen == sizeof(U32) ) { RESERVOIR_ID_T reservoirID; + U32 resID; result = TRUE; - memcpy( &reservoirID, message->payload, sizeof(RESERVOIR_ID_T) ); + memcpy( &resID, message->payload, sizeof(U32) ); + reservoirID = (RESERVOIR_ID_T)resID; setActiveReservoirCmd( reservoirID ); } sendAckResponseMsg( (MSG_ID_T)message->hdr.msgID, COMM_BUFFER_OUT_CAN_DG_2_HD, result );