Dsk5416_ddk.tci
上传用户:dahaojd
上传日期:2008-01-29
资源大小:14357k
文件大小:3k
- /*
- * ======== Dsk5416_ddk.tci ========
- * This file is used for textual configuration of DSP/BIOS as an alternative
- * or in addition to the traditional graphical configuration tool (GCONF).
- * For more information on textual configuration and the TCONF utility,
- * please refer to the DSP/BIOS TextConf User's Guide (SPRU007).
- */
- /*
- * Create an empty object and call it with the getProgObjs method to
- * create global variables for every Module and Instance object.
- * For example, instead of
- * prog.module("LOG").instance("LOG_system").buflen = <some value>;
- * we can simply say
- * tibios.LOG_system.buflen = <value>;
- */
- tibios = {};
- utils.getProgObjs(prog, tibios);
- if (environment["config._54f_"] != null) {
- tibios.GBL.CALLMODEL = "far";
- }
- /*
- * enable assorted BIOS features
- */
- bios.enableMemoryHeaps(prog)
- bios.enableRealTimeAnalysis(prog);
- bios.enableRtdx(prog);
- bios.enableTskManager(prog);
- /*
- * initialize LOG objects for user trace and system log
- */
- var trace = tibios.LOG.create("trace");
- trace.bufLen = 128;
- trace.logType = "circular";
- tibios.LOG_system.bufLen = 128;
- tibios.LOG_system.logType = "circular";
- /*
- * Memory segments, their sizes, heaps, and heap sizes
- * In internal and external data memory, we create heaps with names
- * INTERNALHEAP and EXTERNALHEAP, respectively, and platform-independent
- * portions of the application refer to these heaps by their names
- * rather than the names of memory segments they are created in
- * (as not all platforms have IDATA, DARAM47 segments).
- */
- /* allocate heap named "INTERNALHEAP" of size 0x0C00 in internal memory */
- tibios.IDATA.createHeap = true;
- tibios.IDATA.heapSize = 0x0C00; /* 3K */
- tibios.IDATA.enableHeapLabel = true;
- tibios.IDATA.heapLabel = prog.extern( "INTERNALHEAP" );
- /* allocate heap named "EXTERNALHEAP" of size 0x2000 in external memory */
- tibios.DARAM47.createHeap = true;
- tibios.DARAM47.heapSize = 0x2000; /* 8K */
- tibios.DARAM47.enableHeapLabel = true;
- tibios.DARAM47.heapLabel = prog.extern( "EXTERNALHEAP" );
- /*
- * Set the size of the application stack. Must be large
- * enough to accomodate worst-case of nested priorities, if any.
- */
- tibios.MEM.STACKSIZE = 0x0200;
- /*
- * Set the default segment for the stack allocated by TSK_create().
- */
- tibios.TSK.STACKSEG = tibios.DARAM47;
- /*
- * Overriding default section placement
- * Assign listed sections to specified memory segments.
- */
- /* General */
- /* Set dynamic heap allocation into IDATA */
- tibios.MEM.BIOSOBJSEG = tibios.IDATA; /* Segment for DSP/BIOS Objects */
- tibios.MEM.MALLOCSEG = tibios.IDATA; /* Segment for malloc()/free() */
- /* BIOS data */
- /* BIOS code */
- /* Compiler Sections */
- /*
- * To assist in changing prog model from far <-> near,
- * these sections are placed on the overlay page
- */
- tibios.MEM.GBLINITSEG = tibios.IPROG; /* DSP/BIOS Initialization
- Tables (.gblinit) */
- tibios.MEM.TRCDATASEG = tibios.IPROG; /* TRC Initial value (.trcdata) */
- tibios.MEM.SWITCHSEG = tibios.IPROG; /* Switch Jump Table (.switch) */
- tibios.MEM.CINITSEG = tibios.IPROG; /* Data Initialization
- Section (.cinit) */
- tibios.MEM.PINITSEG = tibios.IPROG; /* C Function Initialization
- (.pinit) */