2019-01-17 20:57:12 +11:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
INFILE="../../serial/foo.dat"
|
2019-02-09 14:06:09 +11:00
|
|
|
NBLINES=60000
|
2019-01-17 20:57:12 +11:00
|
|
|
TMPFILE="/tmp/dd2data.$$"
|
|
|
|
IMAGE="av4v-h.png"
|
|
|
|
|
|
|
|
tail -${NBLINES} ${INFILE} | ./av4v-h.awk > ${TMPFILE}
|
|
|
|
|
|
|
|
gnuplot << __EOC__
|
|
|
|
set term png size 1280,420
|
|
|
|
set output "${IMAGE}"
|
|
|
|
set grid
|
|
|
|
set title "Hourly average on the last ${NBLINES} samples"
|
|
|
|
set xlabel "Heures"
|
2019-01-28 01:25:40 +11:00
|
|
|
set ylabel "Temperature"
|
2019-02-09 14:06:09 +11:00
|
|
|
set yrange [ 0.0 : 30.0]
|
|
|
|
|
|
|
|
set xdata time
|
|
|
|
set timefmt "%s"
|
|
|
|
set format x "%d, %H:%M"
|
|
|
|
|
|
|
|
plot "${TMPFILE}" using 1:2 title "celcius" with lines
|
2019-01-17 20:57:12 +11:00
|
|
|
__EOC__
|
|
|
|
|
|
|
|
cat -n ${TMPFILE} | tail -20
|
|
|
|
|