サーバのOS更新で最後に残っていた室温のログ取りとグラフ表示を更新完了。当時の流行りのnode.jsを使用していたのを止めて、gnuplotでグラフ生成を行うように小改修しました。
https://riverotter.xsrv.jp/temperature/1day.jpg
ついでに室温/外気温を別のグラフにしていたのを止めて、一つのグラフにまとめました。
reset set terminal jpeg size 1200,480 font "Noto Sans Mono,Regular,12" set output "1day.jpg" set title "24 hours monitering" set xlabel "Date time" set ylabel "Temperature [°C]" set key top left set grid set xdata time set timefmt "%Y-%m-%d %H:%M:%S" set format x "%H:%M" plot \ "log_temp.csv" using 1:3 with linespoint linewidth 2 linecolor rgb "red" title "Inside", \ "log_temp.csv" using 1:4 with linespoint linewidth 2 linecolor rgb "blue" title "Outside"
gnuplotのスクリプトはこんな感じ。debain 11 では 2行目のfontを指定しないと文字化けしました。Ubuntu 23.04では問題なかったけど。