I am developing code for C6678 involving multicore communications/synchronization using tool chain listed below:
MCSDK: 2.0.1.12
C6678 PDK: 1.0.0.12
IPC: 1.23.0.26
Sys/BIOS: 6.32.01.38
XDC: 3.22.01.21
TI Compiler: 7.3.0
CCS: 5.0.3.00028
I encountered a problem, which is narrowed down to the host interrupt to eventId map of CpIntc. The map follows the specs of C6670 even though my project is configured to use C6678 as target platform.
I would be very grateful for being told whether this is a development tool/library problem or I did something wrong.
The host to event map and the cpp and cfg files used to generate the map are listed at the end of this posting.
Dongning
------------ host to event map ----------------------
[C66xx_0] hostInt(0), eventId(56) [C66xx_0] hostInt(1), eventId(57) [C66xx_0] hostInt(2), eventId(58) [C66xx_0] hostInt(3), eventId(59) [C66xx_0] hostInt(4), eventId(60) [C66xx_0] hostInt(5), eventId(61) [C66xx_0] hostInt(6), eventId(62) [C66xx_0] hostInt(7), eventId(63) [C66xx_0] hostInt(8), eventId(74) [C66xx_0] hostInt(9), eventId(75) [C66xx_0] hostInt(10), eventId(76) [C66xx_0] hostInt(11), eventId(77) [C66xx_0] hostInt(12), eventId(92) [C66xx_0] hostInt(13), eventId(93) [C66xx_0] hostInt(14), eventId(94) [C66xx_0] hostInt(15), eventId(95) [C66xx_0] hostInt(16), eventId(255) ----------- cpp file ------------------------ #include <xdc/runtime/System.h> if(0 == coreId) } Int main(Int argc, Char* argv[]) return (0); --------------------- cfg file --------------------------------- var Settings = xdc.useModule('ti.csl.Settings'); var MultiProc = xdc.useModule('ti.sdo.utils.MultiProc'); var Ipc = xdc.useModule('ti.sdo.ipc.Ipc'); var BIOS = xdc.useModule('ti.sysbios.BIOS'); var tsk0 = Task.create('&tsk0_func'); Ipc.procSync = Ipc.ProcSync_ALL; var SHAREDMEM = 0x0C000000; var SharedRegion = xdc.useModule('ti.sdo.ipc.SharedRegion');
#include <ti/ipc/Ipc.h>
#include <ti/ipc/MultiProc.h>
#include <ti/sysbios/BIOS.h>
#include <ti/sysbios/knl/Task.h>
#include <ti/sysbios/family/c66/tci66xx/CpIntc.h>
extern "C" Void tsk0_func(UArg arg0, UArg arg1)
{
int coreId = MultiProc_self();
CpIntc_Module_startup(0);
{
for(int i = 0; i < 17; ++i)
{
Int eventId = CpIntc_getEventId(i);
System_printf("hostInt(%d), eventId(%d)\n", i, eventId);
}
}
{
Int status = Ipc_start();
if (status < 0) {
System_abort("Ipc_start failed\n");
}
BIOS_start();
}
switch (Program.platformName) {
case "ti.sdo.ipc.examples.platforms.evm6670.core0":
var nameList = ["CORE0", "CORE1", "CORE2", "CORE3"];
break;
case "ti.sdo.ipc.examples.platforms.evm6678.core0":
var nameList = ["CORE0", "CORE1", "CORE2", "CORE3",
"CORE4", "CORE5", "CORE6", "CORE7"];
break;
case "ti.platforms.evm6678":
var nameList = ["CORE0", "CORE1", "CORE2", "CORE3",
"CORE4", "CORE5", "CORE6", "CORE7"];
break;
default:
throw("Platform " + Program.platformName + " not supported by this example");
break;
}
var Error = xdc.useModule('xdc.runtime.Error');
var CpIntc = xdc.useModule('ti.sysbios.family.c66.tci66xx.CpIntc');
MultiProc.setConfig(null, nameList);
var System = xdc.useModule('xdc.runtime.System');
var SysStd = xdc.useModule('xdc.runtime.SysStd');
System.SupportProxy = SysStd;
BIOS.heapSize = 0x8000;
var Task = xdc.useModule('ti.sysbios.knl.Task');
tsk0.instance.name = "tsk0";
var SHAREDMEMSIZE = 0x00200000;
SharedRegion.setEntryMeta(0,
{ base: SHAREDMEM,
len: SHAREDMEMSIZE,
ownerProcId: 0,
isValid: true,
name: "DDR2 RAM",
});