Using erpc in a frdmmcxn947, opening the ERPC_MESSAGE_LOGGING macro reported an error

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Using erpc in a frdmmcxn947, opening the ERPC_MESSAGE_LOGGING macro reported an error

Jump to solution
814 Views
yzs
Contributor I

HI, 

I'm using erpc in a frdm board and found that opening the ERPC_MESSAGE_LOGGING macro reported an error. The attached image shows the detailed error message.image-20241221154950008.png

 

 

Labels (1)
0 Kudos
Reply
1 Solution
751 Views
Celeste_Liu
NXP Employee
NXP Employee

Hello @yzs ,

You are welcome. If that reply answers your question, please click the "ACCEPT AS SOLUTION" button. Thank you!

BRs,

Celeste

View solution in original post

0 Kudos
Reply
3 Replies
770 Views
Celeste_Liu
NXP Employee
NXP Employee

Hello @yzs ,

Thanks for letting us know about this issue. 

I have indeed reproduced your issue. The `logMessage` function expects a parameter of the `MessageBuffer *` pointer type. However, the previous error message indicated that it was not possible to convert an ordinary `erpc::MessageBuffer` object into an `erpc::MessageBuffer*` pointer type. Therefore, the following workaround can be considered to solve this type mismatch problem: obtain a reference using the `getBufferRef` function and then pass the pointer by taking the address. The code modification is as follows:

In erpc_client_manager.cpp:

Celeste_Liu_0-1734934523832.png

Celeste_Liu_1-1734934533705.png

 

By modifying the above code, it can be compiled successfully.

Celeste_Liu_2-1734934552890.png

 

However, this approach may not be the optimal solution. I will submit a Jira ticket to the SW Team to further investigate this issue.

Thanks again for your post. Have a nice day~

BRs,

Celeste

0 Kudos
Reply
762 Views
yzs
Contributor I
Hello,
Thank you for answering that question.
BRs,
yzs
0 Kudos
Reply
752 Views
Celeste_Liu
NXP Employee
NXP Employee

Hello @yzs ,

You are welcome. If that reply answers your question, please click the "ACCEPT AS SOLUTION" button. Thank you!

BRs,

Celeste

0 Kudos
Reply