Hi
I have tried to get the the "rpmsg_lite_str_echo_rtos" to work - and it works half the way...
I have compiled and loaded the example into the CM4 processor. And after booting the EVK, and entered "modprobe imx_rpmsg_tty" at the command line of the A7 processor, I'm greeted with a message in serial terminal for the M4 saying:
Nameservice sent, ready for incoming messages...
Get Message From Master Side : "hello world!" [len : 12]
If I send another message using: "echo test > /dev/ttyRPMSG30" this message is also received by the M4 processor - but I would expect the message to be echoed back to the A7 processor.
I have tried "cat /dev/ttyRPMSG30" and also made a little script to read from the virtual port, but in either case nothing is returned. Am I reading the echoed message correct?
The following code is from the "main_remote.c" of the example code.
memcpy(tx_buf, app_buf, len);
/* Echo back received message with nocopy send */
result = rpmsg_lite_send_nocopy(my_rpmsg, my_ept, remote_addr, tx_buf, len);
if (result != 0)
{
assert(false);
}
/* Release held RPMsg rx buffer */
result = rpmsg_queue_nocopy_free(my_rpmsg, rx_buf);
if (result != 0)
{
assert(false);
}
it seems that the function "rpmsg_lite_send_nocopy" should send the message back to the A7 core. The function is returning a "0" which means that it will never get into the two if sentences? I have not tried to follow the the function "rpmsg_lite_send_nocopy" to see which output it can give in which situations... But does a "0" mean the function did not successfully send the message?
BTW. why has the "multicore_examples" been removed from the latest SDK (SDK_24_12_00_EVK-MCIMX7ULP). The examples are included in SDK_2_16_000_EVK_MCIMX7ULP.