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.

TM4C129ENCPDT: Flash programming of the TM4C129x over USB from another Host

Part Number: TM4C129ENCPDT
Other Parts Discussed in Thread: AM3352, EK-TM4C1294XL

TI Friends and Family!

Just casting a net out there for a potential project being worked on within the Tiva community.  This involves Flash programming of the TM4C129x over USB from another Host.  Here is more information on how the USB programming would need to work:

The TI Sitara AM3352 Linux Processor in this case, would need to inform the micro in the system that it wants to reprogram it.  This can be done either through the USB Interface if possible or via additional HW such as an IO or trigger as needed.  The goal is to not have any manual local intervention at the product (e.g. push a button or change a switch/jumper position) so that the reprogramming can be done remotely.  The USB BSL bootloader in the TM4C would have native USB peripheral/device support so that it could communicate through the USB [hub] to the AM3352 over the USB2.0 interface in 2.0 Full Speed Mode.  Linux running on the AM3352 would be able to initiate the reprogramming of the TM4C in the system and use an existing application/utility/script that sends the new image to the bootloader in the TM4C over the USB interface.  The new binary image would be stored in the memory accessible by the AM3352 on an existing processor board.  After reprogramming the TM4C restarts automatically or the new code can be executed by a command from Linux running in the AM3352 so that the USB enumeration process detects the device again and can use its serial communication port with the updated code.

We have the TI Flash boot loader source provided in TivaWare so we wouldn’t see why one couldn’t make some adjustments to it in order to handle this.  Some additional HW (ie IO or trigger may be needed as said).  We also have Host mode support and since it is just looking at USB 2.0 Full speed, we don’t think there would be an issue here from a USB standpoint.  Other mentions of only support downloading program in and not uploading it – in fact some of our sister TM4C123x devices are like that with ‘Device only’ mode.  Additionally, TM4C129x has EPI / Quad SPI for accessing external memories which is handy and appropriate in this case.

What we're interested in here if is anyone in the community has experience with this already?  In speaking within the TI family, it certainly seems possible but again wanted to cast a net out to see if anyone has further comments or input.

TY,

CY

  • Hi Chris,

      I think it is possible. As a matter of fact, there is a TivaWare example doing something like this. The example is C:\ti\TivaWare_C_Series-2.2.0.295\examples\boards\ek-tm4c1294xl\boot_demo_usb. The MCU is operating as a composite device supporting HID and DFU classes. There is no special I/O needed between the host and MCU to signal the firmware download. The host software (e.g. dfuprog from TivaWare) can determine that the device is capable of receiving software updates over USB. The runtime DFU protocol allows such tools to signal the device to switch into DFU mode and prepare to receive a new software image. The runtime DFU functionality requires only that the device listen for a particular request (DETACH) from the host and, when this is received, transfer control to the USB boot loader to re-enumerate as a pure DFU device capable of uploading and downloading firmware images. 

  • Charles (and Ralph offline),

    I thank you both for your input and clarifications.  I think we definitely have a viable game plan here.  I will discuss this project and advise of any additional comments or questions.  For now, we can call this resolved.

    Regards,

    Chris