DM642新做的板子(只焊接了电源和DSP部分),与CCS3.3 connect之后马上就disconnect,错误信息如下:
Trouble Writing Memory Block at 0x1800020 on Page 0 of Length 0x4:Error 0x00000022/-1154Error during: Memory, Execution, The memory at 0x00000000 continually indicated it was 'not ready' The emulator was unable to regain control of the processor. The processor must be reset.Sequence ID: 66Error Code: -1154Error Class: 0x00000022
Chris Meng:
Jacky,
从错误信息看,芯片工作不稳定。建议测量一下芯片的电源,复位信号,上电时序,晶振,JTAG相关信号来排查原因。
Jacky Yan:
回复 Chris Meng:
现在可以一直连上CCS,但是在load program时失败.
.vecs:0 of 512 at 0xa800
Chris Meng:
回复 Jacky Yan:
Jacky,
能否分享一下,之前仿真器链接问题是如何解决的?
关于你的问题,程序下载的位置是EMIF的寄存器地址。你的代码怎么会下载到寄存器的地址上去?
MEMORY BLOCK DESCRIPTION BLOCK SIZE HEX ADDRESS RANGE
External Memory Interface A (EMIFA) Registers 256K 0180 0000 – 0183 FFFF
Jacky Yan:
回复 Chris Meng:
我换了个gel文件,然后仿真器可以连上了。
我现在只是焊接了电源、晶振、复位、和DSP芯片这几个部分,外扩的SDRAM和CPLD、FLASH都还没有焊接,我在仿真器连接的情况下可以运行程序吧。
.cmd文件如下:
MEMORY{ L2 : o = 00000000h l = 0003fb00h /* all SRAM */}
SECTIONS{ .vecs > L2 .cinit > L2 .text > L2 .stack > L2 .bss > L2 .const > L2 .data > L2 .far > L2 .switch > L2 .sysmem > L2 .tables > L2 .cio > L2}
主函数如下:
void main(){ DM642_init(); /*中断向量表的初始化*/ IRQ_globalDisable(); //Point to the IRQ vector table IRQ_setVecs(vectors);
printf("DM642 is OK!");
}
Chris Meng:
回复 Jacky Yan:
Jacky,
请检查一下map文件,看里面是否有使用到0x1800024这个地址?
Jacky Yan:
回复 Chris Meng:
map文件里我现在只保留了一条:
GEL_MapAdd(0x00000000, 0, 0x00040000, 1, 1); /* Internal Memory */
现在与CCS的连接没有问题,只是在load program时,会出现
data verification failed at address 0x7FF0
Jacky Yan:
回复 Chris Meng:
昨晚又试了下,现在可以load program进去,但是程序后跳转不了mian,如果这个时候halt ,那就会出现CCS与仿真器被断开。这时错误为:
Trouble Halting Target CPU:Error 0x00000020/-1151Error during: Execution, Processor communication timeout.It is recommended to RESET EMULATOR. This will disconnect each target, perform an emulation reset, and then reconnect each target.Power cycle the target board before continuing.
Sequence ID: 15Error Code: -1151Error Class: 0x00000020
然后再点disconnect,出现:
Failed to remove the debug state from the target before disconnecting.
There may still be breakpoint opcodes embedded in program memory.
It is recommended that you reset the emulator before you connect and reload your program before you continue debugging.
Chris Meng:
回复 Jacky Yan:
Jacky,
我说的map文件是代码编译后生成的,和out文件在同一个目录下。
Jacky Yan:
回复 Chris Meng:
谢谢Chris,今天已经解决了,运行了一个小程序,有输出了。