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.

How do I unlock my Piccolo? I set the Code Security Module (CSM) password

Other Parts Discussed in Thread: CONTROLSUITE, TMS320F28035, UNIFLASH, TMDSDOCK28035, TMDSCNCD28035

customer said:

I was able to program the password.  The problem is after I program the password using FlashBurn, I cannot connect to the BlackHawk programmer anymore.  I did it twice and then after power cycle, I can’t connect anymore… of course this is using the evaluation board.

Now I want to know how to unlock the device

I was able to lock myself out of the C2000 and then unlock it.

Setup:

Code Composer Studio Version: 5.3.0.00090
Experimenter’s Kit – Piccolo F28035
ControlSUITE v3.1.0 FlashingLeds-F28035 example

Procedure:

1.Lock the TMS320F28035 
    Debug example on hardware.  Resume. Suspend
    Tools > Memory Map > On-Chip Flash > Code Security Password > Key 7 > Change from FFFF to FFFE   
    Program password (button)
    Lock (button)
    Terminate debug
    Reset Experimenter’s kit
    Debug example on hardware
    Load fails because device is locked.

2.Unlock the TMS320F28035   
    View > Target Configurations > Navigate to the configuration inside FlashingLeds-F28035 > Launch Selected Configuration (right click)   
    Run > Connect Target (C28xx) > Resume > Suspend   
    Tools > Memory Map > On-Chip Flash > Code Security Password > Unlock (button).  Error because password is wrong.   
    Tools > Memory Map > On-Chip Flash > Code Security Password > Key 7 > Change from FFFF to FFFE   
    Unlock (button   
    Tools > Memory Map > On-Chip Flash > Erase Sector Selection > Sector A > Erase flash (button)   
    Terminate debug   
    Reset Experimenter’s kit  
    Debug example on hardware.  Resume. Suspend.  This works because the device is unlocked.

Let me know how you do replicating my results.

  • customer said:

    Thank you Jason. I will try it that way too.

    I was able to use FlashBurn tool to program the CSM... But not reprogram back to FFFF yet.

    I had to ground GPIO37 for me to re-flash the device.

    Did you figure out a way to reset back to FFFF?

    Also how would we do this in production without giving the password to CM? I figured we can put the password in our application .out file... I tried this by creating an array of 8 words and locating it in csmpasswds symbol from the .cmd file.  Do you have an elegant solution?

    I needed to erase sector A to reset the password back to FFFF.  I could not simply unlock and program a new password.

    C28xx: Starting device unlocking...
    C28xx: Device unlocked. To clear the programmed password, please erase Sector A of Flash memory.
    C28xx: Erasing Flash memory...
    C28xx: Operation completed successfully.

    Reference:

    Code Security Module FAQ for C2000 > Q: Is there anyway to erase the password?

    Here is how to include the Code Security Module (CSM) password in the .out file for the example above.
        Open this folder
            C:\TI\controlSUITE\device_support\f2803x\v126\DSP2803x_common\source
        Drag this file over your project, "FlashingLeds-F28035 [Active - F2803x_FLASH]," in Code Composer Studio
            DSP2803x_CSMPasswords.asm
        In the dialog box select, "Link to files," and create link locations relative to: PROJECT_LOC
        Open DSP2803x_CSMPasswords.asm and find, "csmpasswds"
        Change the following line
            .int 0xFFFF  ;PWL7
        Change to
            .int 0xFFFE  ;PWL7
        Save the file and debug the example on hardware
        To unlock and reset the password, follow step two from before

     

  • customer said:

    ... regarding erasing sector A, did you use code composer studio to unlock and erase?

    Yes, but you can also use CCS Uniflash to program, lock, unlock and erase.

    1. Program
        File > New Target Configuration(*.ccxml) File
            Connection: Texas Instruments XDS100v2 USB Emulator
            Board or Device: Experimentor's Kit - Piccolo F28035
        Program > Load Program > Browse to FlashingLeds.out

    2. Lock
        TMS320F28035 -Texas Instruments XDS100v2 USB Emulator/C28xx > TMS320F28035 > Code Security Password
        Key 7 > Change from FFFF to FFFE (for example)
        Program password (button)
        Lock (button)
        Key 7 > Change from FFFE to FFFF (incorrect password)
        Unlock (button).  This does not work since the password is incorrect.

    3. Unlock
        TMS320F28035 -Texas Instruments XDS100v2 USB Emulator/C28xx > TMS320F28035 > Code Security Password
        Key 7 > Change from FFFF to FFFE (for correct password
        Unlock (button).  This works since password is correct.

    4. Reset password
        TMS320F28035 -Texas Instruments XDS100v2 USB Emulator/C28xx > TMS320F28035 > Erase Sector Selection
        Erase Flash (button) with Sector A selected.

    CCS Uniflash Debug Console said:

    [12:13:26] Loaded target configuration from: C:\Users\a0123456\AppData\Local\.TI\1753898293\0\0/temptargetconfiguration.ccxml
    [12:15:34] Begin Writing Flash memory operation...
    [12:15:34] Loading program: C:\Users\a0123456\workspace_v5_3\2013-02-07\FlashingLeds-F28035\F2803x_FLASH\FlashingLeds.out
    [12:15:40] Operation Writing Flash memory returned.
    [12:20:12] C28xx: Starting program password operation...

    [12:20:13] C28xx: Password programmed successfully. Use the Lock button to lock the device (otherwise, the board will be locked on next connection).

    [12:20:27] C28xx: GEL Output: Device Calibration not complete, check if device is unlocked and recalibrate.
    [12:20:27] C28xx: Starting device locking...

    [12:20:27] C28xx: Device locked with programmed password.

    [12:22:03] C28xx: GEL Output: Device Calibration not complete, check if device is unlocked and recalibrate.
    [12:22:04] C28xx: Starting device unlocking...

    [12:22:04] ERROR >> C28xx: Flash Programmer: Error unlocking flash memory. Device is still locked

    [12:22:04] Flash operation Unlock failed on core Texas Instruments XDS100v2 USB Emulator/C28xx !
    [12:22:15] C28xx: GEL Output: Device Calibration not complete, check if device is unlocked and recalibrate.
    [12:22:15] C28xx: Starting device unlocking...

    [12:22:15] C28xx: Device unlocked. To clear the programmed password, please erase Sector A of Flash memory.

    [12:24:31] C28xx: GEL Output: Device Calibration not complete, check if device is unlocked and recalibrate.
    [12:24:31] C28xx: Erasing Flash memory...

    [12:24:33] C28xx: Operation completed successfully.

  • customer said:

    Will I be able to use the Blackhawk Flashburn program to do this?

    Yes, I accomplished the same goal with this setup also:

    TMDSDOCK28035 Experimenter’s Kit – Piccolo F28035 [including TMDSCNCD28035 F28035 Piccolo controlCARD (including TMS320F28035)]
    ControlSUITE v3.1.0 FlashingLeds-F28035 example
    TMDSEMU2000U - Blackhawk USB2000 JTAG Emulator
    Blackhawk FlashBurn v4.0.0.1

  • Hello,

    I was looking for some answers and seeing this post I thought that maybe you could halp me.

    I have a problem erasing my Flash memory with TMS320F28035. I thought the device was locked but after reading your post I tried to lock en unlock it and it had the same behaviour you described.

    So my device is not locked but I can't erase it anymore! Could you help me? It's the fourth device that "lock" itself already...

    Thank you.

    Regards, 

    Simon Brethous

  • Hi,
    I am facing the same Problem as Simon. Is there a way to solve this Problem because as Simon said this is my third device that lock itself.
    Best Regards,
    Said
  • Hi Said,

    Can you explain your issue in detail in a new post please?

    Regards,
    Gautam
  • Hi Gautam,
    thank you for your reply. I´ve already started new post here :
    e2e.ti.com/.../419494
    Regards,
    Said
  • Taken care. Thanks for re-directing.

    Regards,
    Gautam