|
|
沙发

楼主 |
发表于 2015-9-4 10:29:21
|
只看该作者
补充说明
& r0 d# L2 U R我大约calloc 每次共计大小为5K*16bits,怀疑哪里需要配置一下' F0 b4 Y7 M) Z6 Y. Q- A* {( W9 g0 d
(不过疑惑的是,为何单独DSP仿真就没有问题呢?)
5 i0 R3 G# T* `; q" x3 I+ T: G0 u8 w' n/ ^0 _- F* R2 e/ ^, ]
是不是需要在DSP.CFG中进行配置1 \; h5 _1 |8 {( x
我现在的配置为
. M: Y, z" b: o
, \$ T5 Y, g+ W6 z/*/ m" V6 {% {# a" t
* ======== Operating System Configuration ========: o J" n" a/ {2 e
*/, [. _7 `, x, O/ }! p7 l8 V0 t" t
2 p* w/ }$ h, u0 Y$ m& o2 y
/* no rts heap */% o5 M& U% |4 z& W2 E5 R
Program.heap = 0;
/ `( f: U9 x( ~# |& JProgram.argSize = 100; /* minimum size */
" v; q" `2 K6 D2 W* w! M1 D+ cProgram.stack = 0xF000; //此处修改后的值。不太懂,所以改大
( Y2 `) S: _+ I& ~
9 `* A1 S8 s. A% a/* create a default heap */, r5 N! _- U1 Y' ], {
var HeapMem = xdc.useModule('ti.sysbios.heaps.HeapMem');
0 K( A+ d) h: |4 qvar heapMemParams = new HeapMem.Params();
q2 Y% C ~; L% s- zheapMemParams.size = 0xFf00; //此处修改后的值。不太懂,所以改大
5 A5 Z# b7 C/ ^. l1 M* P9 K: K- x: }2 H: q0 \
var Memory = xdc.useModule('xdc.runtime.Memory');
/ u' i8 i4 i: vMemory.defaultHeapInstance = HeapMem.create(heapMemParams);
7 I" A" \" n7 U
& i& p0 e6 A' G) J/* configure System module */- c6 K) j8 Z0 h' J' [# ?3 |- m
var SysMin = xdc.useModule('xdc.runtime.SysMin');2 D5 {' i* ]9 k! y& w! ^: I0 ?
SysMin.bufSize = 0x1000;
7 y' X0 @* s! hSysMin.flushAtExit = false;
2 Y6 ]! j: y2 s; f, X3 H: i' c. X: A& p9 @+ M' j3 e1 C! T1 Y
var System = xdc.useModule('xdc.runtime.System');. x& q: z. y' i% }
System.SupportProxy = SysMin;0 N8 ]+ I# Y: L- k
- O) z3 p1 h% Y' i/* configure SysBios to use the lower half of Timer 1 */( d; I" T8 o8 H/ t+ h( K
var Timer = xdc.useModule('ti.sysbios.timers.timer64.Timer');
- E5 ^7 D3 Z6 i ]var Clock = xdc.useModule('ti.sysbios.knl.Clock');
# G, y" O/ S0 N* i' ATimer.timerSettings[1].master = true;
! S) t3 I( J7 \8 |- _Timer.defaultHalf = Timer.Half_LOWER;/ A3 k& x1 N" }9 e' u
Clock.timerId = 1;
1 ^- B% W* S, y) _1 _) f: Y. `) c6 _' u/ U$ l- d
% O& f" T( f3 l
/*
4 B1 c' t" c6 h8 z * ======== Miscellaneous Configuration ========
$ R6 z2 M9 c q* b4 | */
+ l% j6 M/ K$ p: I7 }$ }
1 o/ o% Z! n' X, t. v. B, {/* set default diags mask */7 T1 O# V# k: l0 I. B
var Diags = xdc.useModule('xdc.runtime.Diags');
% F9 f# B0 r \) Fvar Defaults = xdc.useModule('xdc.runtime.Defaults');
& k& A: U3 O, n' S* D. H# Z
' o, ?: F2 b: n) V6 ]Defaults.common$.diags_ENTRY = Diags.ALWAYS_OFF;; i# F9 k+ q- j9 D; M) h( [1 g
Defaults.common$.diags_EXIT = Diags.ALWAYS_OFF;: g9 U. ?* T5 ?: S
Defaults.common$.diags_LIFECYCLE = Diags.ALWAYS_OFF;" l1 u* ]6 m* f% J. Q
Defaults.common$.diags_INTERNAL = Diags.ALWAYS_OFF; /* needed for asserts */
$ ]0 g- z, i) K5 v7 tDefaults.common$.diags_ASSERT = Diags.ALWAYS_OFF; /* development only */
# ^$ y5 n" T! A7 l0 TDefaults.common$.diags_STATUS = Diags.RUNTIME_ON;+ G: t# w9 |# T: V& f+ t+ G
Defaults.common$.diags_USER1 = Diags.ALWAYS_OFF;" z# W4 Z( Q1 _
Defaults.common$.diags_USER2 = Diags.ALWAYS_OFF;4 d4 r! R' I- p5 N5 w' c
Defaults.common$.diags_USER3 = Diags.ALWAYS_OFF;' O1 _0 I) k6 i) R
Defaults.common$.diags_USER4 = Diags.ALWAYS_OFF;
9 {. V% j1 B! Q* T; r: HDefaults.common$.diags_USER5 = Diags.ALWAYS_OFF;* w) W/ M" Y' i! ?: w0 @3 L
Defaults.common$.diags_USER6 = Diags.ALWAYS_OFF;; k; ]- c! B( h% f
Defaults.common$.diags_INFO = Diags.ALWAYS_OFF;- N/ ^/ Q* }4 \8 V1 Y0 \( S
Defaults.common$.diags_ANALYSIS = Diags.ALWAYS_OFF;( ^# r) c( q! t0 R' D6 e7 n, b) U
) m( U+ D/ X& S6 I
/* override diags mask for selected modules */
+ S+ w5 e# U- Q' m* y5 ~xdc.useModule('xdc.runtime.Main');! t/ x, j+ V9 @
Diags.setMaskMeta() |, Y) ^. ~0 I5 A- ^
"xdc.runtime.Main",8 E+ `# Y( a+ E2 a; B& J) H) r
Diags.ENTRY | Diags.EXIT | Diags.INFO,1 N0 D2 ?& d0 o; J# p3 C; O5 |4 G% ^
Diags.RUNTIME_ON5 n; V) |- z7 D: N+ L+ q
);
1 b0 k6 T0 f* b' M; c. @& E( u8 C3 Y( P9 E
var Registry = xdc.useModule('xdc.runtime.Registry');5 R* ?' I) q, s, M9 l) q
Registry.common$.diags_ENTRY = Diags.RUNTIME_OFF;
3 N' |7 i% V$ {; Y# I! Z7 }Registry.common$.diags_EXIT = Diags.RUNTIME_OFF;) ~8 G5 j, n; M
Registry.common$.diags_INFO = Diags.RUNTIME_OFF;
. R: w( D1 D7 v WRegistry.common$.diags_USER1 = Diags.RUNTIME_OFF;
. p0 x# v/ [& j% n4 C, A8 w) y1 }# Z( a" v t2 G9 E( g
/* create a logger instance */& a6 |* v" G/ B, J& g0 ]
var LoggerBuf = xdc.useModule('xdc.runtime.LoggerBuf');
" {1 G$ b8 x- k; p1 J: @var loggerBufP = new LoggerBuf.Params();9 J8 n( w- v: ?4 Z0 v) |
loggerBufP.numEntries = 128; /* 128 entries = 4 KB of memory */, s; f$ c& z0 \5 A& e2 `% f
loggerBufP.bufType = LoggerBuf.BufType_FIXED;
7 p$ q a: K. S& p- l& ` i: K- C/ j* q
7 r0 D9 x0 O6 D$ evar appLogger = LoggerBuf.create(loggerBufP);
" Q% x/ Z+ V! |% e6 \5 e5 cappLogger.instance.name = "AppLog_Core1";
1 V4 C" m8 b, p7 [/ j& |& f: e; Z6 S oDefaults.common$.logger = appLogger;$ n- t5 k8 x0 L5 x I2 ~* Q
Memory.defaultHeapSize = 0x8192; : J, _2 u; F$ m" U" B
Idle.idleFxns[0] = "&LEDStatus";4 z1 F* {- U# F7 Y4 u W8 r4 h0 Z
Cache.initSize.l2Size = Cache.L2Size_32K;
/ l9 W; {7 t! Y) d0 x! z4 M/ k; p! j5 j0 M! `
|
|