Author |
|
astro43 Newbie
Joined: September 18 2008
Online Status: Offline Posts: 4
|
Posted: September 19 2008 at 13:56 | IP Logged
|
|
|
I am experiencing very different behavior in version 2 vs 1.03.4.12. I have a trigger that fires on an Insteon Device Change then executes a script. In the prior version, this was working correctly. In version 2, the trigger is firing two, sometimes three times within a fraction of a second (possibly from PH acting on the devices's group broadcast and P2P cleanup messages - even though there is no device state change) but more seriously, often these triggers don't activate my script for minutes and sometime hours (although eventually my script does get executed for each trigger event. My computer has been "awake" at all times. Has anyone seen this problem or have suggestions?
__________________ Chris Murray
|
Back to Top |
|
|
mustangcoupe Super User
Joined: August 08 2003 Location: United States
Online Status: Offline Posts: 308
|
Posted: September 19 2008 at 15:47 | IP Logged
|
|
|
I am not having any trigger problems but lets try and break it down...
are you logging all insteon traffic? Can you see there why it might be triggering multiple times? is it getting stuck in the queue? or is nothing happening with the macro?
__________________ Todd Hannemann
HA newbie
PowerHome - UPB - ELK
|
Back to Top |
|
|
astro43 Newbie
Joined: September 18 2008
Online Status: Offline Posts: 4
|
Posted: September 19 2008 at 17:40 | IP Logged
|
|
|
Todd, Thanks for the quick reply. Here are some additional details. I have a good idea what is causing the duplicate triggers. I am not currently logging Insteon In in PH but I am closely following the messages displayed in the Smarthome Device Manager. My application is measuring the off time of a device so I capture time-of-day in a script when the device turns off and again when it turns on. When the device turns on (or off), it sends a group broadcast (message flag CF) and two cleanup messages to the two devices in the group (message flag 45) all three of which are received by the Device Manager. I believe that each of the three messages is firing the trigger in version 2.0 even though only the first message received actually represents a change of state. The trigger's action directly invokes my vbscript via ph.runscript_1. It appears that the first instance of the trigger is processed immediately (my script runs correctly) but the other two triggers are sometimes queued for an extended duration and sometimes not. No matter how long the delay in the queue of the duplicate triggers, my script eventually runs. I had been running the same script under version 1.03.4.12 for over a month with no occurrence of this behavior. Any thoughts?
__________________ Chris Murray
|
Back to Top |
|
|
dhoward Admin Group
Joined: June 29 2001 Location: United States
Online Status: Offline Posts: 4447
|
Posted: September 20 2008 at 00:14 | IP Logged
|
|
|
Chris,
This is the proper behaviour and should have been happening in version 1.03.4.12. If it wasnt, Im not sure why. The Device Change trigger is meant to fire for any Insteon communication that *could* cause a change in status or level so this would include the initial broadcast as well as the cleanups. It's possible that the cleanups werent being sent before or perhaps your plc/plm didnt have a full database and you were initially only firing on the broadcast.
Not to worry though...since this is a common request, the fix is simple. In the Boolean field, place the following formula:
[LOCAL9] <> [LOCAL10]
What this does is cause the trigger to *only* fire when an actual status change occurs. [LOCAL9] contains the original value and [LOCAL10] contains the new value (or vice versa...I'd need to look it up). The Boolean field must be true (or non-zero) in order for the trigger to fire. So when the first broadcast comes in, the [LOCAL9] and [LOCAL10] variables will be different and the trigger fires. The group cleanup comes in and the [LOCAL9] and [LOCAL10] will be the same so the trigger doesnt fire.
Hope this helps.
Dave.
|
Back to Top |
|
|
astro43 Newbie
Joined: September 18 2008
Online Status: Offline Posts: 4
|
Posted: September 20 2008 at 15:27 | IP Logged
|
|
|
Thanks for your help, Dave. You've cleared up the use of the Boolean field. I agree that the trigger should fire on all communications. I don't know why the trigger was not firing multiple times in the prior release. I was receiving the cleanup messages. But since your new release is out (and is excellent by the way), it's not important.
__________________ Chris Murray
|
Back to Top |
|
|