1 (edited by BarryMead 2011-03-19 17:47:25)

Topic: Restore ROM image in microSD Card

Many of us who have been experimenting with the Chumby Hacker board will no-doubt make a mistake along the way, and need to restore the firmware to the way it came from the factory.  This link will allow you to download the official rom-falconwin.img file that you can use to create a factory fresh microSD card:

http://files.chumby.com/sean/rom-hackerboard-3320.zip

The procedure to put this image onto a microSD flash card can be found here (except change 64M to 32M) on the dd commands:

http://www.ladyada.net/learn/chumby/microsd.html

There is one tiny glitch, however with this ROM image file.  The partition table has some overlapping partitions in it that can be repaired by mounting the microSD card on a desktop linux computer and running the fdisk utility.  I was hoping that a ROM image file without this glitch (overlapping partitions) would be available so I didn't have to fix the partition table every time I restored my chumby.   Since I couldn't find a de-glitched version of the ROM image, I decided to make a program to create one.  After correcting the partition table with fdisk, I copied the corrected ROM to a new image file, and compared it with the original one downloadable above.  The little delta utility that I wrote found only two bytes that were not correct, so I wrote a tiny fixrom utility which copies the original ROM image to a new file while patching only those two incorrect bytes.

You can download the source code for these two utilitly programs delta.c and fixrom.c from the adafruit forum at this web address:

http://forums.adafruit.com/viewtopic.ph … p;start=15

The two 1-page c programs are very well documented so you can easily see what they do and how they work.


So to make a long story short.

1. Download the rom-falconwing.img file above
2. Download the fixrom.c utility
3. compile the fixrom.c utility  gcc -Wall fixrom.c -o fixrom
4. Correct the ROM image   ./fixrom rom-falconwing.img  rom-falconwing-fixed.img
5. Burn your microSD card with the rom-falconwing-fixed.img file and your partition tables will not overlap or need to be repaired.


Hope this helps you,  Barry Mead