Firmware/Flash update over the GPRS

18 Apr 2012

Did I dream of that or did I really sough a project of firmware update over the ethernet (IP Bootloader)?

I was thinking of the same thing but using GPRS device (SIM908 or WISMO228) to connect to the internet and the server with new bin/hex firmware file...

Any thoughts/help much appreciated... ;)

18 Apr 2012

Checkout this notebook page: http://mbed.org/users/shintamainjp/notebook/firmwareupdater_en/

The crux is that you save your newly updated .bin file to the root of the LocalFileSystem, delete all the other .bin files from the LocalFilesystem to force your updated one to be the newest, and then ask the interface chip to go through a reset cycle.

19 Apr 2012

This is for mbed. What about LPC1768 itself (without mbed and localfilesystem)?

I was thinking external flash sd card, or if the firmware uses only 256kB, to download new firmware on the upper 256KB, and then to copy it in lower 256KB...

Or if the firmware is bigger then 256KB and there is no external flash memory, then it would have to copy primary routines for GPRS and IAR into the RAM, and run them from RAM, and download firmware in segments and update FLASH...

I am new to the ARM, but I'm AVR gooroo. So I did the bootloader in ATmega128 that resided in bootloader area (only 8KB of memory), and it had GPRS routines, HTTP protocol implemented, and IAR. The bootloader was downloading 2KB (just 4K of RAM) of flash at the time and writing it in FLASH... After doing all 120KB of mega128, it just started new firmware...

So I was thinking doing something similar in ARM, where I have larger FLASH, but also more freedom because of 96KB of RAM...

So any help is appreciated to do routines as described...

19 Apr 2012

You can look at this sample to see how to use the In Application Programming functionality of the lpc1768 to program FLASH.

Import programIAP_internal_flash_write

Sample code for how to erase/write LPC1768, LPC11U24, LPC1114, LPC812 and LPC824 internal flash memory. This program uses IAP call of MCU's ROM routines. The IAP library also supports read/write of EEPROM in LPC11U24.

Section 32.8 of http://ics.nxp.com/support/documents/microcontrollers/pdf/user.manual.lpc17xx.pdf discusses this in more detail.

I don't know if anyone has done exactly what you are planning to do. I know that the R2C2 reprap firmware has a bootloader which will pull new binaries from a SD card and load this into the internal FLASH so that code might be a good starting point for your own project. It can be found at https://github.com/bitboxelectronics/R2C2_Firmware

Hope that helps,

Adam

19 Apr 2012

Adam, thank you very much for the info... ;)

If anyone has more info, hit me...

Now I have to figure out how to connect microSD card, and get busy with coding...

19 Apr 2012

Goran Jurkovic wrote:

Now I have to figure out how to connect microSD card, and get busy with coding...

http://mbed.org/cookbook/SD-Card-File-System

19 Apr 2012

Hi,

I have made a sdcard bootloader. It is quite simple now but forms the basic mean to load new firmware. I just load a xxx.BIN file onto a folder and once you press reset, the bootloader checks to see if there is a .BIN file and burns it. Once it completes, it checks the check sum and then deletes the file.

The next step is to do firmware updates over wired ethernet and GPRS but its easy. All you need to do is grab the file, save it on the sdcard, do some crc checks and reset through watchdog timer. Then the primary bootloader will see that new firware is available.

20 Apr 2012

Could I import it to try it? And maybe upgrade it with GPRS?

21 Apr 2012

/media/uploads/nk15/bootloader_sdcard.zip

Hi,

Here you are. Its based on lpcxpresso project. Application address is at 0x7000.

Regards, N.Karakotas

13 Jan 2013

Of course it can. I have already implemented downloading and flashing firmware over GPRS with a SIM900D. Any module will do. You need to use CRC in order to make sure you don't flash corrupted data.

Regards, Nick

20 Jan 2017

Hi, I am wondering whether is there any pointer/idea on how to do this with a with different board? It is because I am using NUCLEO L073RZ but could not find any way to do this. Help is greatly appreciated!