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.

TMS320F28379D: TMS320F2837xD Field Firmware update procedure

Part Number: TMS320F28379D
Other Parts Discussed in Thread: C2000WARE

Hi,

I am planning to use TMS320F2837xD in my custom design. Before moving to further steps. I needed few info about field firmware update for TMS320F2837xD.

As per my understanding TMS320F2837xD will support I2C boot mode. Referred section 4.9.4.4 I2C Boot Mode from "TMS320F2837xD Dual-Core Delfino Microcontrollers" TRM.

I2C boot mode configuration setting can be done by using "Stand-Alone Boot Mode" setup from "https://www.ti.com/lit/an/sprt720/sprt720.pdf?ts=1603132051489&ref_url=https%253A%252F%252Fwww.ti.com%252Ftool%252FLAUNCHXL-F28379D".

So with reference to above document. I need to make below changes to boot from I2C.

1. GPIO-72 and 84 (BOOTCTRL Pins) Set to 1'b and 1'b Respectively i.e, GetMode

2. OTP_KEY = 0x5A

3. OTP_BMODE = 0x05 (I2C-A)

So, Once above sequence passes. Boot ROM will start loading the application firmware stored in I2C EEPROM with Slave address 0x50 to RAM and start executing the application. Is my understanding is correct ?

How to set the OTP_KEY and OTP_BMODE to the required value. How can I over write the data to my required operation.

Boot ROM will contain I2C boot code "C:\ti\c2000\C2000Ware_DigitalPower_SDK_3_00_01_00\c2000ware\libraries\boot_rom\f2837xd\revB\rom_sources\F2837x_bootROM\cpu01-bootROM\source". Will this Boot ROM by default pre-loaded with all the boot loader support ?

As per my understanding, CCS will generate .hex file and that hex file should be loaded into I2C EEPROM(0x50). Then only in boot mode, I2C Boot ROM can fetch the application firmware from EEPROM and loading into RAM and starts execution. So here my query is How to program my application into I2C EEPROM. Do we have any reference design I can use ?

--> Since in I2C Boot ROM, As well in TRM I found about Boot loaders. I couldn't find anything about Boot programmer. So Do I need to connect another microcontroller to the same EEPROM in MultiMaster mode and need to program the .hex file to EEPROM. or TMS320F2837xD  can do this. If TMS320F2837xD  can do How do I need to keep the device in Boot Programmer mode and update application firmware into I2C EEPROM.

Instead of using I2C EEPROM, Can I update my application firmware into Flash memory available in TMS320F2837xD FLASH (256Kx16). If that needs to be done. I think I need to use UART from host programmer.

"C:\ti\c2000\C2000Ware_DigitalPower_SDK_3_00_01_00\c2000ware\utilities\flash_programmers\serial_flash_programmer". Is my understanding is correct ? Dow we have any reference design for loading my application firmware into flash memory. and what interface I need to use from my host computer. I would like to have my custom stand alone flash programmer. 

Best Regards,

Prasanna

  • Prasanna, an SME will get back to you on this by tomorrow. Thanks, Sira

  • Prasannakumar M N said:

    So with reference to above document. I need to make below changes to boot from I2C.

    1. GPIO-72 and 84 (BOOTCTRL Pins) Set to 1'b and 1'b Respectively i.e, GetMode

    2. OTP_KEY = 0x5A

    3. OTP_BMODE = 0x05 (I2C-A)

    So, Once above sequence passes. Boot ROM will start loading the application firmware stored in I2C EEPROM with Slave address 0x50 to RAM and start executing the application. Is my understanding is correct ?

    Yes, that is correct

    Prasannakumar M N said:

    How to set the OTP_KEY and OTP_BMODE to the required value. How can I over write the data to my required operation.


    Note that OTP is one time programmable, so make sure to follow the emulation boot details in the boot TRM chapter first. You can use the CCS flash utility (connect to device, go to Tools->Onchip flash) or device application to program OTP. For application, see in C2000Ware (\device_support\f2837xd\examples\cpu1\blinky_with_DCSM).

    Prasannakumar M N said:

    Boot ROM will contain I2C boot code "C:\ti\c2000\C2000Ware_DigitalPower_SDK_3_00_01_00\c2000ware\libraries\boot_rom\f2837xd\revB\rom_sources\F2837x_bootROM\cpu01-bootROM\source". Will this Boot ROM by default pre-loaded with all the boot loader support ?

    As per my understanding, CCS will generate .hex file and that hex file should be loaded into I2C EEPROM(0x50). Then only in boot mode, I2C Boot ROM can fetch the application firmware from EEPROM and loading into RAM and starts execution. So here my query is How to program my application into I2C EEPROM. Do we have any reference design I can use ?


    Yes all those bootloaders are what's included in ROM already. Those source are for reference and/or stepping through ROM for debug.
    I'm not aware of a reference design but in C2000Ware there is I2C eeprom example that can be adapted to write to EEPROM.

    Prasannakumar M N said:

    --> Since in I2C Boot ROM, As well in TRM I found about Boot loaders. I couldn't find anything about Boot programmer. So Do I need to connect another microcontroller to the same EEPROM in MultiMaster mode and need to program the .hex file to EEPROM. or TMS320F2837xD can do this. If TMS320F2837xD can do How do I need to keep the device in Boot Programmer mode and update application firmware into I2C EEPROM.


    This will vary per your design. With the I2C boot mode selected, if the EEPROM HEX key isn't correct, it will boot to flash. So once you're in your flash app, if you need to update, your app can switch to a mode where it receives the new app using some communication peripheral and then programs the EEPROM. Then you can reset the device and it will load the new EEPROM image. That's just one thought.

    Prasannakumar M N said:

    Instead of using I2C EEPROM, Can I update my application firmware into Flash memory available in TMS320F2837xD FLASH (256Kx16). If that needs to be done. I think I need to use UART from host programmer.

    "C:\ti\c2000\C2000Ware_DigitalPower_SDK_3_00_01_00\c2000ware\utilities\flash_programmers\serial_flash_programmer". Is my understanding is correct ? Dow we have any reference design for loading my application firmware into flash memory. and what interface I need to use from my host computer. I would like to have my custom stand alone flash programmer.


    Yes, that is the correct utility. See app note: https://www.ti.com/lit/sprabv4

    Best regards
    Chris

  • Chris,

    Thanks for detailed Info, I may need few more clarification. Please check my in-line comments.

    Note that OTP is one time programmable, so make sure to follow the emulation boot details in the boot TRM chapter first. You can use the CCS flash utility (connect to device, go to Tools->Onchip flash) or device application to program OTP. For application, see in C2000Ware (\device_support\f2837xd\examples\cpu1\blinky_with_DCSM).

    >> You mean by using JTAG I need to keep the device in emulation mode and update the OTP_KEY and OTP_BMODE. As you mentioned that by using device application also I can program OTP means. An application firmware can be used to access the DCSM register and change the BMODE. Is my understanding is correct ?

    This will vary per your design. With the I2C boot mode selected, if the EEPROM HEX key isn't correct, it will boot to flash. So once you're in your flash app, if you need to update, your app can switch to a mode where it receives the new app using some communication peripheral and then programs the EEPROM. Then you can reset the device and it will load the new EEPROM image. That's just one thought.

    >> Suppose my EEPROM HEX key also correct means it will start running my application (Just consider my application Firmware Version 1.4), and I need to update the new version of application firmware (lest be 1.5), How I can keep the device in boot programming mode. Some other communication means what are the modes that are supported.

    Boot ROM, firmware can't be modified correct ?

    Yes, that is the correct utility. See app note: ++

    >> That utility uses UART commands from Host PC and update the firmware to the flash. But I would like to take I2C data from my master controller and update the flash. would that be possible. Is Flash kernel is like keeping Second stage boot loader in flash. It can receive I2C data and program it to Flash/EEPROM anything. For decoding the hex file and how it should be programmed can be taken from the app note mentioned by you correct ?

    Where can I get the source code for flash kernel. and where it resides. How to update the flash kernel ?

    Best Regards,

    Prasanna

  • Hello

    Prasannakumar M N said:

    Note that OTP is one time programmable, so make sure to follow the emulation boot details in the boot TRM chapter first. You can use the CCS flash utility (connect to device, go to Tools->Onchip flash) or device application to program OTP. For application, see in C2000Ware (\device_support\f2837xd\examples\cpu1\blinky_with_DCSM).

    >> You mean by using JTAG I need to keep the device in emulation mode and update the OTP_KEY and OTP_BMODE. As you mentioned that by using device application also I can program OTP means. An application firmware can be used to access the DCSM register and change the BMODE. Is my understanding is correct ?

    The boot emulation mode allows you test your boot configuration values in RAM to make sure your setup is correct. Then you can more confidently program OTP since it can’t be changed once set. You can use the application to do the programming as just another option. Again, once the boot mode is set in the OTP, it can’t be changed. I’d assume most users set it through the CCS flash utility.

    Prasannakumar M N said:

    This will vary per your design. With the I2C boot mode selected, if the EEPROM HEX key isn't correct, it will boot to flash. So once you're in your flash app, if you need to update, your app can switch to a mode where it receives the new app using some communication peripheral and then programs the EEPROM. Then you can reset the device and it will load the new EEPROM image. That's just one thought.

    >> Suppose my EEPROM HEX key also correct means it will start running my application (Just consider my application Firmware Version 1.4), and I need to update the new version of application firmware (lest be 1.5), How I can keep the device in boot programming mode. Some other communication means what are the modes that are supported.

    With a valid key in the EEPROM, the I2C bootloader will always load that app to RAM to run. With the boot GPIOs set as you described, this I2C bootloader will be run on every device reset. Your application will need a method to reprogram the EEPROM before pulling a device reset which will then run the new application. How you do this is up to your design. Your app running in RAM can somehow determine its time to update the firmware in which it receives the new app HEX via SCI, I2C, CAN, etc and programs it to the EEPROM. Then once complete, the device can be reset to run the updated app.

    Prasannakumar M N said:

    >> That utility uses UART commands from Host PC and update the firmware to the flash. But I would like to take I2C data from my master controller and update the flash. would that be possible. Is Flash kernel is like keeping Second stage boot loader in flash. It can receive I2C data and program it to Flash/EEPROM anything. For decoding the hex file and how it should be programmed can be taken from the app note mentioned by you correct ?

    Where can I get the source code for flash kernel. and where it resides. How to update the flash kernel ?

    The flash kernels we have available are for SCI, you can use them as a reference to create something with I2C. Flash kernels are in C2000Ware (\device_support\f2837xd\examples\dual)

    Best regards

    Chris