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.

TMS320F28388D: 应用问题

Part Number: TMS320F28388D
Other Parts Discussed in Thread: C2000WARE

我们用Ti的芯片28388时候,主要是在CPU1CM这两个核的通讯上面碰到问题比较多

下载的一对例子ipc_ex1_basic_c28x1ipc_ex1_basic_cm,都是采用IPC通讯,结果发现只要发送核发送一次、接收核读取一次后,接收核始终IPC_readCommand可以读到东西

好像一个消息FLAG之类的没有清掉,读取了还有,一直有

修改如下:

//ipc_ex1_basic_c28x1修改,用来查询接收

    while(1)
    {
        bool IsOK;
        IsOK = IPC_readCommand(IPC_CPU1_L_CM_R, IPC_FLAG1, IPC_ADDR_CORRECTION_ENABLE,
                        &command, &addr, &data);
        if(true == IsOK)
        {
            IswriteTrged = true;
            for(i=0; i<data; i++)
            {
                writeBuf[i] = *((uint32_t *)addr + i);
            }

            IPC_sendResponse(IPC_CPU1_L_CM_R, TEST_PASS);
            IPC_ackFlagRtoL(IPC_CPU1_L_CM_R, IPC_FLAG0);
            IPC_clearFlagLtoR(IPC_CPU1_L_CM_R, IPC_FLAG_ALL);
        }
    }

 

//ipc_ex1_basic_cm修改,writeTrg触发发送

    while(1)
    {
        if(1 == writeTrg)
        {
            IPC_sendCommand(IPC_CM_L_CPU1_R, IPC_FLAG1, IPC_ADDR_CORRECTION_ENABLE,
                            IPC_CMD_WRITE_MEM, (uint32_t)writeBuf, 10);
            writeTrg = 0;
        }
    }