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.

Can't modify read-only field

Hello.  I am trying to meld the fastcopytest application (from framework_components) into a dsplink application on an OMAPL137 EVM (using the latest DSP/BIOS 5.x release).  I believe to do this right I need to modify the .tcf and.tci files that come in the sample application I'm modifyting.

Below is my .tcf file.  I took all the major components that were being included in the sample's template and merged them in with the bits from fast copy test that seemed relevant.

I get the these errors:

js: "./dmalink.tcf", line 98: Can't modify read-only field

js: "./dmalink.tcf", line 99: Can't modify read-only field

I've tried a number of things, none have been successful.  Any ideas as to what's wrong here?

Thanks,

Chris

Begin .tcf...

/** ============================================================================
 *  @file   loop.tcf
 *
 *  @path   $(DSPLINK)/dsp/src/samples/dmalink/DspBios/5.XX/OMAPL1XXGEM/
 *
 *  @desc   Configuration file for the LOOP sample.
 *          This file defines platform-specific configuration details.
 *
 *  @ver    1.65.00.03
 *  ============================================================================
 */
/*  ============================================================================
 *  Load generic DSP/BIOS Link configuration
 *  ============================================================================
 */
var mem_ext = [];
mem_ext[0] = {
    comment: "16Mbytes of the DSP's off-chip memory",
    name: "SDRAM",
    base: 0xC3000000,
    len:  0x01000000,
    space: "code/data"
};
var device_regs = {
    l1PMode: "32k",
    l1DMode: "0k",      /* was 32k */
    l2Mode: "0k" 
};
var params = {
    clockRate: 300,
    catalogName: "ti.catalog.c6000",
    deviceName: "OMAPL137",
    regs: device_regs,
    mem: mem_ext
};
if(utils.loadPlatform.params != null) {
    var overrides = utils.loadPlatform.params;
    for(var i in params) {
        if (i in overrides) {
            params[i] = overrides[i];
        }
    }
}
utils.loadPlatform("ti.platforms.generic", params);
bios.disableRealTimeAnalysis(prog);
bios.enableMemoryHeaps(prog);
bios.disableRtdx(prog);
bios.enableTskManager(prog);
prog.module("GBL").ENABLEALLTRC     = false;
prog.module("GBL").PROCID           = parseInt(arguments[0]);
prog.module("GBL").C64PLUSCONFIGURE = true;
prog.module("GBL").C64PLUSL2CFG     = "32k";
prog.module("GBL").C64PLUSL1DCFG    = "0k";             /* was 32 k */
/*prog.module("GBL").C64PLUSMAR192to233 = 0x00000008;*/
var RESET_VECTOR = prog.module("MEM").create("RESET_VECTOR");
RESET_VECTOR.base           = 0xC3E00000;
RESET_VECTOR.len            = 0x00000080;
RESET_VECTOR.space          = "code/data";
RESET_VECTOR.createHeap     = false;
RESET_VECTOR.comment        = "RESET_VECTOR";
var SDRAM = prog.module("MEM").instance("SDRAM");
SDRAM.base                  = RESET_VECTOR.base + RESET_VECTOR.len;
SDRAM.len                   = 0xFFF80;
SDRAM.space                 = "code/data";
SDRAM.createHeap            = true;
SDRAM.heapSize              = 0x10000;
SDRAM.comment               = "SDRAM";
SDRAM.enableHeapLabel       = true;
SDRAM["heapLabel"]          = prog.extern("EXTERNALHEAP");
var DSPLINKMEM = prog.module("MEM").create("DSPLINKMEM");
DSPLINKMEM.base             = SDRAM.base + SDRAM.len;
DSPLINKMEM.len              = 0x30000;
DSPLINKMEM.createHeap       = false;
DSPLINKMEM.comment          = "DSPLINKMEM";
var POOLMEM = prog.module("MEM").create("POOLMEM");
POOLMEM.base                = DSPLINKMEM.base + DSPLINKMEM.len;
POOLMEM.len                 = 0xD0000;
POOLMEM.createHeap          = false;
POOLMEM.comment             = "POOLMEM";
/*var IRAM = prog.module("MEM").instance("IRAM");*/
bios.IRAM.base                   = 0x11800000;
bios.IRAM.len                    = 0x8000;
bios.IRAM.enableHeapLabel        = true;                         /* new */
bios.IRAM["heapLabel"]           = prog.extern("EXTMEMHEAP");    /* new */
bios.L1DSRAM.createHeap      = true;
bios.L1DSRAM.enableHeapLabel = true;
bios.L1DSRAM["heapLabel"]    = prog.extern("L1DHEAP");
bios.L1DSRAM.heapSize        = 0x800;
bios.MEM.STACKSIZE = 0x4000;
/*  ============================================================================
 *  Set all code and data sections to use SDRAM
 *  ============================================================================
 */
bios.setMemCodeSections(prog, SDRAM);
bios.setMemDataNoHeapSections(prog, SDRAM);
bios.setMemDataHeapSections(prog, SDRAM);
/*  ============================================================================
 *  MEM : Global
 *  ============================================================================
 */
prog.module("MEM").BIOSOBJSEG = SDRAM;
prog.module("MEM").MALLOCSEG  = SDRAM;
/*  ============================================================================
 *  TSK : Global
 *  ============================================================================
 */
prog.module("TSK").STACKSEG = SDRAM;
utils.importFile("dsplink-iom.tci") ;
utils.importFile("dsplink-dio.tci") ;
utils.importFile("dsplink-zcpydata-swi.tci");
//utils.importFile("dmalink.tci");
/*  ============================================================================
 *  LOG
 *  ============================================================================
 */
var trace = prog.module("LOG").create("trace");
trace.bufLen = 32;
/*  ============================================================================
 *  Enable POOL Manager
 *  ============================================================================
 */
bios.POOL.ENABLEPOOL = true;
/*  ============================================================================
 *  Generate cdb file...
 *  ============================================================================
 */
if (config.hasReportedError == false) {
    prog.gen();
}

  • Christopher,
    I can't tell exactly which lines are 98 and 99, but these two

    bios.IRAM.enableHeapLabel        = true;                         /* new */
    bios.IRAM["heapLabel"]                  = prog.extern("EXTMEMHEAP");    /* new */
    would cause such an error message if heap is not enabled for IRAM. If these are the lines from the error messages, try adding
    bios.IRAM.createHeap      = true;
    before them. Please let me know which lines are causing the error, if the ones above are not.
  • Sasha,

    Those are the lines in question, and yes, I do need the createHeap statement to make it compile..  Thanks for catching that! 

    Thanks,
    Chris 

  • So I try to use this image in my DSPlink application and it fails to load.  I get these messages:

    Failure [0x80008014] in [0x405] at line 322

    Failure [0x80008014] in [0x402] at line 2473

    Failure [0x80008014] in [0x402] at line 1077

    Failure [0x80008014] in [0x402] at line 1246

    Failure [0x80008014] in [0x300] at line 984

    PROC_load failed. Status = [0x80008014]

    I believe these are coming from DSPLink.  How can I determine what the error is?  I have a feeling it's related to my settings in the tcf.
    Thanks,
    Chris

  • Nevermind. Got it working! The fix was to add the line prog.module("MEM").ARGSSIZE = 150; to my tcf.

    I had left that out accidentally.

    Thanks,
    Chris 

  • Hi all,

    I am getting the exact error as above. I am using 5.5. I am trying to create example project(CCS3.1) of DM642 in CCS 5. With reference to CCS3.1 BIOS I created new BIOS in CCS 5. Few extra options existing in CCS5 which were not in CCS3.1 are neglected by me. Please help where I am wrng

    Kindly help

    The content of my bios file is as follows

    utils.loadPlatform("ti.platforms.evmDM642");

    /* The following DSP/BIOS Features are enabled. */

    bios.enableRealTimeAnalysis(prog);

    bios.enableRtdx(prog);

    bios.enableTskManager(prog);

    bios.MEM.NOMEMORYHEAPS = 0;

    bios.GBL.CALLUSERINITFXN = 1;

    bios.GBL.USERINITFXN = prog.extern("EVMDM642_init");

    bios.GBL.CLKOUT = 720.0000;

    bios.GBL.SPECIFYRTSLIB = 1;

    bios.GBL.RTSLIB = "cslDM642.lib";

    bios.GBL.C641XCONFIGUREL2 = 0;

    bios.MEM.NOMEMORYHEAPS = 0;

    bios.MEM.USEMPC = 0;

    bios.MEM.ARGSSEG = prog.get("SDRAM");

    bios.MEM.STACKSEG = prog.get("SDRAM");

    bios.MEM.GBLINITSEG = prog.get("SDRAM");

    bios.MEM.TRCDATASEG = prog.get("SDRAM");

    bios.MEM.SYSDATASEG = prog.get("SDRAM");

    bios.MEM.OBJSEG = prog.get("SDRAM");

    bios.MEM.BIOSSEG = prog.get("SDRAM");

    bios.MEM.SYSINITSEG = prog.get("SDRAM");

    bios.MEM.HWISEG = prog.get("SDRAM");

    bios.MEM.HWIVECSEG = prog.get("SDRAM");

    bios.MEM.RTDXTEXTSEG = prog.get("SDRAM");

    bios.MEM.TEXTSEG = prog.get("SDRAM");

    bios.MEM.SWITCHSEG = prog.get("SDRAM");

    bios.MEM.BSSSEG = prog.get("SDRAM");

    bios.MEM.FARSEG = prog.get("SDRAM");

    bios.MEM.CINITSEG = prog.get("SDRAM");

    bios.MEM.PINITSEG = prog.get("SDRAM");

    bios.MEM.CONSTSEG = prog.get("SDRAM");

    bios.MEM.DATASEG = prog.get("SDRAM");

    bios.MEM.CIOSEG = prog.get("SDRAM");

    bios.MEM.LOADBIOSSEG = prog.get("SDRAM");

    bios.MEM.LOADSYSINITSEG = prog.get("SDRAM");

    bios.MEM.LOADGBLINITSEG = prog.get("SDRAM");

    bios.MEM.LOADTRCDATASEG = prog.get("SDRAM");

    bios.MEM.LOADTEXTSEG = prog.get("SDRAM");

    bios.MEM.LOADSWITCHSEG = prog.get("SDRAM");

    bios.MEM.LOADCINITSEG = prog.get("SDRAM");

    bios.MEM.LOADPINITSEG = prog.get("SDRAM");

    bios.MEM.LOADCONSTSEG = prog.get("SDRAM");

    bios.MEM.LOADHWISEG = prog.get("SDRAM");

    bios.MEM.LOADHWIVECSEG = prog.get("SDRAM");

    bios.MEM.LOADRTDXTEXTSEG = prog.get("SDRAM");

    bios.MEM.ENABLELOADADDR = 0;

    bios.MEM.USERCOMMANDFILE = 0;

    bios.MEM.NOMEMORYHEAPS = 0;

    bios.MEM.instance("IRAM").base = 0x00000400;

    bios.MEM.instance("IRAM").len = 0x0002fc00;

    bios.MEM.instance("IRAM").heapSize = 0x00000000;

    bios.MEM.instance("IRAM").createHeap = 1;

    bios.MEM.instance("IRAM").enableHeapLabel = 1;

    bios.MEM.instance("IRAM").heapLabel = prog.extern("intHeap");

    bios.MEM.instance("SDRAM").createHeap = 1;

    bios.MEM.instance("SDRAM").heapSize = 0x00000000;

    bios.MEM.instance("SDRAM").enableHeapLabel = 1;

    bios.MEM.instance("SDRAM").heapLabel = prog.extern("extHeap");

    bios.MEM.BIOSOBJSEG = prog.get("SDRAM");

    bios.MEM.MALLOCSEG = prog.get("SDRAM");

    bios.MEM.NOMEMORYHEAPS = 0;

    bios.MEM.USERCOMMANDFILE = 0;

    bios.MEM.NOMEMORYHEAPS = 0;

    // !GRAPHICAL_CONFIG_TOOL_SCRIPT_INSERT_POINT!

    prog.gen();