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.

TMS320F280049: serial flash programming through F28004x flash kernel

Part Number: TMS320F280049
Other Parts Discussed in Thread: C2000WARE

Hi,

I'm testing the serial flash programming function for my customer. I tested with "flashapi_ex2_sci_kernel.txt" in C2000ware,

the directory is C:\ti\c2000\C2000Ware_1_00_02_00\utilities\flash_programmers\serial_flash_programmer\f28004x_fw_upgrade_example.

I can download the flash kernel to RAM through SCI bootloader, but when I command to erase or upgrade the application project, there will be error.

The error when I try to erase the flash is shown as below. What does the error mean? How can I fix it?

  • Howard,

    What is the command that you used to load the kernel for F280049?

    Thanks and regards,
    Vamsi
  • Vamsi,

    the command is 

    "serial_flash_programmer.exe -d f28004x -k flashapi_ex2_sci_kernel.txt -a led_ex1_blinky.txt -p COM14"

    I can download the kernel, but I cannot erase flash or write new application project code to the flash.

  • Howard,

    I reviewed the code for the kernel. Based on the error that we see in the above snapshot, looks like the device is not receiving the correct command and hence it is failing to erase. Can you try a lower baud rate like 9600?

    Thanks and regards,
    Vamsi
  • Vamsi,

    I got the same error with baud rate 9600. I don't think the problem is related to baud rate because the flash kernel is already downloaded to the device.

    In command window it already asked us

    What operation do you want to perform?

            1-DFU

            2-Erase

            3-Verify

            4-Unlock Zone 1

            5-Unlock Zone 2

            6-Run

            7-Reset

            8-Live DFU

            0-DONE

    Could you please have a test on the F280049 DOCK and see if there is the same problem? Thanks.

  • Howard,

    Thank you for trying a lower baud rate.  I saw your snapshot and understood that the kernel is loaded.  But, I noticed that the kernel initiates another autobaud lock after it configures the PLL so that it can download the application at a higher speed.  Hence asked you to try a lower baud rate.

    The above command window messages are from the host PC software.  

    It may be that the kernel is not able to successfully configure the PLL on your device.  

    When the erase fails, can you connect CCS (via JTAG) to the device and load the symbols of the flash kernel and see where it is stuck?  

    Also, please enable the verbose output mode to look for more info.

    I asked our Serial Kernel developer to take a look at this.  He is out of office now and will be back next week.

    Thanks and regards,

    Vamsi 

  • Howard,

    Please use the -v command line argument for verbose printing as Vamsi has suggested.

    Also, please confirm that the kernel is using the correct GPIO pins for SCI communication as the SCI bootloader you are using?

    Are you using a controlCARD?

    Regards,
    sal
  • Yes, I'm using controlCARD. and I've configured GPIO24=0, GPIO32=1 for (boot from SCI/Wait Mode), by default I think it's boot from SCI, right?

    And I'm using the USB cable which connect the board and PC to serve as SCI communication cable, I think the device FT2232HL will convert SCI to USB, right?
    Have you tested with the controlCARD? looking forward to your answer.

  • Hi Howard,

    Yes, it is SCI boot which runs the SCI bootloader necessary for the serial flash programmer.

    Yes, it communicates SCI/UART over the USB connection.

    Yes, we have tested it.

    Let us know if you have any other questions.

    Pay attention to what SCI GPIO pins are used by the bootloader and which pins you compile the SCI flash kernel to use. There is a #define in the SCI flash kernel to select which SCI GPIO pins you are using.

    Also, the default SCI boot loader does not use the pins which are pinned out to the FTDI chip. You will need to use SCI BOOT1.

    sal
  • There's no SCI flash kernel project in C2000ware, only a txt file.

    I'm not sure what you mean that "the default SCI boot loader does not use the pins which are pinned out to the FTDI chip",

    are you referring to the bootloader in the ROM? But i've checked the TRM it's using GPIO28 AND GPIO29, which are connected to FTDI.

    If you are referring to the SCI flash kernel, I'm not able to change it since I don't have the original project file. And it makes no sense for the flash kernel to use a different pair of pins to download the application project.

  • there is a flash kernel example under flashapi in the examples folder.

    You can disregard the comment about default SCI pins. This is only an issue with the F3837x controlCARD.

    sal