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.

CCS/TMS570LC4357: Error Led stays ON after load

Part Number: TMS570LC4357

Tool/software: Code Composer Studio

Hi,

When I load my program to the board I keep getting the error led ON. When I check the ESM register I'll get the following and the rest in 0.

If I press the Power reset button the led goes OFF.

What is this error related to? I don't understand very well; checking the TRF I see that when the Error key register is 5h -> The ERROR pin set to high when the low time counter (LTC) has completed; then the EKEY bit will switch back to normal mode (EKEY = 0000) 

what should I do so that I don't get this error? and is the code correctly load?

Thanks and regards,

J

  • Hello JDC,

    This behavior is caused by the HW bug described in DEVICE#56 in device Errata. You can clear the error by writing 0x5 first, then 0x00 to ESMEKR register.

    DEVICE#56 nERROR assertion on debugger connect
    Severity 4-Low
    Expected Behavior: No errors should be detected when connecting to the device by JTAG
    Issue: Sometimes a CPU compare error (ESM Group 2 channel 2) is generated when the debugger connects to device.
    Condition: Upon a debugger initially connecting to the device.
    Implication(s): The nError pin will toggle upon initial connection with the debugger.
    Workaround(s): Clear the nERROR by writing 0x5 to the ESMEKR key register in the ESM module and ignore the nERROR pin toggle which happens immediately upon the debugger connecting.

  • I see that the picture was not correctly loaded.

    is your answer still applicable? 

    Thanks

  • I see that the picture was not correctly loaded.

    is your answer still applicable? 

    Thanks

  • At the beginning of main(), add following instruction to clear the ERR:

    esmREG->SR1[2] = 0xFFFFFFFF;
    esmREG->EKR = 0x05;
    esmREG->EKR = 0x00;

  • Hello,

    The err is in ESM group 2 channel 2:

    esmREG->SR1[1] = 0xFFFFFFFF;
    esmREG->EKR = 0x05;
    esmREG->EKR = 0x00;

    Be aware that this way clears the error caused by JTAG connection, and clears the CPU compare error in real run-time operation too. This way should not be used in your production.