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.

TM4C129XNCZAD: Flash based bootloader issue

Part Number: TM4C129XNCZAD

Dear sir,

Example use by  given in tiva library.

I am using the flash based bootloader.

The bootloader code with configure uart 0 rest on adress 0x0000

and application code rest on adress 0x4000.

Lm flash loader used for dumping .bin file.

It s working.

Now while dumping the new file through Lm flash loader @0x4000 application address ,communication interrupted due to power  failure. 

Now not able to recover original earlier one programme.

My question is that

1.If prograame dumping interrupted by anything then my earlier programme will remain after restart device?( It is not in my case)

How can we again dump or reinitiate  process

2. If programme interrupt then again try to dump through LM flash loader then won't responding to accept dumping ( As mention Uart 0 is using)

3. As metioned in attached file steps for  start up code we have to write or it is given in examples. We are using keil RV MDK.

I thought you have given the examples in tiva library means it is proven and already have steps 

Intialize memory,copy the boot loader from flash to sram

Please suggest 

Regards,

Rajesh

  • Hello Rajesh,

    So what you are seeing is that right now if the boot loader is configured with an APP_START_ADDRESS of 0x4000 and it seems valid application code at that address, it will start the application instead of the boot loader even though the application code was not fully loaded.

    The two best means to guard against this case are as follows:

    1) Add an I/O that can be toggled which can be used to force the boot loader to run. The standard implementation is before checking for a valid application code, the boot loader polls an I/O pin to check the level and if matches either high or low, then ignore the application code check and enter the boot loader regardless. This is provided in the flash bootloader with the FORCED_UPDATE parameters that can be configured.

    2) Have a validation check added as part of the boot loader. The code won't be allowed to execute until it's confirmed the full image has been flashed. If the validation fails, the boot loader returns back to a state where it is waiting for new application code. This can be done with CRC via the CHECK_CRC feature in the Flash boot loader (requires some application adjustments, you'd have to read up on the usage) or more advanced processes like described in this app note: https://www.ti.com/lit/pdf/spma083

    Best Regards,

    Ralph Jacobi