Hi,
We're working on Concerto controller and we ould like to use IPC communication.
We've implemented two functions for sending a IPc messages to C28:
void IPCInterface::IPCSendData( Uint16 uiMessageType, char uiFCid, Uint16 uiDataSize, char *pDataBuff )
{
 MY_M3_C28_Msg  *mySendMessage;
 Uint16    loop, BufLoop;
 // Allocate the message
 mySendMessage = IPC_allocMsg ();
    if (mySendMessage == NULL) {
     System_printf("IPC alloc message failed\n");
    }
    mySendMessage->MsgType = uiMessageType;
    mySendMessage->Data[0] = uiFCid;
  for (loop = 1, BufLoop = 0; (loop < uiDataSize); loop++, BufLoop++)
 {
  mySendMessage->Data[loop] = pDataBuff[BufLoop];
 }
 // send the message
 IPC_sendMsg(mySendMessage);
}
void IPC_sendMsg ( MY_M3_C28_Msg *Message )
{
 Int              status;
    // Increment the msgID and set it
    msgId++;
    MessageQ_setMsgId(Message, msgId);
System_printf("Sending a message #%d to %s\n", msgId, remoteQueueName);
    // send the message to the remote processor
    status = MessageQ_put(remoteQueueId, (MessageQ_Msg)Message);
    if (status < 0) {
         System_abort("MessageQ_put had a failure/error\n");
    }
}
/******************************************************************************************************************************/
On M3 side I have two communications CAN and Ethernet, and I would like to transfer messages from Ethernet_receiveTsk and CAN_receiveTk via IPC to C28.
Shall I use " lock" before calling MessageQ_put. How can I be sure that messages are not got lost? How shall I manage it correctly?
thank you
Alla