pool: tick

This commit is contained in:
Gilles Grandou 2022-06-19 16:03:52 +02:00
parent 33d79e48f2
commit 2b6652411a

22
pool.js
View File

@ -16,6 +16,10 @@ let status = {
duration: null, duration: null,
schedule: null, schedule: null,
time: null,
uptime: null,
tick: 0,
tick_mqtt: 0, tick_mqtt: 0,
tick_temp: 0, tick_temp: 0,
tick_lock: 0, tick_lock: 0,
@ -271,4 +275,22 @@ Shelly.addEventHandler(
} }
); );
// Debug...
Timer.set(
60 * 1000,
true,
function() {
status.tick++;
Shelly.call (
"Sys.GetStatus",
{},
function (result) {
print("[POOL] tick", result.time);
status.time = result.time;
status.uptime = result.uptime;
}
);
}
);