summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSinthu Raja M2017-11-15 09:44:18 -0600
committerPratap Reddy2017-11-15 13:45:52 -0600
commitb5b48a330279f84b0f47a580515770c11f0418b8 (patch)
tree14bda534dea0f99dda4eddbc8f8cf5f4a0d04465
parent2ad512d9bba991e1bfa20e4ddd071edfbca072b9 (diff)
downloadpruss-lld-b5b48a330279f84b0f47a580515770c11f0418b8.tar.gz
pruss-lld-b5b48a330279f84b0f47a580515770c11f0418b8.tar.xz
pruss-lld-b5b48a330279f84b0f47a580515770c11f0418b8.zip
PRSDK-3190 Add cfg file of sorte example for AM574
Added cfg file of sorte example for AM574x Signed-off-by: Pratap Reddy <x0257344@ti.com>
-rw-r--r--example/apps/sorte/src/sorte_idkAM574x_app.cfg204
1 files changed, 204 insertions, 0 deletions
diff --git a/example/apps/sorte/src/sorte_idkAM574x_app.cfg b/example/apps/sorte/src/sorte_idkAM574x_app.cfg
new file mode 100644
index 0000000..692f6da
--- /dev/null
+++ b/example/apps/sorte/src/sorte_idkAM574x_app.cfg
@@ -0,0 +1,204 @@
1/* ================ General configuration ================ */
2var Defaults = xdc.useModule('xdc.runtime.Defaults');
3var Diags = xdc.useModule('xdc.runtime.Diags');
4var Error = xdc.useModule('xdc.runtime.Error');
5var Log = xdc.useModule('xdc.runtime.Log');
6var LoggerBuf = xdc.useModule('xdc.runtime.LoggerBuf');
7var Main = xdc.useModule('xdc.runtime.Main');
8var Memory = xdc.useModule('xdc.runtime.Memory')
9var System = xdc.useModule('xdc.runtime.System');
10var Text = xdc.useModule('xdc.runtime.Text');
11var Clock = xdc.useModule('ti.sysbios.knl.Clock');
12var Swi = xdc.useModule('ti.sysbios.knl.Swi');
13var Task = xdc.useModule('ti.sysbios.knl.Task');
14var Mailbox = xdc.useModule('ti.sysbios.knl.Mailbox');
15var Semaphore = xdc.useModule('ti.sysbios.knl.Semaphore');
16var ti_sysbios_hal_Hwi = xdc.useModule('ti.sysbios.hal.Hwi');
17var SemiHostSupport = xdc.useModule('ti.sysbios.rts.gnu.SemiHostSupport');
18var Program = xdc.useModule("xdc.cfg.Program");
19var Timer = xdc.useModule('ti.sysbios.timers.dmtimer.Timer');
20/*
21 * Program.argSize sets the size of the .args section.
22 * The examples don't use command line args so argSize is set to 0.
23 */
24Program.argSize = 0x0;
25Program.heap = 0x10000;
26
27/* System stack size (used by ISRs and Swis) */
28Program.stack = 0x10000;
29
30/*
31 * Uncomment this line to globally disable Asserts.
32 * All modules inherit the default from the 'Defaults' module. You
33 * can override these defaults on a per-module basis using Module.common$.
34 * Disabling Asserts will save code space and improve runtime performance.
35Defaults.common$.diags_ASSERT = Diags.ALWAYS_OFF;
36 */
37
38/*
39 * Uncomment this line to keep module names from being loaded on the target.
40 * The module name strings are placed in the .const section. Setting this
41 * parameter to false will save space in the .const section. Error and
42 * Assert messages will contain an "unknown module" prefix instead
43 * of the actual module name.
44Defaults.common$.namedModule = false;
45 */
46
47/*
48 * Minimize exit handler array in System. The System module includes
49 * an array of functions that are registered with System_atexit() to be
50 * called by System_exit().
51 */
52/*System.maxAtexitHandlers = 4;*/
53
54/*
55 * Uncomment this line to disable the Error print function.
56 * We lose error information when this is disabled since the errors are
57 * not printed. Disabling the raiseHook will save some code space if
58 * your app is not using System_printf() since the Error_print() function
59 * calls System_printf().
60Error.raiseHook = null;
61 */
62
63/*
64 * Uncomment this line to keep Error, Assert, and Log strings from being
65 * loaded on the target. These strings are placed in the .const section.
66 * Setting this parameter to false will save space in the .const section.
67 * Error, Assert and Log message will print raw ids and args instead of
68 * a formatted message.
69Text.isLoaded = false;
70 */
71
72/*
73 * Create and install logger for the whole system
74 */
75var loggerBufParams = new LoggerBuf.Params();
76loggerBufParams.numEntries = 16;
77var logger0 = LoggerBuf.create(loggerBufParams);
78Defaults.common$.logger = logger0;
79Main.common$.diags_INFO = Diags.ALWAYS_ON;
80SysStd = xdc.useModule('xdc.runtime.SysStd');
81System.SupportProxy = SysStd;
82
83/* ================ BIOS configuration ================ */
84
85var BIOS = xdc.useModule('ti.sysbios.BIOS');
86/*
87 * Build a custom SYS/BIOS library from sources.
88 */
89BIOS.libType = BIOS.LibType_Custom;
90BIOS.assertsEnabled = true;
91BIOS.logsEnabled = true;
92/*
93 * The BIOS module will create the default heap for the system.
94 * Specify the size of this default heap.
95 */
96BIOS.heapSize = 0xA0000;
97
98Semaphore.supportsEvents = false;
99Defaults.common$.diags_INTERNAL = Diags.ALWAYS_ON;
100
101Task.defaultStackSize = 4096;
102Task.idleTaskStackSize = 4096;
103BIOS.cpuFreq.lo = 500000000;
104
105Program.sectMap[".c_int00"] = new Program.SectionSpec();
106Program.sectMap[".c_int00"].loadAddress = 0x80000000;
107
108
109/* ================ Task configuration ================ */
110
111/* Define and add one Task Hook Set */
112Task.addHookSet({
113 registerFxn: '&TaskRegisterId',
114 switchFxn: '&mySwitch',
115});
116
117/* ================ Driver configuration ================ */
118
119/* Load the OSAL package */
120var osType = "tirtos"
121var Osal = xdc.useModule('ti.osal.Settings');
122Osal.osType = osType;
123
124
125/* Load the CSL Package */
126var deviceType = "am574x";
127var socType = deviceType;
128/* Load the CSL package */
129var Csl = xdc.loadPackage('ti.csl');
130Csl.Settings.deviceType = deviceType;
131
132/* Load the UART package */
133var Uart = xdc.loadPackage('ti.drv.uart');
134/* Load the I2c package */
135var I2c = xdc.loadPackage('ti.drv.i2c');
136/* Load the PRUSS package */
137var Pruss = xdc.loadPackage('ti.drv.pruss');
138Pruss.Settings.socType = socType;
139
140/* Load Profiling package */
141var Utils = xdc.loadPackage('ti.utils.profiling');
142
143var socType = "am574x";
144
145/* Load the board package */
146var Board = xdc.loadPackage('ti.board');
147Board.Settings.boardName = "idkAM574x";
148
149/* ================ Cache and MMU configuration ================ */
150
151var Cache1 = xdc.useModule('ti.sysbios.family.arm.a15.Cache');
152Cache1.enableCache = true;
153
154/***********************************************
155 * MMU Configuration *
156 ***********************************************/
157var Mmu = xdc.useModule('ti.sysbios.family.arm.a15.Mmu');
158Mmu.enableMMU = true;
159
160/******************************************************************************
161 *
162 * SYS/BIOS assigns the following defaults to MAIR0 ATTR0, ATTR1 and ATTR2:
163 *
164 * ATTR0 -> 0x44 (mark memory region as non-cacheable normal memory)
165 * ATTR1 -> 0x04 (mark memory region as device memory, i.e. strongly
166 * ordered and non-cacheable)
167 * ATTR2 -> 0xFF (mark memory region as normal memory, RW cacheable and
168 * RW allocate)
169 ******************************************************************************
170 */
171
172
173// descriptor attribute structure
174var attrs0 = new Mmu.DescriptorAttrs();
175
176Mmu.initDescAttrsMeta(attrs0);
177attrs0.type = Mmu.DescriptorType_BLOCK; // BLOCK descriptor
178attrs0.shareable = 2; // sharerable
179attrs0.attrIndx = 1; // Non-cache, device memory
180
181// Set the descriptor for each entry in the address range
182for (var i=0x40000000; i < 0x60000000; i = i + 0x00200000) {
183 // Each 'BLOCK' descriptor entry spans a 2MB address range
184 Mmu.setSecondLevelDescMeta(i, i, attrs0);
185}
186
187// descriptor attribute structure
188var attrs1 = new Mmu.DescriptorAttrs();
189
190Mmu.initDescAttrsMeta(attrs1);
191attrs1.type = Mmu.DescriptorType_BLOCK; // BLOCK descriptor
192attrs1.shareable = 2; // sharerable
193attrs1.attrIndx = 2; // Cached, normal memory
194
195// Set the descriptor for each entry in the address range
196for (var i=0x80000000; i < 0xA0000000; i = i + 0x00200000) {
197 // Each 'BLOCK' descriptor entry spans a 2MB address range
198 Mmu.setSecondLevelDescMeta(i, i, attrs1);
199}
200
201
202/* ================ Memory sections configuration ================ */
203Program.sectMap["BOARD_IO_DELAY_DATA"] = "OCMC_RAM1";
204Program.sectMap["BOARD_IO_DELAY_CODE"] = "OCMC_RAM1";