|
|
沙发

楼主 |
发表于 2015-9-4 10:29:21
|
只看该作者
补充说明
`2 I/ N+ L6 @0 \我大约calloc 每次共计大小为5K*16bits,怀疑哪里需要配置一下
! t0 {: S8 Z" q1 i$ _ w! V5 P(不过疑惑的是,为何单独DSP仿真就没有问题呢?)8 _/ h x6 Q- K! E3 x# `
/ I- a7 e; A* l0 G
是不是需要在DSP.CFG中进行配置
* i" b! M- b {( ^/ H: H- ~我现在的配置为8 w7 m4 ?) v9 A/ \2 m9 L1 n
* y) G5 X6 {6 E( Z* C- k+ Z6 ~/*
& \3 m: `: q; D9 _$ w * ======== Operating System Configuration ========: B0 R! h) J$ P! b& {
*/
, \- N) G% e Z9 m1 R/ v
2 N! q" A M1 Q3 M3 O# @0 ?+ z/* no rts heap */
. ]3 s/ O5 H1 L0 N% L( `Program.heap = 0;6 o( Q3 S( z' r z1 a
Program.argSize = 100; /* minimum size */1 h8 A9 }7 k/ `4 [) i ^$ q
Program.stack = 0xF000; //此处修改后的值。不太懂,所以改大
: P( O6 k$ r% H6 `2 v) u
! x* V6 Y( I: g1 u( O/* create a default heap */
y7 o, p3 l/ S8 b) i4 L% V% ^var HeapMem = xdc.useModule('ti.sysbios.heaps.HeapMem');
# R7 O& k, x. Z0 L# Q( M0 Bvar heapMemParams = new HeapMem.Params();
2 _- _$ |* t) w8 s/ _* AheapMemParams.size = 0xFf00; //此处修改后的值。不太懂,所以改大( v f* J* O) z4 Q
9 e: ? X5 `7 E8 g6 fvar Memory = xdc.useModule('xdc.runtime.Memory');
% a$ Y3 @. F- Z# |! P+ tMemory.defaultHeapInstance = HeapMem.create(heapMemParams);# f" M, a3 D6 F/ C7 {
0 h( L6 p/ p( x& @
/* configure System module */
6 _0 s% R, h- n; _/ |var SysMin = xdc.useModule('xdc.runtime.SysMin');8 ^" a" @0 b0 `, a' V
SysMin.bufSize = 0x1000;9 b* u, `; @+ ~% B6 A6 @# U
SysMin.flushAtExit = false;
; [/ V% p; E W* D3 B- C1 C3 M4 S$ P7 _" [
var System = xdc.useModule('xdc.runtime.System');& d2 b* I |) h/ b2 x
System.SupportProxy = SysMin;
4 z: k0 X, i0 K4 w" L! t- n. F8 ]- }5 ]! I
/* configure SysBios to use the lower half of Timer 1 */
) X9 L9 T( m3 b7 j8 |8 Ovar Timer = xdc.useModule('ti.sysbios.timers.timer64.Timer');# s2 U& @ _( |. ~2 S$ t0 ? _1 F
var Clock = xdc.useModule('ti.sysbios.knl.Clock');
8 S( n" a4 v( t+ N# H+ |% ]6 `" LTimer.timerSettings[1].master = true;6 }8 G7 ?4 ^( E/ K1 G
Timer.defaultHalf = Timer.Half_LOWER;- g! X7 C5 `& E3 A% K9 b
Clock.timerId = 1;
/ L( d$ `1 J( L
- M$ T- T& `$ }- D8 [7 ^$ ]/ ]0 d
/*
! p0 h+ x/ B& L( O w2 a * ======== Miscellaneous Configuration ========
" p) m7 U4 O, ?: h */
4 C( b5 X4 t: T2 q8 R) M
" f# E$ ? R0 |% W! j! Z0 W1 h* h m/* set default diags mask */
$ r" W; I+ P( D$ L* G9 L. ^. Vvar Diags = xdc.useModule('xdc.runtime.Diags');
( z5 Q" v1 R/ K6 p. S# n" f9 q# ?1 ?var Defaults = xdc.useModule('xdc.runtime.Defaults'); e8 S; z& |9 x2 Q0 q3 n! \
0 F/ n5 c0 b5 J- I3 \, O9 n# QDefaults.common$.diags_ENTRY = Diags.ALWAYS_OFF;
# P# z$ G2 j: M( i* f4 yDefaults.common$.diags_EXIT = Diags.ALWAYS_OFF;
) [. O/ s! i @1 bDefaults.common$.diags_LIFECYCLE = Diags.ALWAYS_OFF;6 g1 @1 x! y# b- Y8 z/ V
Defaults.common$.diags_INTERNAL = Diags.ALWAYS_OFF; /* needed for asserts */
* Y- r" Y( j- O6 R2 PDefaults.common$.diags_ASSERT = Diags.ALWAYS_OFF; /* development only */
) \$ i* C0 W" i N& hDefaults.common$.diags_STATUS = Diags.RUNTIME_ON;
8 Z: z. w$ Q2 M. E HDefaults.common$.diags_USER1 = Diags.ALWAYS_OFF;
% _ ^% U9 S" n w- [% A: rDefaults.common$.diags_USER2 = Diags.ALWAYS_OFF;
6 {/ C# i) G0 _Defaults.common$.diags_USER3 = Diags.ALWAYS_OFF;" V' x* D' ^! g, C
Defaults.common$.diags_USER4 = Diags.ALWAYS_OFF;
" }+ A2 F; M3 }4 Z" ~, J' |' O3 f7 MDefaults.common$.diags_USER5 = Diags.ALWAYS_OFF;
5 e4 I9 A- W+ e0 c; lDefaults.common$.diags_USER6 = Diags.ALWAYS_OFF;- S% p' K* C8 Z" c& }
Defaults.common$.diags_INFO = Diags.ALWAYS_OFF;+ j, U& l3 I' e8 S2 X
Defaults.common$.diags_ANALYSIS = Diags.ALWAYS_OFF;
' G$ ^$ V% K) y" w; x
2 \7 o: S/ [* N C% n/* override diags mask for selected modules */; Q$ a0 ]5 x3 x8 A9 q
xdc.useModule('xdc.runtime.Main');0 ^" a' X* v/ L4 u$ Q
Diags.setMaskMeta(
7 H( i; B' C# H "xdc.runtime.Main",
- D3 o0 t, _1 s( E Diags.ENTRY | Diags.EXIT | Diags.INFO,# y2 K" V) [$ @: u
Diags.RUNTIME_ON
6 P( ]* @5 y: R w);
% S3 t* x" ^ Z& V% T- P4 Y" l P+ H2 H. a# ]' Y7 K/ D! Q
var Registry = xdc.useModule('xdc.runtime.Registry');
& J8 P, s- b& N& |4 |# uRegistry.common$.diags_ENTRY = Diags.RUNTIME_OFF;% I& K( A3 r" x
Registry.common$.diags_EXIT = Diags.RUNTIME_OFF; X% V1 B+ o1 E: N
Registry.common$.diags_INFO = Diags.RUNTIME_OFF;: L% J$ {& p& @* `
Registry.common$.diags_USER1 = Diags.RUNTIME_OFF;, w. i y& L+ X6 W7 Y1 l
3 f7 u' W" D- Z, Q b1 h/* create a logger instance */5 J( _; ~3 r+ }( G
var LoggerBuf = xdc.useModule('xdc.runtime.LoggerBuf');
, V, u( d' |: R0 A) M6 O2 Hvar loggerBufP = new LoggerBuf.Params();
8 U2 Y* L( [* L( ZloggerBufP.numEntries = 128; /* 128 entries = 4 KB of memory */
' g* C/ J$ \' b" g5 ologgerBufP.bufType = LoggerBuf.BufType_FIXED;! Q" v6 R6 f; U2 E# q- k
3 y4 O9 R5 e4 H6 cvar appLogger = LoggerBuf.create(loggerBufP);
! |$ A( k4 G* e* v' ]+ TappLogger.instance.name = "AppLog_Core1";6 G+ l+ l1 L0 q# ^& c2 |0 H
Defaults.common$.logger = appLogger;4 ?! u; S3 }$ y: V. S3 G" u S* G
Memory.defaultHeapSize = 0x8192;
$ U) V( g8 d _) A# c" |Idle.idleFxns[0] = "&LEDStatus";/ j* O) b% {8 B6 l4 S
Cache.initSize.l2Size = Cache.L2Size_32K;$ W [8 f9 c! d6 ~
, q7 V4 c, B: ?( L, C2 k$ a& ~
|
|