changes?
This commit is contained in:
parent
96666cca2d
commit
6f101ed6dc
@ -1,8 +1,9 @@
|
|||||||
set timeout 30
|
#!/usr/bin/expect -d
|
||||||
|
|
||||||
|
set timeout 100
|
||||||
|
exp_internal 1
|
||||||
|
|
||||||
set send_human {.1 .3 1 .05 2}
|
set send_slow {1 0.005}
|
||||||
set send_slow {1 0.001}
|
|
||||||
|
|
||||||
spawn picocom -b 115200 /dev/ttyUSB0 --logfile typescript
|
spawn picocom -b 115200 /dev/ttyUSB0 --logfile typescript
|
||||||
|
|
||||||
@ -17,7 +18,7 @@ send "new2day\n"
|
|||||||
|
|
||||||
expect {
|
expect {
|
||||||
"Boot (PRI)-> " {
|
"Boot (PRI)-> " {
|
||||||
send -s {setenv ramboot_openwrt "setenv ipaddr 10.0.7.2; setenv serverip 10.0.7.1; tftpboot 0x2000000 openwrt-mpc85xx-p1020-extreme-networks_ws-ap3825i-initramfs-kernel.bin; interrupts off; bootm 0x2000000;"; setenv boot_openwrt "bootm 0xEC000000;" setenv bootcmd "run boot_openwrt"; saveenv;
|
send -s {setenv ramboot_openwrt "setenv ipaddr 10.0.7.2; setenv serverip 10.0.7.1; tftpboot 0x2000000 openwrt-mpc85xx-p1020-extreme-networks_ws-ap3825i-initramfs-kernel.bin; interrupts off; bootm 0x2000000;"; setenv boot_openwrt "bootm 0xEC000000;"; setenv bootcmd "run boot_openwrt"; saveenv;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -31,10 +32,11 @@ expect {
|
|||||||
"Please press Enter to activate this console." {
|
"Please press Enter to activate this console." {
|
||||||
send -s "\n"
|
send -s "\n"
|
||||||
sleep 1
|
sleep 1
|
||||||
|
send -s {
|
||||||
|
while ! sysupgrade https://downloads.openwrt.org/releases/23.05.2/targets/mpc85xx/p1020/openwrt-23.05.2-mpc85xx-p1020-extreme-networks_ws-ap3825i-squashfs-sysupgrade.bin; do
|
||||||
|
echo retrying;
|
||||||
|
done;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sleep 10
|
|
||||||
expect "root@OpenWrt:/#"
|
|
||||||
send "sysupgrade https://downloads.openwrt.org/releases/23.05.2/targets/mpc85xx/p1020/openwrt-23.05.2-mpc85xx-p1020-extreme-networks_ws-ap3825i-squashfs-sysupgrade.bin\n"
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user