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.

TMS320VC5502: Error connecting to the target: (Error -2172 @ 0xD) Unable to communicate with the debug probe. Confirm debug probe configuration and connections, reset the debug probe, and retry the operation. (Emulation package 8.4.0.00006)

Part Number: TMS320VC5502


Hello everyone, when I press the "debug" button, I experience a freeze, followed by error -2172 as mentioned in the title.

  1. I am using a custom DSP board equipped with a C5502.

  2. I am using an XDS200 debug probe.

  3. I have tried CCS from V9 to V12, and the same issue persists.

  4. During debugging, I am running the Hello World program from the Basic sample.

  5. When I perform the Test connection, it seems to have no issues, with the following result:

    [Start: Texas Instruments XDS2xx USB Debug Probe]

    Execute the command:

    %ccs_base%/common/uscif/dbgjtag -f %boarddatafile% -rv -o -S integrity

    [Result]


    -----[Print the board config pathname(s)]------------------------------------

    C:\Users\user\AppData\Local\TEXASI~1\CCS\
    ccs930\0\0\BrdDat\testBoard.dat

    -----[Print the reset-command software log-file]-----------------------------

    This utility has selected a 560/2xx-class product.
    This utility will load the program 'xds2xxu.out'.
    The library build date was 'Nov 25 2019'.
    The library build time was '14:43:38'.
    The library package version is '8.4.0.00006'.
    The library component version is '35.35.0.0'.
    The controller does not use a programmable FPGA.
    The controller has a version number of '13' (0x0000000d).
    The controller has an insertion length of '0' (0x00000000).
    This utility will attempt to reset the controller.
    This utility has successfully reset the controller.

    -----[Print the reset-command hardware log-file]-----------------------------

    This emulator does not create a reset log-file.

    -----[Perform the Integrity scan-test on the JTAG IR]------------------------

    This test will use blocks of 64 32-bit words.
    This test will be applied just once.

    Do a test using 0xFFFFFFFF.
    Scan tests: 1, skipped: 0, failed: 0
    Do a test using 0x00000000.
    Scan tests: 2, skipped: 0, failed: 0
    Do a test using 0xFE03E0E2.
    Scan tests: 3, skipped: 0, failed: 0
    Do a test using 0x01FC1F1D.
    Scan tests: 4, skipped: 0, failed: 0
    Do a test using 0x5533CCAA.
    Scan tests: 5, skipped: 0, failed: 0
    Do a test using 0xAACC3355.
    Scan tests: 6, skipped: 0, failed: 0
    All of the values were scanned correctly.

    The JTAG IR Integrity scan-test has succeeded.

    -----[Perform the Integrity scan-test on the JTAG DR]------------------------

    This test will use blocks of 64 32-bit words.
    This test will be applied just once.

    Do a test using 0xFFFFFFFF.
    Scan tests: 1, skipped: 0, failed: 0
    Do a test using 0x00000000.
    Scan tests: 2, skipped: 0, failed: 0
    Do a test using 0xFE03E0E2.
    Scan tests: 3, skipped: 0, failed: 0
    Do a test using 0x01FC1F1D.
    Scan tests: 4, skipped: 0, failed: 0
    Do a test using 0x5533CCAA.
    Scan tests: 5, skipped: 0, failed: 0
    Do a test using 0xAACC3355.
    Scan tests: 6, skipped: 0, failed: 0
    All of the values were scanned correctly.

    The JTAG DR Integrity scan-test has succeeded.

    [End: Texas Instruments XDS2xx USB Debug Probe]

    I have shared all the information I can provide. I would like to ask if any of you have encountered similar issues during development?

  • Hi Jun-ting,

    Have you set your custom board to No Boot Mode and try again?

    Please refer to the Table 4. Boot Mode Selection Options of Using the TMS320VC5501/5502 Bootloader (Rev. C) (ti.com) for details.

    Best regards,

    Ming

  • Dear Ming Wei,

    Thank you for your assistance. I have conveyed the suggestion regarding the No Boot Mode setting to my hardware supplier, and I will update you with the outcome after our discussion. Thank you once again for your support!

    Best regards,

    JUN-TING

  • Dear Ming Wei,

    I apologize for the late response as discussing with the equipment supplier took quite some time.

    After getting the modified DSP board back, I set the boot mode to 000 (no boot mode), which no longer results in the -2172 error code.

    However, a new issue has emerged. When I press debug, it displays "load program error."

    If I set the boot mode to other settings, it then shows "Trouble Reading memory Block at 0x802 (error code -1069)" and "(error code -2130)."

    May I ask if this indicates a problem with the hardware memory?

  • Hi Jun-ting,

    the "load program error" usually means the memory area your program was loaded to is not accessible. One way to tell whether it is a SOC initialization issue or a program issue is to access the on-chip memory via CCS memory browser. If you can access to all on-chip memory using memory browser, then the issue is with the program. Are you using any off-chip memory in your program? Can you send your linker command file?

    I do not have a C5502 board at hand, so I cannot debug this issue on board.

    Best regards,

    Ming 

  • Hi Ming Wei,

    I tried to check the memory status using the Memory Browser, but as soon as I press debug, a program error pops up and the execution stops, so there is no content shown in the Memory Browser. Additionally, my chip does not have any off-chip memory; it's just a simple board. I will attach the linker command file below. Thank you very much for your help!

    Best regards,

    Jun-Ting

  • Hi Jun-ting,

    In CCS, you can select View --> Targe Configurations, you should get a view for all the target configurations available in CCS. You can select your C5502 target configuration (ccxml), right click on it, then use the "Launch Selected Configuration" to launch the ccxml file. Once CCS shows the debug view, you can select the DSP and right click on it, then select "Connect Target". Once the DSP is connected, you should be able to get to the Memory Broswer view without loading the program.

    Unfortunately, our IT does not allow us to access the google drive. Can you attach your linker command file here? You may need to rename it from *.cmd to *.lcf.

    Best regards,

    Ming 

  • Hi Ming Wei,

    Thank you for your reply. After several days of attempts on my own, I tried modifying the GEL file. By commenting out the initialization functions of two CEs in the c5502.gel file located at C:\ti\ccs1240\ccs\ccs_base\emulation\gel, it now functions correctly as follows:

    OnTargetConnect()
    {
    C5502_Init();

    //Init_CE1_SBSRAM_5502CPUBoard();
    //Init_CE0_SDRAM_5502CPUBoard();
    }

    OnReset()
    {
    //Init_CE1_SBSRAM_5502CPUBoard();
    //Init_CE0_SDRAM_5502CPUBoard();
    }


    Additionally, I used the memory browser to attempt changes at specific memory addresses. Could you advise how I might use the memory browser to test if there are issues with the physical memory?

    Lastly, regarding the linker command file you mentioned, I have copied it below in plain text format:

    /****************************************************************************/
    /* C5502.cmd */
    /* Copyright (c) 2010 Texas Instruments Incorporated */
    /* Author: Rafael de Souza */
    /* */
    /* Description: This file is a sample linker command file that can be */
    /* used for linking programs built with the C compiler and */
    /* running the resulting .out file on a C5502. */
    /* Use it as a guideline. You will want to */
    /* change the memory layout to match your specific */
    /* target system. You may want to change the allocation */
    /* scheme according to the size of your program. */
    /* */
    /****************************************************************************/

    MEMORY
    {
    MMR: o = 0x000000 l = 0x0000c0 /* 192B Memory Mapped Registers */
    DARAM0: o = 0x0000C0 l = 0x001F40 /* 8kB Dual Access RAM 0 */
    DARAM1: o = 0x002000 l = 0x002000 /* 8kB Dual Access RAM 1 */
    DARAM2: o = 0x004000 l = 0x002000 /* 8kB Dual Access RAM 2 */
    DARAM3: o = 0x006000 l = 0x002000 /* 8kB Dual Access RAM 3 */
    DARAM4: o = 0x008000 l = 0x002000 /* 8kB Dual Access RAM 4 */
    DARAM5: o = 0x00A000 l = 0x002000 /* 8kB Dual Access RAM 5 */
    DARAM6: o = 0x00C000 l = 0x002000 /* 8kB Dual Access RAM 6 */
    DARAM7: o = 0x00E000 l = 0x002000 /* 8kB Dual Access RAM 7 */

    CE0: o = 0x010000 l = 0x3F0000 /* 4MB CE0 external memory space */
    CE1: o = 0x400000 l = 0x400000 /* 4MB CE1 external memory space */
    CE2: o = 0x800000 l = 0x400000 /* 4MB CE2 external memory space */
    CE3: o = 0xC00000 l = 0x3F8000 /* 4MB CE3 external memory space */
    ROM: o = 0xFF8000 l = 0x007F00 /* 32kB ROM (MPNMC=0) or CE3 (MPNMC=1) */
    VECS: o = 0xFFFF00 l = 0x000100 /* reset vector */
    }

    SECTIONS
    {
    vectors (NOLOAD) > VECS /* If MPNMC = 1, remove the NOLOAD directive */
    .cinit > DARAM0
    /* Arbitrary assignment of memory segments to .text section. */
    /* Can be expanded or reduced observing limitations of SPRAA46 */
    .text >> DARAM1|DARAM2|DARAM3|DARAM4|DARAM5
    .stack > DARAM0
    .sysstack > DARAM0
    .sysmem > DARAM4
    .data > DARAM4
    .cio > DARAM0
    .bss > DARAM5
    .const > DARAM0
    }


    Best regards,

    Jun-Ting

  • Hi Jun-ting,

    Glad to hear it works for you now.

    The CEx settings are for the external memory, if your board does not have the external memory, it will cause the gel execution failure, so it makes sense to comment them out. As of the linker cmd, you should comment out the CEx related MEMORY section too.

    Best regards,

    Ming