bundles/infobeamer-monitor: more alerts
This commit is contained in:
parent
9be370f8df
commit
14c01e3bf0
1 changed files with 6 additions and 4 deletions
|
@ -98,9 +98,7 @@ while True:
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
mqtt_out(
|
mqtt_out(
|
||||||
'new device found with name "{}"!'.format(
|
'new device found!',
|
||||||
device["description"]
|
|
||||||
),
|
|
||||||
device=device,
|
device=device,
|
||||||
)
|
)
|
||||||
if device["is_online"]:
|
if device["is_online"]:
|
||||||
|
@ -123,6 +121,10 @@ while True:
|
||||||
if device["is_online"]:
|
if device["is_online"]:
|
||||||
must_dump_state = True
|
must_dump_state = True
|
||||||
|
|
||||||
|
if device["description"] != state[did]["description"]:
|
||||||
|
LOG.info("device {} changed name to {}".format(did, device["description"]))
|
||||||
|
must_dump_state = True
|
||||||
|
|
||||||
if device["is_online"]:
|
if device["is_online"]:
|
||||||
if device["maintenance"]:
|
if device["maintenance"]:
|
||||||
mqtt_out(
|
mqtt_out(
|
||||||
|
@ -137,7 +139,7 @@ while True:
|
||||||
if (
|
if (
|
||||||
device["is_synced"] != state[did]["is_synced"]
|
device["is_synced"] != state[did]["is_synced"]
|
||||||
or device["location"] != state[did]["location"]
|
or device["location"] != state[did]["location"]
|
||||||
or device["setup"]["name"] != state[did]["setup"]["name"]
|
or device["setup"]["id"] != state[did]["setup"]["id"]
|
||||||
or device["run"].get("resolution")
|
or device["run"].get("resolution")
|
||||||
!= state[did]["run"].get("resolution")
|
!= state[did]["run"].get("resolution")
|
||||||
):
|
):
|
||||||
|
|
Loading…
Reference in a new issue