Menu

Installation

btsimonh

NOTE: The CURRENT version of squashfs image does NOT destroy the OpenRG image.

before you start, backup /dev/mtdblock0 from OpenRG linux prompt - this is the whole nand flash.
Make a note of your MAC address. This will boot to a default one... (see details in mach file - you can put yours into the uboot environment).

To install OpenWRT permenantly:

Install the u-boot as described in the package.

Obtain the latest image in trunk/bin in the code repository ('code' above), and put it in a folder with tftpd32.exe, and run tftpd32.

from u-boot prompt:
(don't type the // bits...)

//fill memory area with FF so jffs2 is not upset
mw 81000000 ff 550000
// erase flash after OpenRG image data
nand erase 0x0E04000 0x11fC000
// tftp image over
tftpboot 81000000 openwrt-lantiq-danube-BTHOMEHUBV2B-squashfs.image
// write to flash (big enough)
nand write 0x81000000 0x0E04000 0x550000
// boot image
bootm 0x81000000

wait 3 minutes minimum for jffs2 to be prepared.
Access the router LUCI interface on http://192.168.1.1

now telnet to 192.168.1.1

the image has uboot-envtools pre-installed.
enter the following at OpenWRT prompt:
echo /dev/mtd1 0x0 0x10000 0x10000 >/etc/fw_env.config
fw_printenv

fw_setenv nboot "nand read 0x81000000 0xe04000 0x550000; bootm 0x81000000"
fw_setenv bootcmd "run nboot"
fw_setenv bootdelay 20
fw_setenv preboot "setenv stdin nc; setenv stdout nc; setenv stderr nc"

NOTE: i have had some booting problems without LAN. These seem to be solved by using:
fw_setenv preboot "setenv stdin nc; setenv stdout serial; setenv stderr serial"
This means you won't see boot logs via nc, but CAN interrupt the boot process by running nc and hitting a key. You can then type 'setenv stdout nc' to get a prompt.

Luci (web interface) is now pre-installed

To re-run OpenRG:
run up nc as described in the u-boot zip on this site.
interrupt the boot process.
at the uboot prompt, type
dualimage
bootm 0xa0500000

this will start the original firmware.

To have more room in flash jffs2, and destroy the OpenRG image:
edit mach-bthomehubv2b.c
change
define NAND_KEEPOPENRG
to
define NAND_ONLYOPENWRT

rebuild the squashfs image.

do the flashing procedure, with
//fill memory area with FF so jffs2 is not upset
mw 81000000 ff 550000
// erase flash after art image data
nand erase 0x004000 0x1ffC000
// tftp image over
tftpboot 81000000 openwrt-lantiq-danube-BTHOMEHUBV2B-squashfs.image
// write to flash (big enough)
nand write 0x81000000 0x004000 0x550000
// boot image
bootm 0x81000000


Related

Wiki: Home