各位大神好~~
根据必读贴的要求,我先说明一下我的调试环境:
A、用的是C6678芯片。
B、硬件环境:
用的是我们自己的硬件板,仿真器采用合众达的SEED-XDS560V2PLUS。
C、软件环境:
CCS5.3.0
D、其他:下面详细说明下我们板子的设计,DSP上电的控制及现在遇到的问题。
首先,我们设计的板子,主要参考的是EVM6678的官方开发板,也是通过一块FPGA来控制6678的上电时序、时钟以及复位控制。
我按照6678官方开发板的上电时序,通过FPGA来实现,现在电压,时钟都正常。连接上JTAG,然后在CCS的“Target Configuration”中,测试了“test connection”是通的。最后,我用Hello world程序测试了DSP能否正常工作(加上EVM的GEL、TI原始的CMD),按下CCS的“Debug”按钮,第一次能显示出"hello world"。到现在都很顺利,但是我把程序停止,重新“Debug”的时候,有时会发生错误,而且只要一发生错误后面就一直会出错,必须断电重新加载FPGA的程序才能工作。
我这样反复试了几次,错误有好几种情况,我下面贴出来:
1.C66xx_5: Error connecting to the target: (Error -1144 @ 0x0) Device core is hung. The debugger attempted to recover debug control, but was unsuccessful. Power-cycle the board. If error persists, confirm configuration and/or try more reliable JTAG settings (e.g. lower TCLK). (Emulation package 5.0.872.0)
2.C66xx_0: GEL Output: Error while waiting for GOSTAT bit returning to 0 ...
C66xx_0: GEL Output: Error in Setting up main PLL, please power cycle the board and re-run Global Default
Setup...
C66xx_0: GEL: Error while executing OnTargetConnect(): Evaluation canceled.
3.C66xx_0: Error connecting to the target: (Error -1202 @ 0x1812000) Device core is hung. The debugger will attempt to force the device to a ready state to recover debug control. Your application's state will be corrupt. You should have limited access to memory and registers, but you may need to reset the device to debug further. (Emulation package 5.0.872.0)
#############################################################################
因为在上电的第一次“Debug”都可以正常调试通过,所以我觉得应该不是硬件的问题,是否是DSP的复位控制,Bootmode,LRESET、LRESETNMIEN、NMI、CORESEL0~3等这些的控制引脚的设置有问题,我把我现在所做的步骤给帖出来:
1. C6678的CVDD、CVDD_Fixed、1.8V、1.5V、0.75V都正常供应。
2. C6678的Core(100MHz)、DDR(66.67MHz)、PASS(100MHz)都正常供应
3. FPGA端按照advantech的EVM写了上电时序,
4. 在上电时序的最后阶段:拉高RESET(同时给BOOTMODE[12:0]为0b0110000000000,LRESET=1,LRESETNMIEN=0,NMI=1,CORESEL0~3=1000),接着拉高POR,最后拉高RESETFULL
我比较困惑的一点是,在拉高RESET时,同时给BOOTMODE[12:0]为0b0110000000000,LRESET=1,LRESETNMIEN=0,NMI=1,CORESEL0~3=1000;是否正确?
参考http://www.deyisupport.com/question_answer/dsp_arm/c6000_multicore/f/53/t/31289.aspx?pi239031348=1