I wanted to implement CSM for TMS320x28069. I read the respective user manual and implemented CSM. But "error -1135" occured during programming. I followed the below mentioned procedure.
In FILE: F2806x_CSMPasswords.asm I set the password as shown,
".sect "csmpasswds"
.int 0x0000 ;PWL0 (LSW of 128-bit password)
.int 0x1111 ;PWL1
.int 0x2222 ;PWL2
.int 0x3333 ;PWL3
.int 0x4444 ;PWL4
.int 0x5555 ;PWL5
.int 0x6666 ;PWL6
.int 0x7777 ;PWL7 (MSW of 128-bit password)"
In F2806x_SysCtrl.c, I configured the CsmUnlock() function,
"EALLOW;
CsmRegs.KEY0 = 0x0000;
CsmRegs.KEY1 = 0x1111;
CsmRegs.KEY2 = 0x2222;
CsmRegs.KEY3 = 0x3333;
CsmRegs.KEY4 = 0x4444;
CsmRegs.KEY5 = 0x5555;
CsmRegs.KEY6 = 0x6666;
CsmRegs.KEY7 = 0x7777;
EDIS;"
In the File F28069.gel: I changed the key,
"hotmenu Unlock_CSM()
{
/* Perform dummy reads of the password locations */
XAR0 = *0x3F7FF8;
XAR0 = *0x3F7FF9;
XAR0 = *0x3F7FFA;
XAR0 = *0x3F7FFB;
XAR0 = *0x3F7FFC;
XAR0 = *0x3F7FFD;
XAR0 = *0x3F7FFE;
XAR0 = *0x3F7FFF;
/* Write passwords to the KEY registers. 0xFFFF's are dummy passwords.
User should replace them with the correct password for their DSP */
*0xAE0 = 0x0000;
*0xAE1 = 0x1111;
*0xAE2 = 0x2222;
*0xAE3 = 0x3333;
*0xAE4 = 0x4444;
*0xAE5 = 0x5555;
*0xAE6 = 0x6666;
*0xAE7 = 0x7777;
}"
Then Finally in CCS I entered the right key.
When Debugged I recived the following error:
"C28xx: Flash operation timed out waiting for the algorithm to complete. Operation cancelled.
C28xx: Trouble Writing Memory Block at 0x3f7f80 on Page 0 of Length 0x76: (Error -1135 @ 0x8A2E) The emulator reported an error. Confirm emulator configuration and connections, reset the emulator, and retry the operation. (Release 5.0.429.0)
Cannot write to target
C28xx: Error: (Error -1135 @ 0x8A2E) The emulator reported an error. Confirm emulator configuration and connections, reset the emulator, and retry the operation. (Release 5.0.429.0) "
After that how many ever times i tried to connect error -1041 occurs,
"Error connecting to the target:
(Error -1041 @ 0x0)
The emulator reported an error. Confirm emulator configuration and connections, reset the emulator, and retry the operation.
(Release 5.0.429.0)"
I Tried without altering the .gel file as well on another controller but now I am left with two unusable controller.
Please guide me If the procedure followed is correct. Other blog posts suggest methods for older version of ccs where commands like "program", "erase" csm passwords are present, but I was not able to find those options in ccs V4.1.
kindly advise how to connect to these secured boards.
Thanks In Advance,