r4128 - trunk/src/host/devirginator
werner at sita.openmoko.org
werner at sita.openmoko.org
Thu Feb 28 12:25:32 CET 2008
Author: werner
Date: 2008-02-28 12:25:28 +0100 (Thu, 28 Feb 2008)
New Revision: 4128
Added:
trunk/src/host/devirginator/config.gta01bv4
Removed:
trunk/src/host/devirginator/config.phase0
Modified:
trunk/src/host/devirginator/mknor
trunk/src/host/devirginator/setup.sh
Log:
mknor: removed "under construction" warning
mknor: added usage instructions for "flashnor"
mknor: the path to the u-boot binary is no longer hard-coded by must be passed
on the command line
mknor: added option "-o outfile" to change the output file from the default
nor.bin
setup.sh: generate the NOR binary on non-GTA01
config.gta01bv4: example devirginator configuration for GTA01Bv4
config.phase0: obsolete - removed
Added: trunk/src/host/devirginator/config.gta01bv4
===================================================================
--- trunk/src/host/devirginator/config.gta01bv4 2008-02-28 10:15:47 UTC (rev 4127)
+++ trunk/src/host/devirginator/config.gta01bv4 2008-02-28 11:25:28 UTC (rev 4128)
@@ -0,0 +1,20 @@
+#
+# config.gta01bv4 - Devirginator configuration file
+#
+# This is a shell script sourced by "setup.sh".
+#
+
+OPENOCD_HOST=localhost
+PLATFORM=gta01
+BOARD=bv4
+
+stuff=http://buildhost.openmoko.org/daily/neo1973/deploy/glibc/images/neo1973/
+
+LOWLEVEL=$stuff/lowlevel-foo-$PLATFORM$BOARD-latest.bin
+UBOOT=$stuff/uboot-$PLATFORM$BOARD-latest.bin
+UIMAGE=$stuff/uImage-neo1973-latest.bin
+ROOTFS=$stuff/openmoko-devel-image-fic-$PLATFORM.jffs2
+
+DFU_UTIL=$stuff/dfu-util
+#OPENOCD=$stuff/openocd
+OPENOCD_CFG=http://people.openmoko.org/werner/openocd.cfg
Deleted: trunk/src/host/devirginator/config.phase0
===================================================================
--- trunk/src/host/devirginator/config.phase0 2008-02-28 10:15:47 UTC (rev 4127)
+++ trunk/src/host/devirginator/config.phase0 2008-02-28 11:25:28 UTC (rev 4128)
@@ -1,22 +0,0 @@
-#
-# config - devirginator configuration
-#
-# This is a shell script sourced by "setup.sh".
-#
-
-OPENOCD_HOST=localhost
-SNAPSHOT=20070301
-BOARD=bv3
-
-
-stuff=http://buildhost-old.openmoko.org/snapshots/gta01-20070301/tmp/deploy/images
-
-LOWLEVEL=$stuff/lowlevel_foo-gta01bv3-20070302200829.bin
-UBOOT=$stuff/u-boot-gta01bv3-20070302200829.bin
-UIMAGE=$stuff/uImage-2.6-200703022008-fic-gta01.bin
-ROOTFS=$stuff/openmoko-devel-image-fic-gta01-20070302115654.rootfs.jffs2
-
-DFU_UTIL=$stuff/dfu-util
-
-OPENOCD=$stuff/openocd
-OPENOCD_CFG=http://people.openmoko.org/werner/openocd-debugv2.cfg
Modified: trunk/src/host/devirginator/mknor
===================================================================
--- trunk/src/host/devirginator/mknor 2008-02-28 10:15:47 UTC (rev 4127)
+++ trunk/src/host/devirginator/mknor 2008-02-28 11:25:28 UTC (rev 4128)
@@ -8,15 +8,6 @@
#
#
-# WARNING * WARNING * WARNING * WARNING * WARNING * WARNING * WARNING * WARNING
-#
-# This isn't the final version of NOR image creation yet, and some things may
-# not work as expected.
-#
-# WARNING * WARNING * WARNING * WARNING * WARNING * WARNING * WARNING * WARNING
-#
-
-#
# Write to NOR with the following commands:
#
# flash_unlock /dev/mtd0
@@ -27,6 +18,13 @@
# flash_erase /dev/mtd0 0 13
# (or similar, depending on the image size)
#
+# Or just use the "flashnor" script:
+#
+# norwp rw
+# ifconfig usb0 192.168.0.200 up
+# scp tmp/nor.bin flashnor 192.168.0.202:
+# ssh 192.168.0.202 ./flashnor nor.bin
+#
#
# NOR map:
@@ -43,8 +41,23 @@
# 0x18 1F FFFF end of NOR (2MB)
#
-#unzip 0x18070000 0x8800000 0x96000
+usage()
+{
+ echo "usage: $0 [-o outfile ] u-boot" 1>&2
+ exit 1
+}
+
+
+out=nor.bin
+if [ "$1" = -o ]; then
+ [ ! -z "$2" ] || usage
+ out="$2"
+ shift 2
+fi
+[ ! -z "$1" -a -z "$2" ] || usage
+uboot="$1"
+
./scriptify.pl <<EOF >_script
neo backlight off
neo backlight on
@@ -61,13 +74,13 @@
./envedit.pl -D GTA02 -D NOR_ENV -f environment.in -o _env
./blink.pl \
- /home/moko/2624/u-boot/u-boot.udfu at 0 \
+ "$1"@0 \
_splash at 0x40000 \
'"autoscr 0x18050100"'@0x50000 \
_script at 0x050100 \
_env at 0x51000 \
0x18050000@=0x40 \
0x18051004 at 0x44 \
- >nor.bin || { rm -rf nor.bin; exit 1; }
+ >$out || { rm -rf $out; exit 1; }
rm -f _splash _script _env
Modified: trunk/src/host/devirginator/setup.sh
===================================================================
--- trunk/src/host/devirginator/setup.sh 2008-02-28 10:15:47 UTC (rev 4127)
+++ trunk/src/host/devirginator/setup.sh 2008-02-28 11:25:28 UTC (rev 4128)
@@ -328,6 +328,15 @@
add_file tmp/splash.gz
+# --- Stage 3: the NOR --------------------------------------------------------
+
+
+if [ "$PLATFORM" != gta01 ]; then
+ ./mknor -o tmp/nor.bin "$UBOOT"
+ add_file tmp/nor.bin
+fi
+
+
# --- "devirginate" shell script ----------------------------------------------
More information about the commitlog
mailing list