IPC API _MAX_MSG_SIZE always 16


#1

Hello,

I’ve been using the framework 18.6.4 on the FX30S and I ended up running into an issue while developing an IPC application.
Whenever I try to use a REFERENCE on any function in my API, I get the following error when I call that function from another application.

Assert Failed: ‘le_pack_PackReference( &_msgBufPtr, &_msgBufSize, CANSampleRef )’

Checking deeper inside the ifgen generated server.c and message.c files I found out that the definition of the message buffer is always being set to 16 bytes (#define _MAX_MSG_SIZE 16). However, my referenced struct is of size 40 bytes.
What can I do to increase the IPC message buffer? Do I need to pass an array to increase the buffer? Am I missing any declaration that should set the message buffer to the right value? Is it possible to set it manually by changing the ifgen templates?

This is my API file:

REFERENCE Sample;

HANDLER NewSampleHandler
(
Sample CANSampleRef
);

EVENT NewSample
(
NewSampleHandler handler
);

How can I call the client handler function passing a struct to it?

I followed all the tutorials, but I could never find any example using REFERENCE and IPC together. I tested that the REFERENCE works fine locally, but when called remotely, it throws the error mentioned above.

Is it possible to use REFERENCE at all with IPC?

Thank you very much!
Caio Porto