' Z: y& p* J/ l C! f/ A " y" ~# o4 ]1 _- u9 Z3.然后在定时器Timer2Proc()中断函数中进行翻转GPIO的操作,然后用示波器去看GPIO的波形,发现产生的波形周期为960us(正常应该是1000us); 6 ?; M% S Y( i: U8 d! Y H产生了定时器定时周期和我预设的周期值不一样。附件是我dsp.cfg文件(只能上传一部分)。请教一下这个问题是什么原因导致的,如何解决,谢谢。 " I9 @/ x, w2 |# W1 Z7 y7 r& g- k+ r3 l5 u& ^# a
( \, P$ t6 T( g! n- g7 M # t$ t3 k$ l9 G) z( ]8 ]/*2 g4 N/ S' c& o' h) P
* ======== Dsp.cfg ========) w5 w$ c/ s1 u
*% q, f% ]# V. z* q) p& r/ u
*/ c! O. t! D( J. m' `
$ m; U& X$ D* k" k2 |- b
. N- ^0 N( U$ X% e; B2 l/ e
/* root of the configuration object model */; s6 C! S% B7 ]3 q( O' c' k5 H; f
var Program = xdc.useModule('xdc.cfg.Program');: P, ?! w# ?& {
5 p0 }6 V4 i' n) T+ y, { ( C( M( ~: R# k- {/* application uses the following modules and packages */ " E" Q) N4 U! S5 W! E) Dxdc.useModule('xdc.runtime.Assert'); " `- d/ B- _' \+ I/ l" R: sxdc.useModule('xdc.runtime.Diags'); , z, W+ u$ V. J" kxdc.useModule('xdc.runtime.Error');' b/ F0 S B+ T7 U2 [& X4 H
xdc.useModule('xdc.runtime.Log');+ o$ O; p3 b9 e) E% Q
xdc.useModule('xdc.runtime.Registry');4 T, P9 D' w+ b* z. j
) F% W: v. m' t7 O % m6 I W/ g$ l0 q) `xdc.useModule('ti.sysbios.gates.GateHwi'); 4 g* K- E* Y! W( e8 B- mxdc.useModule('ti.sysbios.knl.Semaphore'); 2 w4 A/ B+ ?; l T9 a0 Q$ ~xdc.useModule('ti.sysbios.knl.Task'); N( L4 E. f9 p4 j3 G. m ; ]+ |9 g: i7 j$ b/ l' K2 H9 R# K% Y/ @' G6 _/ L
9 R: [1 ?: i% Q* R. `; }) f9 B3 L ! q5 d& h' ?/ d. J& ^9 l5 g & }4 h: }3 k5 w6 J5 H& @2 O" i; Q) J5 p" y- y& p/ @8 E
! ]7 |0 d# n5 b# h1 z. ?5 Svar BIOS = xdc.useModule('ti.sysbios.BIOS'); ( D: `" C) X8 o: jBIOS.libType = BIOS.LibType_NonInstrumented;4 B, e2 |, `2 f0 W+ L' L, H. j
8 y; l& ?0 Z. _+ Y6 X" F& V V0 i; h4 P( h% R. Y
9 d: Q2 f. h" c# f5 G9 Q* {' X8 nxdc.useModule('ti.syslink.ipc.rtos.Syslink');" B/ S, d7 l& } j$ n
4 i( t$ }% c# U3 v' R/ Z
8 K- U# a* b* o' ~& d* O2 I+ G5 ?, `- ]% i# f$ s2 X$ m! H
var MultiProc = xdc.useModule('ti.sdo.utils.MultiProc');5 H4 K D: W, B5 X& E9 x: D
var procNameAry = MultiProc.getDeviceProcNames();8 {3 P$ ~0 M D0 g3 Y" u) ~* `$ I
MultiProc.setConfig("DSP", procNameAry); ; ]: s6 X+ U1 l7 A: p4 Y' J' q+ ~1 z* Z% d2 d, w" p6 \