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.

tms320f28075 unable to program flash

Other Parts Discussed in Thread: TMS320F28075, CODECOMPOSER, UNIFLASH

I've got a problem downloading and programming flash on the tms320f28075. This is the 2nd spin of our custom board so that might be the problem but we're having trouble tracking it down. The other difference is that we had tmx parts on our first spin and on this one we have the qualified tms parts. I'm using the xds100v2 emulator. Here's the error:

C28xx_CPU1: Error: Failed unlocking device (zone 2) during Flash Operation.
C28xx_CPU1: Error: (Error -1135 @ 0xC0CC) The debug probe reported an error. Confirm debug probe configuration and connections, reset the debug probe, and retry the operation. (Emulation package 6.0.14.5)
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 6.0.14.5)

Immediately after receiving this error I can do a emulator connection test with success.

These parts also have the linestream library programmed into sector N, but this also was the case with the tmx parts on our 1st spin. I believe that is the reason for the "Failed unlocking device (zone 2)" message above. We also received this message on the 1st spin but are able to program flash.

I can download and execute the blink_cpu01 demo program to RAM with no problems.

Any help to debug would be appreciated.

  • Hi,

    From a CCS/JTAG debugger standpoint, the error (-1135) is usually related to issues with the hardware (check section 5.16 of this wiki page).

    Therefore, I moved this thread to the C2000 forum as the experts here may be better equipped to help you.

    Regards,

    Rafael

  • Hi John,

    Is this device secure? If yes then which zone is secure? There are two secure zone and user can choose to secure one of them or both.

    You can check the same by viewing the memory content @address 0x78020 to 0x78030 (zone1) and 0x78220 to 0x78230 (zone2) . If all the values are 0xFFFF_FFFF then zone is unsecure else it's secure.

    If you are having trouble with connecting to CCS then please check the BOOTMODE pin setting. Use "Wait Boot" setting (GPIO72 = 1 & GPIO84 = 0) to boot-up the device and that should enable connection to CCS. Then you could check the memory content.

    If the flash sector you are trying to program is part of secure Zone then you need to unlock the zone by using correct security passwords and then only program/erase operation can be done.

    Regards,

    Vivek Singh

  • Vivek,

    Thanks for the reply. Our device has linestream motor control s/w programmed into sector N and secured, zone 2 I believe. I am not attempting to program sector N. I have a significant update to my original post. I mentioned that I can download and run the blink_cpu01 project from RAM. What's interesting is that if, after running blink_cpu01, I disconnect and change over to my custom application I can now download and program it to FLASH. More interesting, if I erase FLASH and try this scenario again but this time step through blink_cpu01 until the function InitSysCtrl() is called, then disconnect and try to download my project to FLASH it also works. It seems that changing the clock setting from the internal oscillator to the external crystal oscillator, performed in InitSysCtrl() has fixed the download to FLASH problem. Is it possible that going from the TMX to TMS silicon has changed the FLASH behavior? I am now trying to modify my GEL file to change the clock settings prior to download. I don't know if this is possible but it certainly looks like my problem is related to clock settings.

    John

  • Hi John,

    One difference between TMX and TMS device is, on TMS devices proper trim values are programmed in device which could change the clock accuracy (would be better) of the device. I'll let our Flash expert comment on Flash behavior wrt different clock settings.

    Regards,

    Vivek Singh
  • John,

    This does not seem to me like a clock source issue since you did not get any errors in the console window regarding clock configuration. Also, the INTOSC range in TMS parts is much accurate than that of TMX .

    Latest Flash Plugin tries to unlock both zones and proceeds to program load even if it is not able to unlock one of the zones (issues a warning in this case and not an error like the one in your message) since the customer might not want to unlock both the zones. Which CCS version are you using? Can you install latest CCS and check for updates and install them?

    Thanks and regards,
    Vamsi
  • I'm using CCS 6.1.2.00015 and trying to install the latest but having some trouble. Stand by.
  • I upgraded to version 6.1.3.00033 of CodeComposer and see no difference in behavior. I've modified my GEL file to switch over to the external crystal oscillator prior to flash programming and am able to program flash. Both my boot mode pins are pulled high so I should be attempting to boot from flash. With blank flash I believe the processor is in a watchdog reset loop. If true the reset pulse from the watchdog should be 51.2 ms (512 X (1/10 Mhz)). I measure a bit longer, ~54.8 ms, which I think indicates that the internal oscillator is running a bit slow. Is this significant?

  • Vivek,Please see my latest post.Thanks,John
  • John,

    Good that you are able to program with your custom modification to gel file. But I don't understand the relation between the clock source and the unlock error that you got. CCS Flash Plugin/UniFlash always use INTOSC for Flash operations (Flash Plugin/UniFlash switch to INTOSC before doing Flash operations).

    Can you try programming the Flash with boot mode pins configured for wait boot mode (with out gel edits)?

    Thanks and regards,
    Vamsi
  • Vamsi,

    I tried wait mode and got the same behavior. We have always seen the unlock error, even with the 1st spin of our boards using the TMX part. Note that our parts are programmed with the Linestream library located in sector N and then sector N is locked in secure zone 2. The TMX parts were programmed by linestream on the 1st spin of the boards. For the TMS part on our 2nd spin, pre-production, boards, Arrow has programmed sector N but the programming has been qualified by Linestream.

    The following is the console output for a 2nd spin board using wait mode, the same board using boot mode flash (identical)  followed by the 1st spin board using boot mode flash. Note that the unlock errors are found all cases. I have enable verbose flash output and am using the standard GEL file for the F28075 supplied with CCS version 6.1.3.0003.

    Thanks,

    John

    Wait mode 2nd spin board #1

    Texas Instruments XDS100v2 USB Debug Probe/IcePick_C_0 : Target must be connected before loading program.
    C28xx_CPU1: GEL Output:
    Memory Map Initialization Complete
    C28xx_CPU1: Writing Flash @ Address 0x00088ee8 of Length 0x00000617 (page 0)
    C28xx_CPU1: Warning: Failed unlocking device (zone 2) after reset.
    C28xx_CPU1: Error: (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 6.0.228.0)
    C28xx_CPU1: Unable to determine target status after 20 attempts

    Boot mode flash 2nd spin board #1

    Texas Instruments XDS100v2 USB Debug Probe/IcePick_C_0 : Target must be connected before loading program.
    C28xx_CPU1: GEL Output:
    Memory Map Initialization Complete
    C28xx_CPU1: Writing Flash @ Address 0x00088ee8 of Length 0x00000617 (page 0)
    C28xx_CPU1: Warning: Failed unlocking device (zone 2) after reset.
    C28xx_CPU1: Error: (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 6.0.228.0)
    C28xx_CPU1: Unable to determine target status after 20 attempts

    Boot mode flash 1st spin board

    Texas Instruments XDS100v2 USB Debug Probe/IcePick_C_0 : Target must be connected before loading program.
    C28xx_CPU1: GEL Output:
    Memory Map Initialization Complete
    C28xx_CPU1: Writing Flash @ Address 0x00088ee8 of Length 0x00000617 (page 0)
    C28xx_CPU1: Warning: Failed unlocking device (zone 2) after reset.
    C28xx_CPU1: Erasing Flash Bank 0, Sector E
    C28xx_CPU1: Data has been buffered at the end of the current data block for 64-bit aligned writes.
    C28xx_CPU1: Verifying Flash @ Address 0x00088EE8 of Length 0x00000C28
    C28xx_CPU1: Writing Flash @ Address 0x00080000 of Length 0x00000002 (page 0)
    C28xx_CPU1: Erasing Flash Bank 0, Sector A
    .
    .
    .

  • Vamsi,
    Thanks for your help but we think we found the problem. Our 1.2 V supply voltage had a short duration ~ 200-300 mV droop on it coincident with programming FLASH. Obviously this is our problem but we had to explore all avenues.
    John