1
0
mirror of git://projects.qi-hardware.com/ben-wpan.git synced 2024-12-23 10:06:47 +02:00
ben-wpan/usrp/sps/row
Werner Almesberger 7258e10a9a usrp/sps: further improved scripts, added Makefile
- Makefile (index): generate an illustrated index of all the measurement
  runs
- Makefile (upload): upload images and index to downloads.qi-hardware.com
- collect: added optional directory argument, for cases where the
  destination directory differs from the local directory
- collect: hard-coded remote host to run usrp2_rx_cfile.py at
- collect: added . to PATH, for execution of a local copy of atrf-txrx
- row: generate entire HTML page, not just the table entries
- row: accept a list of prefixes to iterate through
- row: highlight rows starting a "new" prefix
- viz: corrected sprintf formats from +%...f to %+...f
- viz: show negative peak power in red
2011-03-04 20:28:59 -03:00

58 lines
1.1 KiB
Bash
Executable File

#!/bin/sh
export GDFONTPATH
GDFONTPATH=$GDFONTPATH:/usr/share/fonts/truetype/ttf-liberation/
if ! [ "$1" ]; then
echo "usage: $0 prefix ..." 1>&2
exit 1
fi
cat <<EOF
<HTML>
<TABLE cellpadding="0" cellspacing="0">
EOF
last=
for prefix in "$@"; do
echo $prefix 1>&2
if [ "${last%-*}" = "${prefix%-*}" ]; then
color=
else
color=' bgcolor="#a0e0ff"'
fi
last=$prefix
echo "<TR$color><TH>$prefix"
f=2405
while [ $f -le 2480 ]; do
echo "<TD align="center">$f MHz"
f=`expr $f + 5`
done
echo "<TR><TD align="right">-0.5 MHz"
f=2405
while [ $f -le 2480 ]; do
./viz -f LiberationSans-Bold -p $prefix-$f.png $prefix $f
convert -resize '15%' $prefix-$f.png $prefix-$f-small.png
echo "<TD><A href=\"$prefix-$f.png\"><IMG src=\"$prefix-$f-small.png\"></A>"
f=`expr $f + 5`
done
echo "<TR><TD align="right">+0.5 MHz"
f=2405
while [ $f -le 2480 ]; do
f1=`expr $f + 1`
./viz -f LiberationSans-Bold -p $prefix-$f1.png $prefix $f1
convert -resize '15%' $prefix-$f1.png $prefix-$f1-small.png
echo "<TD><A href=\"$prefix-$f1.png\"><IMG src=\"$prefix-$f1-small.png\"></A>"
f=`expr $f + 5`
done
done
cat <<EOF
</TABLE>
EOF