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.

ccsv5 Trouble Reading Memory CE1 Device core is hung

Hi,

I have a custom board with two 5509A processors on a single jtag chain. This board has been used for some time and was originally developed using CCSv2 with the XDS510PP emulator which had no problems with the two processors on the JTAG chain.

Ive been porting this to CCSv5 using a blackhawk XDS560v2 emulator. I had to do some work to make sure all the CSL configuration that used to be done in the CCSv2 configuration was transferred to the initial code in my main function and I think I have done that correctly. The first dsp in the chain is configured with EMIF and the second is with HPI. I load the code on each processor and step through the beginning of main on each until the CSL initialization is done. Then, I try checking the memory of the second processor from the first by looking at memory location 0x2002c0 since the second processor is connected to CE1. Unfortunately, I get the following error:

dsp0: Trouble Reading Memory Block at 0x2002c0 on Page 1 of Length 0x5a: (Error -1144 @ 0x2002C0) 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.791.0)

After this, I lose control of the processor and have to exit debug and reboot the board.

Interestingly, when I look at the EBSR memory location, I get an error there as well:

dsp0: Trouble Reading Memory Block at 0x6c00 on Page 2 of Length 0x5a: (Error -1069 @ 0xD878) Device memory bus has an error and may be hung. Verify that the memory address is in valid memory. If error persists, confirm configuration, power-cycle board, and/or try more reliable JTAG settings (e.g. lower TCLK). (Emulation package 5.0.791.0)

However, it doesn't hang the processor and I can still step through the code. Also, the EBSR value seems to be displayed correctly although all the data after looks bad.

Any ideas what is wrong here? Getting quite frustrated.

I tried slowing down the emulator to 2MHz and it didn't change anything. I also did a test of the target configuration and everything was fine up to the highest frequency.

  • I have made some progress on this issue. I created a new pair of programs which were very simple and just configured the respective dsps in EMIF and HPI modes, then checked to see if I could read data on the EMIF dsp from the HPI dsp. I used the same initialization from my original code and had some difficulty. The result wasn't quite the same with the hanging dsp, but I still had trouble reading anything. I revisited the emifCfg0 structure settings and found some to be strange compared to the documentation. The structure was created when I used the import from legacy CCSv3 feature. After modifying the structure to be more or less the default with a 5 cycle timeout instead of 1, it worked fine. Now to try modifying the original structure and see if it helps there.

  • I reproduced the updated emifCfg settings in the old code and that seemed to stop the hanging.

    I also discovered that the EMIF dsp can't read the HPI chip unless the HPI chip is running, even when the EMIF chip is suspended and you examine memory from the EMIF chip with CCS. (probably obvious but worth mentioning).

  • More strangeness unfortunately.

    I created the following snippet on the EMIF dsp

    Void main()
    {
        int i;
        int *dsp1mem;
        int myval;

        CSL_init();

        CHIP_RSET(XBSR, 1);

        EMIF_config(&emifCfg00);        // configure emif - reset is here too
        EMIF_RSET(EMIRST,0xFFFFu); // reset emif state

        dsp1mem= (int *) 0x2002c0;
        myval=*dsp1mem;

        while(1);

    And the following on the HPI dsp

    Void main()
    {
        int *pointer;

        // Start CSL
        
        CSL_init();
        
        CHIP_RSET(XBSR, 18);

        pointer= (int *) 0x0002c0;
        *pointer= (int) 0x1111;

        while(1);

    In my test environment, I can run these and stop the emif dsp to view the location 0x2002c0 without a problem. When I insert this at the top of my real code, I now get the proper data in myval but when I try to look at location 0x2002c0 with the memory browser, I get a read error. hmmm, any ideas?

    Here is my emif config

    EMIF_Config emifCfg00 = {
        0x0020,        /*  Global Control Register   */
        0xffff,        /*  Global Reset Register   */
        0x1fff,        /*  CE0 Space Control Register 1   */
        0x5fff,        /*  CE0 Space Control Register 2   */
        0x0001,        /*  CE0 Space Control Register 3   */
        0x1fff,        /*  CE1 Space Control Register 1   */
        0x5fff,        /*  CE1 Space Control Register 2   */
        0x0005,        /*  CE1 Space Control Register 3   */
        0x1fff,        /*  CE2 Space Control Register 1   */
        0x5fff,        /*  CE2 Space Control Register 2   */
        0x0005,        /*  CE2 Space Control Register 3   */
        0x1fff,        /*  CE3 Space Control Register 1   */
        0x5fff,        /*  CE3 Space Control Register 2   */
        0x0001,        /*  CE3 Space Control Register 3   */
        0xf948,        /*  SDRAM Control Register 1   */
        0x0080,        /*  SDRAM Period Register   */
        0x0000,        /*  SDRAM Initialization Register   */
        0x03ff         /*  SDRAM Control Register 2   */
    };

  • I think I have it solved. The old uart driver in dsp1 seemed to be the problem. I removed

    // bios.UDEV.create("uart");
    // bios.UDEV.instance("uart").initFxn = prog.extern("UARTMD_init");
    // bios.UDEV.instance("uart").fxnTable = prog.extern("UARTMD_FXNS");
    // bios.UDEV.instance("uart").fxnTableType = "IOM_Fxns";
    // bios.UDEV.instance("uart").params = prog.extern("uartDevParams");

    in the tcf file and all is well. I can read dsp1 memory from dsp0 without any errors.