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.

TMS320F28377D: CSM password locking enquiry

Part Number: TMS320F28377D
Other Parts Discussed in Thread: UNIFLASH,

Hi ,

I am trying to implement CSM locking in F23877D control card

So I enter CMSPSWD , GRABSECT/RAM , PSWDLOCK and Program these successfully with the values as in the picture:

So after doing this , I disconnect the power and power it on again .

Then I change the CSM password value by just entering random numbers in the locations .  Go to Program and program new code to the memory.

The program successfully erases and loads the new program.

Could you tell me why this happens ? Since the memory is secure and I have entered the wrong password.

  • Anish,

    Ist thing you have to make sure that the password values and GRABSECT values were programmed correctly. To check the same, please open password OTP locations in CCS memory watch window and see if the values you see are all 0x0. If yes, then it means zone password are programmed. Then check the value in GRABSECT register (DCSM register in register view) and see if the values are correct. Let us know what you find.

    Regards,
    Vivek Singh
  • Hi Vivek , 

    I think the problem I am facing is with the uniflash command line .

    Let me explain below .  

    In uniflash GUI , when I press on Program GRABSECT/RAM , then I can see that the memory is being programmed with the 35555555 and D0005555 values as I wanted. 

    When I check the memory locations for Flash sector A , B etc , it shows 0's as values. This indicates memory is secure.

    Now when I try programming with the wrong CSM password , the programming fails as I expect.

    Now when I call the below command line in the batch file  , the process says it is successful for all the 3 operations. But when I check the the memory values for GRABSECT and GRABRAM the vales havent changed .  The CSM password however has 0's in its memory , indicating password location is secure.

    Could you tell me what is wrong with the below line for GRABSECT ,GRABRAM  and Z1GRABProgram please.

    call uniflash -ccxml X:/Projects/1006/Software/S-1006-1600/Development/Workspace/CPU1_Prog/targetConfigs/TMS320F28377D.ccxml -core "Texas Instruments XDS2xx USB Debug Probe_0/C28xx_CPU1" -loadSettings X:/Projects/1006/Software/S-1006-1600/Development/Workspace/CPU1_Prog/targetConfigs/TMS320F28377D.uniflashsession -setOptions Z1PSWDLOCK=22221111 Z1CRCLOCK=44443333 Z1CSMPSWD0=21346986 Z1CSMPSWD1=46579443 Z1CSMPSWD2=25612358 Z1CSMPSWD3=21561284 Z1GRABSECT=35555555 Z1GRABRAM=D0005555 -operation Z1GRABProgram Z1PasswordProgram Z1OTPSECCLOCKProgram

    I have also tried :

    call uniflash -ccxml X:/Projects/1006/Software/S-1006-1600/Development/Workspace/CPU1_Prog/targetConfigs/TMS320F28377D.ccxml -core "Texas Instruments XDS2xx USB Debug Probe_0/C28xx_CPU1" -loadSettings X:/Projects/1006/Software/S-1006-1600/Development/Workspace/CPU1_Prog/targetConfigs/TMS320F28377D.uniflashsession -setOptions Z1GRABSECT=35555555 Z1GRABRAM=D0005555 -operation Z1GRABProgram

    In this case as well success was reported , but no changes occurred in the memory

  • Anish,

    If you are trying to change the security setting which is already programmed then it'll not work. You can not change the values in USER OTP, once programmed. You need to change the linkpointer value to change the zone select block location and program the new security settings at new location.

    Regards,

    Vivek Singh

  • Anish,

    Let me know if you have any further query on this.

    Vivek Singh
  • Hi Vivek , 

    I have changed the user otp linkpointer value manually in Uniflash gui and then called the called the above commands in a batch file.

    So the memory doesn't have the previous security settings anymore.

    I found another thread where the same problem was occurring :

    Do you think that the uniflash code is not right ? Let me know how I should proceed.

    Regards

    Anish

  • Anish,

    UniFlash v3 is not supported anymore, so it would be great if you can update to the latest version of UniFlash (processors.wiki.ti.com/index.php if possible.

    As for your v3 CLI command, one thing I can recommend is to move the settings you are loading in -setOptions into your .uniflashsession file (or depending on what's in the file, try not loading it). This way, you are not using both -setOptions and -loadSettings options. I'm not sure if these options work together, so it would be good to try to use only one or the other.

    Thanks,
    Ricky
  • Hi Ricky , 

    Thanks . Setting the passwords in the uniflash sessions file and then executing the batch file to call the programming commands worked.

    The command in my batch file :

    uniflash -ccxml X:/Projects/1006/Software/S-1006-1600/Development/Workspace/CPU1_Prog/targetConfigs/TMS320F28377D.ccxml -core "Texas Instruments XDS2xx USB Debug Probe_0/C28xx_CPU1" -loadSettings X:/Projects/1006/Software/S-1006-1600/Development/Workspace/CPU1_Prog/targetConfigs/TMS320F28377D.uniflashsession -operation Z1GRABProgram Z1PasswordProgram Z1OTPSECCLOCKProgram