Hi,
I am trying to run a simple application on TI814x device and run into this issue. Whenever time dependent OS calls were made, the control would never return.
The same application works fine on TI816x device.
I think i am missing something very basic, just unable to figure out. Could you please help me out. Below is the configuration file that i am using.
Thanks,Sujtih
/* var CurrentPlatform = java.lang.System.getenv("PLATFORM"); */
var CurrentPlatform = "ti814x-evm";
xdc.print("# !!! Current build platform is [" + CurrentPlatform + "] !!!" );
/* use modules */
var Task = xdc.useModule("ti.sysbios.knl.Task");
var Idle = xdc.useModule("ti.sysbios.knl.Idle");
var BIOS = xdc.useModule("ti.sysbios.BIOS");
var Startup = xdc.useModule("xdc.runtime.Startup");
var SysStd = xdc.useModule("xdc.runtime.SysStd");
var System = xdc.useModule("xdc.runtime.System");
var Log = xdc.useModule("xdc.runtime.Log");
var Assert = xdc.useModule("xdc.runtime.Assert");
var Main = xdc.useModule("xdc.runtime.Main");
var Memory = xdc.useModule("xdc.runtime.Memory");
/* var Program = xdc.useModule("xdc.cfg.Program"); */
var Diags = xdc.useModule("xdc.runtime.Diags");
var Semaphore = xdc.useModule("ti.sysbios.knl.Semaphore");
var HeapMem = xdc.useModule("ti.sysbios.heaps.HeapMem");
var HeapBuf = xdc.useModule("ti.sysbios.heaps.HeapBuf");
var Clock = xdc.useModule("ti.sysbios.knl.Clock");
var Timer = xdc.useModule("ti.sysbios.timers.dmtimer.Timer");
var Timestamp = xdc.useModule("xdc.runtime.Timestamp");
var Load = xdc.useModule('ti.sysbios.utils.Load');
var Hwi = xdc.useModule('ti.sysbios.hal.Hwi');
var SyncSem = xdc.useModule('ti.sysbios.syncs.SyncSem');
/* var AMMU = xdc.useModule('ti.sysbios.family.arm.a8.Mmu'); */
/* var Cache = xdc.useModule('ti.sysbios.hal.unicache.Cache'); */
var Cache = xdc.useModule('ti.sysbios.family.arm.a8.Cache');
var Mmu = xdc.useModule('ti.sysbios.family.arm.a8.Mmu');
var memmap = Program.cpu.memoryMap;
var DDR = null;
/* Clock tick in microseconds */
Clock.tickPeriod = 1000;
/* Stack size when NULL is passed as stack during TSK create */
Task.defaultStackSize = 0x4000;
Memory.defaultHeapSize = 0x15000;
/* ISR/SWI stack */
/* Program.stack = 0x4000; */
/* Heap used when creating semaphore's, TSK's or malloc() ... */
/* Program.heap = 0x15000; */
Main.common$.diags_ASSERT = Diags.ALWAYS_ON;
Main.common$.diags_INTERNAL = Diags.ALWAYS_ON;
/******************0x4000 0000 -> 0x6000 0000 ********************************/
// Enable the cache
Cache.enableCache = true;
// Enable the MMU (Required for L1/L2 data caching)
Mmu.enableMMU = true;
// descriptor attribute structure
var attrs = {
type: Mmu.FirstLevelDesc_SECTION, // SECTION descriptor
bufferable: false, // bufferable
cacheable: false, // cacheable
};
// Set the descriptor for each entry in the address range
for (var i=0x40000000; i < 0x60000000; i = i + 0x00100000) {
// Each 'SECTION' descriptor entry spans a 1MB address range
Mmu.setFirstLevelDescMeta(i, i, attrs);
}
// Find DDR in memory map
for (var i=0; i < memmap.length; i++) {
if (memmap[i].name == "DDR3_HOST") {
DDR = memmap[i];
}
}
// Place the MMU table in the DDR memory segment if it exists
if (DDR != null) {
var sectionName = "ti.sysbios.family.arm.a8.mmuTableSection";
Program.sectMap[sectionName] = new Program.SectionSpec();
Program.sectMap[sectionName].type = "NOINIT";
Program.sectMap[sectionName].loadSegment = "DDR3_HOST";
}
else {
print("No DDR memory segment was found");
}
/******************0x8000 0000 -> 0xA000 0000 ********************************/
// descriptor attribute structure
var attrs = {
type: Mmu.FirstLevelDesc_SECTION, // SECTION descriptor
bufferable: true, // bufferable
cacheable: true, // cacheable
};
// Set the descriptor for each entry in the address range
for (var i=0x80000000; i < 0xA0000000; i = i + 0x00100000) {
// Each 'SECTION' descriptor entry spans a 1MB address range
Mmu.setFirstLevelDescMeta(i, i, attrs);
}
// Find DDR in memory map
for (var i=0; i < memmap.length; i++) {
if (memmap[i].name == "DDR3_HOST") {
DDR = memmap[i];
}
}
// Place the MMU table in the DDR memory segment if it exists
if (DDR != null) {
var sectionName = "ti.sysbios.family.arm.a8.mmuTableSection";
Program.sectMap[sectionName] = new Program.SectionSpec();
Program.sectMap[sectionName].type = "NOINIT";
Program.sectMap[sectionName].loadSegment = "DDR3_HOST";
}
else {
print("No DDR memory segment was found");
}