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.

Ethernet Bootlaoder for Tiva w/TI-RTOS

I am migrating an existing non-rtos project that was made for the Stellaris LM3S9D92 MCU to the TM4C1294 MCU with TI-RTOS.

I am building my project with CCS v6.1.1 with compiler v5.2.7, TI-RTOS v2.14.4.31 and XDCtools v3.31.1.33_core

The Stellaris code used a callback function that set a flag (g_bFirmwareUpdate) that forced the code to break the main while loop and run the function SoftwareUpdateBegin();

In TivaC with TI-RTOS I see that the functions ConfigureEnet() and UpdateBOOTP() are used instead. 

I have included files bl_emac.c and bl_config.h files in my project.

I cannot find an example of how to implement these function within TI-RTOS.

My questions:

Do I run ConfigureEnet() at the start of the program?

Is there a flag or event that gets set / posted to indicate that UpdateBOOTP() should run?

Do I exit out of BIOS with a BIOS_exit() command to run UpdateBOOTP()?

I am also not 100% sure of which defines in the bl_config.h file need to be set.

Thank you,

Sam Virgillo

  • Hello Sam,

    There is a similar resource on USB Boot Loader available on wiki. You may want to refer to the section on Boot Loader to be able to perform the same with Ethernet.

    processors.wiki.ti.com/.../TI-RTOS_USB_DFU

    Regards
    Amit
  • Success!

    I have successfully updated a TI-RTOS program on the TM4C1294 using the LM Flash Programmer.

    Step 1 is to include the lwiplib.c, swupdate.c and lwipopts.h files. (Ignore warnings regarding redefinition of macros) 

    also add include paths to the lwip functions in project properties. 

    Step 2 is to add a function that will be run when System_exit is called System_atexit(updateFunc); 

    Step 3 is to build a UDP receiving task handler that responds to the BOOTP magic port and data string and will call System_exit(0).

    This stops the running bios.

    In the updateFunc I run lwipInit(...) with the parameters normally used in an lwip non-RTOS application.

    Then I disable all processor interrupts as is normally done in the SoftwareUpdateBegin function.

    I pause for 500 mS and then call ROM_UpdateEMAC(g_ui32SysClock); 

    and away she goes.

    Whew!

  • Hello Sam

    If you make a good documentation with images, I can ask CCS forum to move it up to the processor wiki.... Credits included

    Regards
    Amit