diff options
author | Keith Packard <keithp@keithp.com> | 2018-10-08 19:40:32 -0700 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2018-10-08 19:40:32 -0700 |
commit | 6e785eea7b7a14ec8c1e69cad2c88836a9b1943e (patch) | |
tree | 4d8d6e027f3ef6417d2379372fc43a994790f585 | |
parent | 88ae4c5ebd64215f05f5efc18f9660560b409ace (diff) |
ao-bringup: Use new ao-cal-freq options when flashing teledongle v3.0
Use --nosave and --output to get the value needed to reflash the device.
Signed-off-by: Keith Packard <keithp@keithp.com>
-rwxr-xr-x | ao-bringup/turnon_teledongle | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/ao-bringup/turnon_teledongle b/ao-bringup/turnon_teledongle index 0cdbde7a..983f1010 100755 --- a/ao-bringup/turnon_teledongle +++ b/ao-bringup/turnon_teledongle @@ -71,7 +71,9 @@ esac echo 'E 0' > $dev -SERIAL=$SERIAL ./cal-freq $dev +CALFILE=cal-$SERIAL.txt + +../ao-tools/ao-cal-freq/ao-cal-freq --verbose --nosave --output=$CALFILE --tty=$dev case $? in 0) @@ -82,7 +84,7 @@ case $? in ;; esac -CAL_VALUE=`grep "^$SERIAL," cal_values | tail -1 | sed 's/^[^,]*,//'` +CAL_VALUE=`cat $CALFILE` case "$CAL_VALUE" in [1-9]*) @@ -93,6 +95,8 @@ case "$CAL_VALUE" in ;; esac +echo $SERIAL","$CAL_VALUE >> cal_values + echo "Reflashing with calibration: $CAL_VALUE" $USBLOAD --cal=$CAL_VALUE --tty=$dev $ALTOS || exit 1 |