wdenk | 012771d | 2002-03-08 21:31:05 +0000 | [diff] [blame] | 1 | #!/usr/bin/kermit + |
| 2 | # usage: ./flash_param parameters |
| 3 | # Parameters: IP Address ETH Address ERIC Number |
| 4 | # Format: xxx.xxx.xxx.xxx xx:xx:xx:xx:xx:xx xxxx |
| 5 | |
| 6 | set line /dev/ttyS0 |
| 7 | set speed 115200 |
| 8 | set serial 8N1 |
| 9 | set carrier-watch off |
| 10 | set handshake none |
| 11 | #set flow-control none |
| 12 | set flow-control xon/xoff |
| 13 | #robust |
| 14 | set file type bin |
| 15 | set file name lit |
| 16 | set rec pack 1000 |
| 17 | set send pack 1000 |
| 18 | set window 5 |
| 19 | set prompt Kermit> |
| 20 | #robust |
| 21 | # Milliseconds to pause between each OUTPUT character |
| 22 | set output pacing 1 |
| 23 | |
| 24 | out \13 |
| 25 | in 10 => |
| 26 | #first erase the environment memory within NVRAM |
| 27 | out mw f0000000 0 200\13 |
| 28 | in 10 => |
| 29 | out reset\13 |
| 30 | in 5 autoboot |
| 31 | out \13\13 |
| 32 | in 10 => |
| 33 | #set additional env parameter |
| 34 | out setenv ethaddr \%2\13 |
| 35 | in 10 => |
| 36 | out setenv serial# ERIC 1.0 \%3\13 |
| 37 | in 10 => |
| 38 | out setenv eric_id \%3\13 |
| 39 | in 10 => |
| 40 | #out setenv prec_videocard_bus unknown\13 |
| 41 | #in 10 => |
| 42 | #out setenv prec_bios_type unknown\13 |
| 43 | #in 10 => |
| 44 | out setenv eric_passwd .eRIC.\13 |
| 45 | in 10 => |
| 46 | #out setenv bootargs root=/dev/ram ramdisk_size=8192 init=/sbin/init ip=\%1:192.168.1.100:192.168.1.254:255.255.255.0\13 |
| 47 | #out setenv bootargs root=/dev/ram ramdisk_size=8192 init=/sbin/init ip=\%1:192.168.0.1\13 |
| 48 | #out setenv bootargs root=/dev/ram ramdisk_size=8192 init=/sbin/init ip=\%1\13 |
| 49 | out setenv bootargs console=/dev/ttyS0,115200 root=/dev/nfs nfsroot=192.168.1.26:/eric_root_devel ip=\%1:192.168.1.26\13 |
| 50 | in 10 => |
| 51 | out setenv bootcmd bootm FFC00000\13 |
| 52 | in 10 => |
| 53 | out saveenv\13 |
| 54 | in 10 => |
| 55 | out reset\13 |
| 56 | in 5 autoboot |
| 57 | out \13\13 |
| 58 | in 10 => |
| 59 | quit |
| 60 | exit 0 |