I have been looking around the forums for a solution to trigger an event based on the 'last change' field, as opposed to a timer that is triggered by the 'value' or 'string' fields.
Let me explain. It seems that the EasyTrigger "This device's value has NOT changed for exactly" trigger uses an internal timer in the plugin based on the value field.
So if the device is updated with the exact same value logically it has not changed and the trigger condition remains true. But in actual fact the device has been updated.
There are a few posts on people wanting to know if a device is not being updated or dead, irrespective of the value. Basically they want to use it as a heartbeat? The solutions all require writing scripts and conditions based on hs.devicelastchangeref(deviceRef). Although some of them work they are not as elegant as using a plugin trigger.
Of course the "Do not update device last change time if device value does not change" property needs to be unchecked.
What would be great is if easy trigger had a trigger based on 'last change'. Something like "if LAST CHANGE timestamp has NOT changed for XX". It would solve a few problems for a number of people.
Thanks, Marty.
Let me explain. It seems that the EasyTrigger "This device's value has NOT changed for exactly" trigger uses an internal timer in the plugin based on the value field.
So if the device is updated with the exact same value logically it has not changed and the trigger condition remains true. But in actual fact the device has been updated.
There are a few posts on people wanting to know if a device is not being updated or dead, irrespective of the value. Basically they want to use it as a heartbeat? The solutions all require writing scripts and conditions based on hs.devicelastchangeref(deviceRef). Although some of them work they are not as elegant as using a plugin trigger.
Of course the "Do not update device last change time if device value does not change" property needs to be unchecked.
What would be great is if easy trigger had a trigger based on 'last change'. Something like "if LAST CHANGE timestamp has NOT changed for XX". It would solve a few problems for a number of people.
Thanks, Marty.
Comment