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.

TMS320F28P550SJ: error trying to load code into flash usign sci

Part Number: TMS320F28P550SJ
Other Parts Discussed in Thread: C2000WARE

Tool/software:

Hi,

What should be the cause of the error below:

First stage, loading the kernel, went without error. 

82==82
fe==fe
6==6
0==0
0==0
0==0
Bit rate /s of transfer was: 7647.001953
Kernel loaded! Booting kernel...
Done waiting for kernel boot...
Attempting autobaud to send function message...
What operation do you want to perform?
1-DFU CPU1
2-Erase CPU1
3-Verify CPU1
4-Unlock CPU1 Zone 1
5-Unlock CPU1 Zone 2
6-Run CPU1
7-Reset CPU1
0-DONE

Second stage, DFU CPU1. Error 0x83198 occurred.

6
0
1
9a
6
0
6
0
0
0
Bit rate /s of transfer was: 29686.691406
Application load successful!
Done waiting for application to download and boot...
SUCCESS of Command
ERROR Status: PROGRAM_ERROR
ERROR Address: 0x83198
Flash API Error: Invalid Address
Please refer to the Flash API documentation for further explanation of the error.
FMSTAT Register contents: 00

What operation do you want to perform?
1-DFU CPU1
2-Erase CPU1
3-Verify CPU1
4-Unlock CPU1 Zone 1
5-Unlock CPU1 Zone 2
6-Run CPU1
7-Reset CPU1
0-DONE

  • Hi Ari,

    Are you using the serial flash programmer tool?

    Thank you,

    Luke

  • Hi, Luke

    yes, I'm using the serial flash programmer tool located at: C:\ti\c2000\C2000Ware_5_02_00_00\utilities\flash_programmers\serial_flash_programmer

    Recently I tested the firmware upgrade using the C2prog app. With C2prog it worked without problems, and with the advantages of not having to compile the kernel and being much faster.

    Still, I would like to know why it isn't working with the serial_flash_programmer.

  • Hi Ari,

    The F28P55x SCI flash kernel project uses the 512-bit programming feature of the corresponding Flash API. Thus, the application sections stored in flash memory need to be aligned to 512-bit boundaries. Please add "ALIGN(32)" to any memory sections stored in flash. Please see section 5.4 of this document for more details.

    Kind regards,

    Skyler

  • Hi Skyler,

    I'm using the "f28p55x_flash_ex3_sci_flash_kernel" example as the kernel, so I need to add the align(32) command to the application and not to the kernel. Correct?

    Where exactly in my application code do I need to include the align(32) command?

    Ari.

  • Hi Ari,

    Yes, you need to add it to the linker .cmd file of the application, not the kernel. For an example, take a look at C2000Ware_5_02_00_00\device_support\f28p55x\common\cmd\28p55x_flash_api_512bit_lnk.cmd

    Kind regards,
    Skyler

  • Skyler,

     

    I used aligh(32) in my application's .cmd file and there is still an error.

    I don't understand why the serial_flash_programmer.exe program doesn't work like C2Prog, being able to use the .out file directly, without needing to configure and compile a kernel for my board, and without needing to configure my application to work with it.

    C2prog loads the entire firmware in less than 10 seconds, just by pressing a button, as the GUI maintains the path from the last time I loaded the .out file.

    I give up trying to load the firmware with serial_flash_programmer.exe, I'm going to stick with C2prog.

    Thank you for your help,
    Ari

    Bit rate /s of transfer was: 29444.427734
    Application load successful!
    Done waiting for application to download and boot...
    SUCCESS of Command
    ERROR Status: PROGRAM_ERROR
    ERROR Address: 0x8084c
    Flash API Error: Invalid Address
    Please refer to the Flash API documentation for further explanation of the error.
    FMSTAT Register contents: 00

    What operation do you want to perform?
    1-DFU CPU1
    2-Erase CPU1
    3-Verify CPU1
    4-Unlock CPU1 Zone 1
    5-Unlock CPU1 Zone 2
    6-Run CPU1
    7-Reset CPU1
    0-DONE

  • Hi Ari,

    Are you able to provide your linker cmd file here for review? Can also accept through direct message.

    Thanks and regards,

    Charles