X-Git-Url: https://git.rvb.name/weathermon.git/blobdiff_plain/24b943a6e7b7490d7cb5b9fb02b5561a8b74c697..21260a74f42a65603317d1938fac675d5eef6635:/bin/weather-lcd?ds=sidebyside diff --git a/bin/weather-lcd b/bin/weather-lcd index 9ecadfa..9abd84f 100755 --- a/bin/weather-lcd +++ b/bin/weather-lcd @@ -251,14 +251,19 @@ setup_pages(conn) while true do - vals = process_file() - process_vals(vals) + pcall( function () - if log_con then - process_graphs() - end + vals = process_file() + process_vals(vals) + + if log_con then + process_graphs() + end - os.execute("inotifywait -e MODIFY \""..weather_file.."\"") - socket.sleep(3) + os.execute("inotifywait -e MODIFY \""..weather_file.."\"") + + end) + + socket.sleep(3) end