This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320C6657: 处理器论坛

Part Number: TMS320C6657


板子启动设置为nand 直接启动。nand flash中无任何代码。
上电时序采用io-before-core时序,仿TI的评估板的例子。

使用的是CCS5.5 ide,仿真器使用的是TI xds2xxUSB emulator.

上电后,连接仿真器出现以下信息:

C66xx_0:
Error connecting to the target: (Error -1143 @ 0x0) Device core was hung.
The debugger has forced the device to a ready state and recovered debug control,
but your application's state is now corrupt.
You should have limited access to memory and registers,but you may need to reset the
device to debug further. (Emulation package 5.1.232.0)

然后,按提示让仿真器执行下去,评估板的gel文件可以执行并加载程序,但是,在进入main()前出现以下错误信息:

C66xx_0:
Trouble Reading Memory Block at 0x85f1ac on Page 0 of Length 0x4:
(Error -1202 @ 0x85F1AC) 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.1.232.0)

截图如下:

此时,我通过菜单校验加载的程序(*.out)显示校验OK.

但程序无法执行下去,看起来是在执行一些c runtime的自动初始化任务时涉及到某个地址读写(LL2地址范围)就停顿了。

请工程师或有经验的专家帮忙看看,可能是什么问题?
如果是上电时序可能有问题,可能是哪部分上电时序有问题?
多谢!

  • 请尝试把boot mode设置成No boot模式看是否能连仿真器。

  • 多谢回复!!

    试过了,改成no boot 后

    评估板的gel文件可以执行并加载程序,但是,在进入main()前还是会出现以下错误信息:

    C66xx_0:
    Trouble Reading Memory Block at 0x85f1ac on Page 0 of Length 0x4:
    (Error -1202 @ 0x85F1AC) 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.1.232.0)

    和之前一样

  • 是GEL文件初始化时报的错是吧?GEL文件是参考C:\ti\ccs901\ccs\ccs_base\emulation\boards\evmc6657l\gel\evmc6657l.gel吗?

  • 多谢答复!
    不是gel文件报的错,gel此时已执行完毕。这是load完程序后,程序开始执行(执行main()函数之前的runtime 初始化的工作)时报的错,具体的参见上面那个截图。

    gel文件就是用的evmc6657l.gel

  • 执行的是什么程序?建议先执行一个最简单helloworld程序测试一下。

  • 多谢答复!
    执行的就是普通的helloworld程序。

    目前问题是main()函数无法进入,如上面截图所示,它是在gel文件完成初始化设置并加载完程序后,在进入main()函数前,执行runtime的初始化工作时报的错。

    这部分是runtime标准的程序,不属于用户控制的部分。

    错误与具体使用的什么程序应该是无关的,因为,此时,用户的main()函数都没有被调用。

  • 请看一下auto run选项是否设成了main,如果去掉的话,会报这个错吗?
    7.2.5. Auto Run and Launch Options
    https://software-dl.ti.com/ccs/esd/documents/users_guide/ccs_debug-main.html#auto-run-and-launch-options

  • 多谢答复!

    auto run选项如果去掉执行到main()后不会报这个错。
    但程序无法执行到main(),此时是停在_cint00(),一运行就出现错误:
    C66xx_0: Trouble Reading Register ControlRegisters_CSR: (Error -1202 @ 0x41) 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.1.232.0)

    此外,单独的jtag口连接测试是正常的。

  • 补充说明一下:


    此后,如果我通过debug菜单中的system reset 去复位1-2次,再载入程序,有时候就可以程序正常load,正常执行到main(),不会再报错。
    只要DSP不掉电,就一直可以正常地debug或调试程序。

    如果,掉电,就又会陷入上述故障。

    有时候,DSP一上电,仿真器一连接上,gel文件没执行前,就会出现:
    C66xx_0: Trouble Reading Register ControlRegisters_CSR: (Error -1202 @ 0x41) 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.1.232.0)

    然后,按提示继续,gel文件执行完也load完程序后,会出现:

    C66xx_0: Trouble Reading Register ControlRegisters_CSR: (Error -1202 @ 0x41) 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.1.232.0)

    或者

    C66xx_0:
    Trouble Reading Memory Block at 0x85f1ac on Page 0 of Length 0x4:
    (Error -1202 @ 0x85F1AC) 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.1.232.0)

    然后仿真器就停在上述截图画面,无法继续debug或执行程序。

  • 请检查一下电源的纹波是否在数据手册范围内,复位信号的有效时间是否从时钟,电源都稳定输出后开始计算。