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.

TMS320F28377D: CPU2 to CPU1 IPC MSG RAM access

Part Number: TMS320F28377D
Other Parts Discussed in Thread: C2000WARE

Hello,

I need to exchange values between CPU2 and CPU1 (CPU2 write data and CPU1 get it)

To begin, I don't want to use all IPC functions, I just want to write directly in the message RAM (CPU2TOCPU1RAM).

  • On CPU2 side, I write directly two values on CPU2TOCPU1RAM.

CPU2 .cmd file : (not full file, just concerned lines) :

Fullscreen
1
2
3
CPU2TOCPU1RAM : origin = 0x03F800, length = 0x000400
BufferTest : > CPU2TOCPU1RAM PAGE = 1
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

CPU Main file (not full Main, just concerned lines) :

Fullscreen
1
2
3
4
5
#pragma DATA_SECTION(CPU2Values, "BufferTest");
Uint16 CPU2Values[2];
CPU2Values[0] = 0xAAAA;
CPU2Values[1] = 0x5555;
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

It works, I can find good values in the Memory Browser at the right address ( 0xAAAA at @0x03F800, 0x55555 at @0x03F801)

  • On CPU1 side, I did the same thing for the .cmd file :

Fullscreen
1
2
3
CPU2TOCPU1RAM : origin = 0x03F800, length = 0x000400
BufferTest : > CPU2TOCPU1RAM PAGE = 1
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

  • For the main :

Fullscreen
1
2
3
4
5
6
7
8
#pragma DATA_SECTION(CPU2Values, "BufferTest");
Uint16 CPU2Values[2];
unsigned int CPU2Value1 = 0;
unsigned int CPU2Value2 = 0;
CPU2Value1 = CPU2Values[0];
CPU2Value2 = CPU2Values[1];
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

In the Memory Browser, I can find good values at the right address ( 0xAAAA at @0x03F800, 0x55555 at @0x03F801), but all the four variables are equal to zero (CPU2Values[0],CPU2Values[1], CPU2Value1 and CPU2Value 2).

Do you know why ?

Thank you.

Regards,

  • Hi,

    Did you use C2000ware example, and modified it as shown above in your post? I just tested on my setup. I imported IPC example from C2000ware Driverlib example, and modified something similar. I am able to see the value changed in CPU1 memory browser, as I modify the value in CPU2 memory browser.