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.

TMS320F28377S: Issues Programming Flash and Setting PLL Registers

Part Number: TMS320F28377S
Other Parts Discussed in Thread: UNIFLASH

I am currently having an issue programming my device after many days of development. The original problem started with an issue programming to flash with a TI SYS/BIOS project where my XDS100 would fail to connect occasionally. Power cycling the board and the emulator was fixing that.

 

Recently (past day or two) I could not program the device at all. CCS Console would indicate that the Memory Map was successfully initialized, but then after tying to writing to Flash Address 0x00082000 (Sector B) the debug probe reports and error and then it fails. Below is a screen capture of the error window, as well as the console output of the failure.

C28xx_CPU1: GEL Output: 
Memory Map Initialization Complete
C28xx_CPU1: Writing Flash @ Address 0x00082000 of Length 0x00000456 (page 0)
C28xx_CPU1: Error: (Error -1135 @ 0xC095) The debug probe reported an error. Confirm debug probe configuration and connections, reset the debug probe, and retry the operation. (Emulation package 7.0.188.0) 
C28xx_CPU1: Trouble Halting Target CPU: (Error -1044 @ 0x0) The debug probe reported an error. Confirm debug probe configuration and connections, reset the debug probe, and retry the operation. (Emulation package 7.0.188.0) 
C28xx_CPU1: Error: (Error -1135 @ 0xC095) The debug probe reported an error. Confirm debug probe configuration and connections, reset the debug probe, and retry the operation. (Emulation package 7.0.188.0) 
C28xx_CPU1: Unable to determine target status after 20 attempts
C28xx_CPU1: Failed to remove the debug state from the target before disconnecting.  There may still be breakpoint op-codes embedded in program memory.  It is recommended that you reset the emulator before you connect and reload your program before you continue debugging
C28xx_CPU1: Error occurred during flash operation: Could not write 0x00000064@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not read 0x00130@Program: target is not connected
C28xx_CPU1: PLL configuration status = 0.
C28xx_CPU1: Error executing PLL configuration algorithm. Operation cancelled. (0x0)
C28xx_CPU1: File Loader: Memory write failed: Unknown error
C28xx_CPU1: GEL: File: C:\Users\eweigel\Workspaces\TI_RTOS_F28377S\Debug\TI_RTOS_F28377S.out: Load failed.
C28xx_CPU1: Error occurred during flash operation: Could not read register PC: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x0005F800@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x0005FC00@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x00000@Program: target is not connected
C28xx_CPU1: Error occurred during flash operation: Cannot enable while the target is disconnected
C28xx_CPU1: Error occurred during flash operation: Could not read 0x00000064@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x00000064@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Failed to run target while trying to execute pwrite_en.alg
C28xx_CPU1: Flash operation timed out waiting for the algorithm to complete. Operation cancelled.
C28xx_CPU1: Perform a debugger reset and execute the Boot-ROM code (click on the RESUME button in CCS debug window) before erasing/loading the Flash.  If that does not help to perform a successful Flash erase/load, check the Reset cause (RESC) register, NMI shadow flag (NMISHDFLG) register and the Boot-ROM status register for further debug.
C28xx_CPU1: Error occurred during flash operation: Could not write 0x00000064@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not read 0x0005D20E@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x0005D20E@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not read 0x0005D20E@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x0005D20E@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not read 0x0005D22E@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not read 0x0005D208@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x0005D208@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not read 0x0005D208@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x0005D208@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not read 0x0005D222@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x0005D222@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x0005D214@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not read 0x0005D20E@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x0005D20E@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x0005D20E@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x0005D222@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x00000@Program: target is not connected
C28xx_CPU1: Error occurred during flash operation: Cannot enable while the target is disconnected
C28xx_CPU1: Error occurred during flash operation: Could not read 0x00000064@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write 0x00000064@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Failed to run target while trying to execute pwrite_dis.alg
C28xx_CPU1: Flash operation timed out waiting for the algorithm to complete. Operation cancelled.
C28xx_CPU1: Perform a debugger reset and execute the Boot-ROM code (click on the RESUME button in CCS debug window) before erasing/loading the Flash.  If that does not help to perform a successful Flash erase/load, check the Reset cause (RESC) register, NMI shadow flag (NMISHDFLG) register and the Boot-ROM status register for further debug.
C28xx_CPU1: Error occurred during flash operation: Could not write 0x00000064@Data: target is not connected
C28xx_CPU1: Error occurred during flash operation: Could not write register PC: target is not connected

I tried using UniFlash to see if I could connect to the device and access memory. This worked fine and I was even able to read the sectors of memory in question from the failed CCS debug. Below is a screen capture of several memory reads into flash as well as a successful verify image attempt.

Flash Sector B

Flash Sector G

Verify Image

This was suspicious to me so I loaded up an example project (sci_echoback_cpu01) and to my surprise it loaded fine and stopped at the entry point as shown below.

The emulator disconnects from the device during the InitSysCrtl() routine, and throws an error that it Can't Run Target CPU.

Trying to force the device to wake up fails, so I restarted and assembly stepped into the function until the failure occurs. The failure occurs trying to to the PLLSYSCLKDIV register and throws a can't single step error.

I captured the CPU status registers (ST0 & ST1) as well as the PLL registers before the error, but nothing seemed out of the ordinary.

I think the device might be damaged, but im not sure. Any assistance in identifying the issue or determining the health of the device is greatly appreciated.

Thanks,
Erick

  • Hi Erick,

    Can you also send the arguments to InitSysPLL functions?

    This is an issue related to high switching currents when you change your divider from Higher value to lower value, in other words increasing your system clock frequency i.e. SYSCLK. You can try lowering the frequency to see if issue resolves. 

    Also what kind of power supply are you using? Can it support operating currents that are rated in data sheet?

    Regards,

    Nirav

  • Nirav,

    Thank you for the quick response. InitSysPll is being called as follows to initialize a 200 MHz system clock :

    InitSysPll(XTAL_OSC,IMULT_20,FMULT_0,PLLCLK_BY_2);
    

    Specifically related to the device disconnecting, the value being set into the PLLSYSCLKDIV register is 0x01. I tried changing the multiplier to 10 for a 100 MHz clock, but the same issue persists.

    A brown-out type event during programming the flash was also something I had been thinking might have happened. I am using two ST LD1117A series regulators to power the F28377S, a fixed 1.2V and a fixed 3.3V regulator. Both regulators have a typical output current of 1.2A which is above the device current consumption listed in the datasheet, included below for convenience.

    If the issue with the device is indeed a current supply issue, could that permanently damage the device? I am going to do some rework and re-power the board using a bench top supply for the DSP and see if that resolves the issue.

    Thanks,
    Erick

  • Hi Erick,

    Can you try disabling the watchdog right before it configures divsel?

    DisableDog(); you can use this function.

    Regards,
    Nirav
  • Nirav,

    Doing some rework and supplying an external voltage resolved the programming issue. Thank you for identifying the high current draw during clock switching. I believe in the RTOS case the debugger configuring the PLL caused the issue and in the example case it was during clock configuration in InitSysPll().

    I narrowed down the supply issue to an upstream 5V regulator that supplies the processor 3.3V and 1.2V.

    Thanks,
    Erick