Due to the FreedomBox project (and of course multiple individuals), Debian has had working DreamPlug support in its u-boot package since July, despite insufficient upstream support (this is being rectified, and the official release this December should support DreamPlug). In the Debian version, U-Boot can boot a kernel off of an ext2 (or derived) filesystem, which the boot loader shipped by the manufacturer cannot do.


It is always important to have a bootloader that is free software and meets Debian's standards of quality. It is important to be able to modify and build U-Boot from source, enabling or disabling features as desired. It is more convenient to not have to use a FAT partition to boot one's FreedomBox. In particular this prevents some problems where upgrading the box will result in broken systems, as seen recently here: http://www.plugcomputer.org/plugforum/index.php?topic=5965.0


Acquire Debian U-Boot package for armel, for example


Extract the contents of this package to a temporary directory, for example

dpkg-deb -x u-boot_2011.12-2_armel.deb /tmp/bootloaderfun

cd /tmp/bootloaderfun/usr/lib/u-boot/dreamplug/

There you should find a usr/lib/u-boot/dreamplug/ directory with two files, uboot.elf and u-boot.kwb. You will need both.

Make sure you have the OpenOCD installed, for example

aptitude install openocd

Make sure your DreamPlug is connected to the UART and JTAG ports on your GuruPlug JTAG board. Make sure the JTAG board is connected to your computer's USB port and is exposing a USB serial device.

Connect to your DreamPlug console via a serial communications program, for example

screen /dev/ttyUSB0 115200

Power on your DreamPlug, and run

sudo openocd -f /usr/share/openocd/scripts/board/sheevaplug.cfg -c init -c sheevaplug_load_uboot

If your cables are connected properly and the timing is right, you should now be running the Debian U-Boot from memory on your device. If not, check your cables and continue blindly re-running this command as the box boots and reboots. Wait for that magic moment.

The banner should say 2011.12, and if you run 'version' at the U-Boot prompt, it should tell you that it was built on Debian. If this is not the case, something has gone wrong.

Next, put the u-boot.kwb file from that directory onto a TFTP server that you control, on a network reachable by your DreamPlug. There are alternative methods for getting this file to your plug computer, if you prefer, but they are not be enumerated here.

Set up the network and TFTP the image to the DreamPlug. This assumes that you have allocated IP for your DreamPlug, your TFTP server is, and you have named the image on the TFTP server dreamplugfreedom.kwb.

setenv ipaddr

setenv serverip

tftp 0x6400000 dreamplugfreedom.kwb

If this succeeds, you will see something like

Bytes transferred = 193952 (2f5a0 hex)

Note the hex number, as we will be using it for the write to SPI/NOR flash.

sf probe 0

sf erase 0x0 0x100000

sf write 0x6400000 0x0 [put the hex number from earlier here, prefixed wit a "0x", so something like :0x2f5a0]

Now, if everything has gone smoothly, you are finally running Debian's U-Boot on your DreamPlug. Check by resetting the plug.


It should now boot up with the banner describing the appropriate version, and when you run 'version' it should give the same.

At this point you will probably want to adjust your boot config with a series of setenv command followed by a 'saveenv'.

Enjoy your free software.