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.

TMS320F280049C: Flash verification fails with dslite

Part Number: TMS320F280049C
Other Parts Discussed in Thread: UNIFLASH

Hi All,

we have some problems programming our electronics and I am not sure if we are just doing something not intended.

We program multiple hex images (Bootloader, Application, etc.) into the controller and when we do it with UniFlash it states:

[SUCCESS] Program Load completed successfully.

Now when we are generating the standalone package and try to program the images with dslite it states:

error: C28xx_CPU1: File Loader: Verification failed: Memory map prevented reading 0x7800C@Program

Considering the address of the error message it seems like the problem is the part of the OTP memory which is programmed to set the BOOT mode of the controller.

The data for these adresses is included in the Bootloader hex image but this probably creates the problem when it is trying to verify it afterwards.

:020000040007F3
:02800C00FFFF74
:02800D005AFF18
:02801C00FF0360

Is there a recommendation how to set these OTP values inside the controller when programming with the dslite standalone tool?

Or is there something else we can do to mitigate this issue?

Best regards

Wolfgang

  • Wolfgang,

    Please clarify below questions:

    1) Are you programming any DCSM settings in OTP?  If yes, which fields are you programming?

    2) When you say "standalone package", do you meant the standalone package of the entire image (flash + OTP) OR Are you talking about the standalone package of the UniFlash for your configuration?  

    3) The image that you used to verify -> Does it have those boot settings in it?  You sounded they are not part of the image used to verify.  Correct?  

    Thanks and regards,
    Vamsi

  • Hi Vamsi,

    1) we are programming the following settings in OTP:

    Z1OTP-GPREG3 (0x7801C)

    Z1OTP-GPREG1 (0x7800C)

    2) We are using the functionality in Uniflash to generate a "Standalone Command Line" which includes dslite, some configuration and the hex images. I am refering to this package as standalone package which programs the device by executing the batch file generated.

    3) One of the hex files (namely the bootloader) includes the OTP settings mentioned before at the beginning of the file. In particular the lines mentioned in the first post are at the beginning of this file: 

    :020000040007F3
    :02800C00FFFF74
    :02800D005AFF18
    :02801C00FF0360

    This is the command generated and executed:

    set GENERATED_COMMAND=-c user_files/configs/f280049c.ccxml -l user_files/settings/generated.ufsettings -s VerifyAfterProgramLoad="No verification" -e -f -v "user_files/images/File1.hex" "user_files/images/File2.hex" "user_files/images/File3.hex" "user_files/images/File4.hex" "user_files/images/File5.hex" 

    The main output of the executed script is the following:

    Loading Program: Multiple Files
    Preparing ...
    0 of 4 at 0x7800c
    C28xx_CPU1: GEL Output: ... DCSM Initialization Start ...
    C28xx_CPU1: GEL Output: ... DCSM Initialization Done ...
    Erasing Flash
    Erasing Bank 0, Sector 0
    Erasing Bank 0, Sector 1: 2%
    Erasing Bank 0, Sector 2: 5%
    Erasing Bank 0, Sector 3: 8%
    Erasing Bank 0, Sector 4: 11%
    Erasing Bank 0, Sector 5: 14%
    Erasing Bank 0, Sector 6: 17%
    Erasing Bank 0, Sector 7: 20%
    Erasing Bank 0, Sector 8: 23%
    Erasing Bank 0, Sector 9: 26%
    Erasing Bank 0, Sector 10: 29%
    Erasing Bank 0, Sector 11: 32%
    Erasing Bank 0, Sector 12: 35%
    Erasing Bank 0, Sector 13: 38%
    Erasing Bank 0, Sector 14: 41%
    Erasing Bank 0, Sector 15: 44%
    Erasing Bank 1, Sector 0: 50%
    Erasing Bank 1, Sector 1: 52%
    Erasing Bank 1, Sector 2: 55%
    Erasing Bank 1, Sector 3: 58%
    Erasing Bank 1, Sector 4: 61%
    Erasing Bank 1, Sector 5: 64%
    Erasing Bank 1, Sector 6: 67%
    Erasing Bank 1, Sector 7: 70%
    Erasing Bank 1, Sector 8: 73%
    Erasing Bank 1, Sector 9: 76%
    Erasing Bank 1, Sector 10: 79%
    Erasing Bank 1, Sector 11: 82%
    Erasing Bank 1, Sector 12: 85%
    Erasing Bank 1, Sector 13: 88%
    Erasing Bank 1, Sector 14: 91%
    Erasing Bank 1, Sector 15: 94%
    0 of 2 at 0x7801c
    0 of 4 at 0x80000
    0 of 236 at 0x80004
    0 of 13404 at 0x8007c
    0 of 570 at 0x81aac: 7%
    0 of 8 at 0x81bcc: 7%
    0 of 96 at 0x81f7c: 7%
    0 of 16 at 0x81ff4: 7%
    0 of 8192 at 0x82000: 7%
    0 of 1044 at 0x83000: 12%
    0 of 105452 at 0x8320c: 13%
    32752 of 105452 at 0x8320c: 31%
    65504 of 105452 at 0x8320c: 49%
    98256 of 105452 at 0x8320c: 67%
    0 of 7044 at 0x90004: 71%
    0 of 3580 at 0x90dc8: 75%
    0 of 2876 at 0x914c8: 77%
    0 of 1598 at 0x91a68: 78%
    0 of 20154 at 0x91d88: 79%
    0 of 11258 at 0x944e8: 91%
    0 of 436 at 0x95ae8: 97%
    0 of 212 at 0x95bc4: 97%
    0 of 580 at 0x95c30: 97%
    0 of 148 at 0x95d54: 97%
    0 of 108 at 0x95da0: 98%
    0 of 3392 at 0x95dd8: 98%
    0 of 8 at 0x9ffec: 99%
    Finished: 99%
    Setting PC to entry point.: 99%
    Verifying Program: Multiple Files
    Preparing ...
    0 of 4 at 0x7800c
    error: C28xx_CPU1: File Loader: Verification failed: Memory map prevented reading 0x7800C@Program
    Finished
    Failed: File: Multiple Files: Load failed.

    Best regards

    Wolfgang

  • Wolfgang,

    #1. So, device is not secured.

    #2. Ok, it is the Uniflash standalone package.

    #3. I will ask our tools team to help you on this.  

    Thanks and regards,

    Vamsi

  • The error basically means that the address that we are trying to read (0x7800C) is not mapped to program memory (@Program).

    Looking at the file that sets up the memory map for the debugger I see this for the program page.  i.e. no memory at 0x7800C

    GEL_MapAddStr(0x00070000,0, 0x400, "R|AS2",0);                       /*   TI OTP BANK1 (2 KBytes)                                 */

    GEL_MapAddStr(0x00070400,0, 0x400, "R|AS2",0);                       /*   TI OTP BANK2 (2 KBytes)                                 */ 

    The data page on the other hand does have memory there.  It has the same 

    GEL_MapAddStr(0x00070000,1, 0x400, "R|AS2",0); /* TI OTP BANK1 (2 KBytes) */
    GEL_MapAddStr(0x00070400,1, 0x400, "R|AS2",0); /* TI OTP BANK2 (2 KBytes) */
    GEL_MapAddStr(0x00078000,1, 0x400, "R|AS2",0); /* USER OTP BANK1 (2 KBytes) */
    GEL_MapAddStr(0x00078400,1, 0x400, "R|AS2",0); /* USER OTP BANK2 (2 KBytes) */

    The issue is likely that hex files have no concept of memory pages.  So UniFlash is seeing the address 0x7800C and assuming program page.  If .out files were being loaded I bet this would have passed ok as .out files have the page information.

    One option would be to edit the .gel file where the memory map is defined and add the USER OTP BANK memory.

    The file is f280049c.gel

    It is located in <uniflash install dir>/deskdb/content/TICloudAgent/win/ccs_base/emulation/gel

    You could add these 2 lines to just after line 172

    GEL_MapAddStr(0x00078000,1, 0x400, "R|AS2",1); /* USER OTP BANK1 (2 KBytes) */
    GEL_MapAddStr(0x00078400,1, 0x400, "R|AS2",1); /* USER OTP BANK2 (2 KBytes) */

    Regards,

    John

  • Hi John,

    thanks a lot for the explanation and your suggestion. I had to adapt the lines to set program page (second argument 0) instead of data page but with this the programming works as expected:

    GEL_MapAddStr(0x00078000,0, 0x400, "R|AS2",1); /* USER OTP BANK1 (2 KBytes) */
    GEL_MapAddStr(0x00078400,0, 0x400, "R|AS2",1); /* USER OTP BANK2 (2 KBytes) */

    Best regards

    Wolfgang