|
|
沙发

楼主 |
发表于 2015-9-4 10:29:21
|
只看该作者
补充说明4 f q! @3 d' U0 k1 B: P4 s7 |
我大约calloc 每次共计大小为5K*16bits,怀疑哪里需要配置一下
& c9 Z3 r C2 E* Y( x7 V(不过疑惑的是,为何单独DSP仿真就没有问题呢?)
" ^1 u2 G5 ~* a2 k( Z6 _$ q5 R0 V1 c, \. n" n1 m& u6 \3 y
是不是需要在DSP.CFG中进行配置: {1 L# T& G$ h, @8 b. E2 {
我现在的配置为
: u) ]3 |7 w6 `( Y9 e& S D! D$ m, R, e& G
/*1 o4 ?7 @) X2 A# s, I4 [$ Z
* ======== Operating System Configuration ========+ |! n+ K/ [, U& G
*/4 r0 o+ g) b# M) W6 I: m+ U
, n/ _& q. W- T) z3 t4 A8 A8 \
/* no rts heap */# v$ e) H! {6 h! O/ Q
Program.heap = 0;2 y: T6 @$ l- \5 g
Program.argSize = 100; /* minimum size */! @0 X- R* p) ?, T7 b
Program.stack = 0xF000; //此处修改后的值。不太懂,所以改大
; x% d7 w( F3 O/ m' B- q4 \: Y* i# T/ u! a4 `. c' d0 G# R
/* create a default heap */! b8 X$ Y7 G$ s/ q8 |
var HeapMem = xdc.useModule('ti.sysbios.heaps.HeapMem');- e0 k; |' M3 [
var heapMemParams = new HeapMem.Params();
8 t% r9 F4 R* EheapMemParams.size = 0xFf00; //此处修改后的值。不太懂,所以改大
! ]6 |/ z( O( j8 }0 i2 m2 L3 Q g1 M2 T" G
var Memory = xdc.useModule('xdc.runtime.Memory');: ]0 `2 [" M; ?# p
Memory.defaultHeapInstance = HeapMem.create(heapMemParams);
+ R# c1 ^4 V) j+ h3 R9 i/ ^4 ~, Z7 a, @0 r1 C+ _
/* configure System module */
* k* C! ~1 S! {, p% @* |var SysMin = xdc.useModule('xdc.runtime.SysMin');
5 D7 S# M! f1 A, b+ R1 L: LSysMin.bufSize = 0x1000;
7 H: V6 {8 Q! B+ l# n% [SysMin.flushAtExit = false;( S/ z2 ^( C6 q+ F9 X) `
- W/ M: x& I% L X9 Zvar System = xdc.useModule('xdc.runtime.System');5 ?6 Q6 @) x2 ^) b W+ @! ?
System.SupportProxy = SysMin;
! Z9 h1 W) S2 _2 ^+ c+ n( I, d. h D5 \( [4 b0 a
/* configure SysBios to use the lower half of Timer 1 */
* d9 |9 G" t8 m2 y# u" q8 u! Mvar Timer = xdc.useModule('ti.sysbios.timers.timer64.Timer');3 j9 N O& Q y, l7 h6 S) S- z3 P
var Clock = xdc.useModule('ti.sysbios.knl.Clock');
r: u/ B4 v' I$ F' C3 pTimer.timerSettings[1].master = true;# T9 V5 Y, B; T. Q
Timer.defaultHalf = Timer.Half_LOWER;
& x' U% }5 X) x/ j* b6 qClock.timerId = 1;
$ F0 m7 }& r( G7 D
7 v9 |- S# p7 h \. C- ]
# S7 {' g; |0 g9 G& Q/*
9 g* A% v0 G* e- z2 a * ======== Miscellaneous Configuration ========7 ?1 n! ^+ w( I# ~1 j1 ` s, y, B( }
*/
0 D6 U/ Z% |- b) q. M
- \. w) T5 P* [, o# d/ t5 _7 ~/* set default diags mask */% i& P% h9 v0 b
var Diags = xdc.useModule('xdc.runtime.Diags');
V& ~4 L/ l9 @, gvar Defaults = xdc.useModule('xdc.runtime.Defaults');( l: j N! D- J; P# r2 O# n4 ^: S& H
; W& R. V% l- u4 o$ U1 \Defaults.common$.diags_ENTRY = Diags.ALWAYS_OFF;3 A9 F% B+ V3 s$ c+ v9 ?
Defaults.common$.diags_EXIT = Diags.ALWAYS_OFF;# ^6 B) E$ h' Q- h8 l& [( ?
Defaults.common$.diags_LIFECYCLE = Diags.ALWAYS_OFF;
0 ` I* [% s1 u0 g" y; C: XDefaults.common$.diags_INTERNAL = Diags.ALWAYS_OFF; /* needed for asserts *// ~* I1 }- g) i5 B
Defaults.common$.diags_ASSERT = Diags.ALWAYS_OFF; /* development only */
# w: a& u# f% g& o. y1 Z! fDefaults.common$.diags_STATUS = Diags.RUNTIME_ON;
3 ~8 w: d, Q% E8 M7 bDefaults.common$.diags_USER1 = Diags.ALWAYS_OFF;2 s0 m/ G n- e {. j
Defaults.common$.diags_USER2 = Diags.ALWAYS_OFF;
% \7 d$ h7 w) T$ kDefaults.common$.diags_USER3 = Diags.ALWAYS_OFF;
! X2 L8 X! y$ C- a5 ADefaults.common$.diags_USER4 = Diags.ALWAYS_OFF;; `8 M3 C' q5 g q, L1 O5 W6 |: n
Defaults.common$.diags_USER5 = Diags.ALWAYS_OFF;
9 e' L* b7 H( ?3 j( l- nDefaults.common$.diags_USER6 = Diags.ALWAYS_OFF; H6 ]9 r( p2 _
Defaults.common$.diags_INFO = Diags.ALWAYS_OFF;$ K( q: }$ m9 B8 N- l$ |2 b' o
Defaults.common$.diags_ANALYSIS = Diags.ALWAYS_OFF;0 U+ D9 n. u+ Y
8 {1 ?( S! S& F/* override diags mask for selected modules */$ B: b8 z; ?% C3 i8 ?2 t8 Z
xdc.useModule('xdc.runtime.Main');
7 z% t) L- ?" V, `2 ^5 rDiags.setMaskMeta(7 ~5 T$ n8 p& ?* B
"xdc.runtime.Main",& L% R$ O7 V! P% _+ P
Diags.ENTRY | Diags.EXIT | Diags.INFO,
3 ^% X' ^7 W- n+ y Diags.RUNTIME_ON
$ }% ?; h9 G+ J/ y" ^);
5 c' m' K7 o1 o0 z3 ?
' o# H ~$ `" f/ n, @/ K. G* bvar Registry = xdc.useModule('xdc.runtime.Registry');6 L# c0 {1 P5 v; n
Registry.common$.diags_ENTRY = Diags.RUNTIME_OFF;
" A5 m5 f! |, k1 _9 R c& m pRegistry.common$.diags_EXIT = Diags.RUNTIME_OFF;1 R, T/ W: n: Q1 Y
Registry.common$.diags_INFO = Diags.RUNTIME_OFF;
2 l/ W- y$ D& }Registry.common$.diags_USER1 = Diags.RUNTIME_OFF;
4 c" K) V9 o: ?. ~3 ?- w9 o, X0 e0 N# D4 P0 p( H( |
/* create a logger instance */
0 b: Y+ B% M$ j- ^' y& t) }9 Ovar LoggerBuf = xdc.useModule('xdc.runtime.LoggerBuf');! r2 }. M! S8 B# U; n- r
var loggerBufP = new LoggerBuf.Params();5 a7 g- K0 n: Q; M" U% B
loggerBufP.numEntries = 128; /* 128 entries = 4 KB of memory */! k; N/ H+ b1 w( T
loggerBufP.bufType = LoggerBuf.BufType_FIXED;- ~* ^: ]/ v6 a1 p7 n9 L
2 e9 {, T+ {& zvar appLogger = LoggerBuf.create(loggerBufP);
! b4 p9 }4 Q# G' JappLogger.instance.name = "AppLog_Core1";! b8 ~2 R4 L5 h i2 d! W
Defaults.common$.logger = appLogger;$ l; B/ f. T3 g/ j0 F5 e# T C
Memory.defaultHeapSize = 0x8192; / y0 h- u1 U% O |" B) U
Idle.idleFxns[0] = "&LEDStatus";. }$ H( \1 [2 ~" B$ t% ~
Cache.initSize.l2Size = Cache.L2Size_32K;
* b& w% ^1 S% d I- s, q
- L& Q. C j# E7 p, [2 x4 u |
|