This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

ping-pong messaging with MessageQ problem

Other Parts Discussed in Thread: SYSBIOS

Hello experts,

I have an intercore communication problem on C6616 simulator. I have setup a pjt in which core0 sends a message to core1^, and core1 sends it back to core0, for,say, 300 times. So I want to get a ping-pong messaging btw the two cores.

What happens is that for the first message (msg0) everything is fine. Then, core0 sends to core1 msg1 and I would expect the same as above but it is lost and never received by core1, until the MessageQ_get timer expires. 

The strange thing is that if I do only one-way communication everything is fine: core0 sends 300 messages to core1 and all are received; the same happens if core1 sends to core0. But if I setup ping-pong, it works only for the first message.

I have tried with one only heap for the two queues and also with two independent heaps, results are the same.

Any idea about what I could check?

Thanks in advance

Roberto

  • Roberto,

    I assume you are using BIOS and IPC?  If so, have you taken a look at the IPC examples?  There is an example called message_multicore that does something very similar to what you are trying to do.  The example round robins a message across all cores in the system but could easily be modified to do a ping-pong between two cores by changing the configuration to specify only two cores in the system.  Typically, the example for the evm667x can be found at:

    C:\Program Files\Texas Instruments\ipc_1_22_00_19\packages\ti\sdo\ipc\examples\multicore\evm667x

    If that doesn't help, my recommendation for debugging would be:

    1)  Set a breakpoint on the interrupt used by IPC for communication between the cores to make sure when core0 sends core1 msg1, that core1 actually received an interrupt and vice versa.  I think the default is interrupt vector 5.  The symbol you can try is:  ti_sysbios_family_c64p_Hwi5

    2) If the right interrupt is being triggered, then make sure that your Notify callback function is getting called. You can try putting a breakpoint on the symbol:  ti_sdo_ipc_transports_TransportShm_swiFxn__I

    3)  If the interrupt/notify mechanism is working (which it sounds like its working).  Then check the message to make sure you're doing a single messageQ_alloc and ping-ponging the same message around.

    Judah