2019-01-17 19:35:48 +11:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
INFILE="../../serial/foo.dat"
|
2019-01-17 20:57:12 +11:00
|
|
|
NBLINES=1600
|
2019-01-17 19:35:48 +11:00
|
|
|
TMPFILE="/tmp/dd2data.$$"
|
2019-01-17 20:57:12 +11:00
|
|
|
IMAGE="av4v-m.png"
|
2019-01-17 19:35:48 +11:00
|
|
|
|
|
|
|
tail -${NBLINES} ${INFILE} | ./average4v.awk > ${TMPFILE}
|
|
|
|
|
|
|
|
gnuplot << __EOC__
|
2019-01-17 20:57:12 +11:00
|
|
|
set term png size 1280,420
|
2019-01-17 19:35:48 +11:00
|
|
|
set output "${IMAGE}"
|
|
|
|
set grid
|
2019-01-17 20:57:12 +11:00
|
|
|
set title "Average on the last ${NBLINES} samples"
|
|
|
|
set xlabel "Minutes"
|
|
|
|
set ylabel "Température"
|
2019-01-17 19:35:48 +11:00
|
|
|
set yrange [ 5.0 : 30.0]
|
|
|
|
plot "${TMPFILE}" with lines
|
|
|
|
__EOC__
|
|
|
|
|
2019-01-17 20:57:12 +11:00
|
|
|
tail -20 ${TMPFILE}
|
|
|
|
|