Author |
|
k2zs Senior Member
Joined: October 22 2009 Location: United States
Online Status: Offline Posts: 113
|
Posted: November 28 2009 at 00:07 | IP Logged
|
|
|
I just received an Insteon 2450 I/O Linc today and was wondering how I can trigger a macro from the input. I would also like keep the input status from changing the status of the device in the "Device Status" window.
__________________ Scott, K2ZS
Home Automation Ideas
|
Back to Top |
|
|
grif091 Super User
Joined: March 26 2008 Location: United States
Online Status: Offline Posts: 1357
|
Posted: November 28 2009 at 07:59 | IP Logged
|
|
|
The I/O Linc is like any Insteon controller. After linking the I/O Linc as a Controller to the Powerhome PLM as a responder, the Insteon Group In for Group 1 will fire a Trigger. The Trigger then invokes a Macro.
There is a Don't Display column under the Device definition but I think that stops the device from displaying altogether. Don't know how to display the device but not change its status.
Edited by grif091 - November 28 2009 at 08:00
__________________ Lee G
|
Back to Top |
|
|
BeachBum Super User
Joined: April 11 2007 Location: United States
Online Status: Offline Posts: 1880
|
Posted: November 28 2009 at 09:18 | IP Logged
|
|
|
k2zs wrote:
I would also like keep the input status from changing the status of the device in the "Device Status" window. |
|
|
Now I’m curious, why would you want to do that.
__________________ Pete - X10 Oldie
|
Back to Top |
|
|
k2zs Senior Member
Joined: October 22 2009 Location: United States
Online Status: Offline Posts: 113
|
Posted: November 28 2009 at 10:49 | IP Logged
|
|
|
BeachBum wrote:
k2zs wrote:
I would also like keep the input status from changing the status of the device in the "Device Status" window. |
|
|
Now I’m curious, why would you want to do that. |
|
|
Hi Pete,
You have to realize that I am totally new to insteon and I/O.
I have an Insteon 2450 I/O Link and figured I would have an output from my security system that reflects door status at the main entry trigger the input on the 2450 to fire a minimal lighting macro. Between the hours of sunset and lets sat 2:00am I would like the opening of the door to activate the foyer lights and bring the hallway lights up to 70%.
I have been able to link the the insteon switches as responders of the I/O Link but all they do is follow the input. When the door closes the lights go out again.
How do I create a trigger in PowerHome that converts this:
Decode: ACK of Group Cleanup. From: I_O_LINK To: K2ZS_PLM Group: 1, On
to run a macro?
BTW: My order arrived yesterday and I am now working with live devices here rather than experimenting on the live system I maintain via logmein.
__________________ Scott, K2ZS
Home Automation Ideas
|
Back to Top |
|
|
k2zs Senior Member
Joined: October 22 2009 Location: United States
Online Status: Offline Posts: 113
|
Posted: November 28 2009 at 11:02 | IP Logged
|
|
|
grif091 wrote:
The I/O Linc is like any Insteon controller. After linking the I/O Linc as a Controller to the Powerhome PLM as a responder, the Insteon Group In for Group 1 will fire a Trigger. The Trigger then invokes a Macro.
There is a Don't Display column under the Device definition but I think that stops the device from displaying altogether. Don't know how to display the device but not change its status. |
|
|
Hi Lee,
I did try that but it didn't work. I am totally new to PowerHome2 and indepth programming. I have never created any triggers.
__________________ Scott, K2ZS
Home Automation Ideas
|
Back to Top |
|
|
BeachBum Super User
Joined: April 11 2007 Location: United States
Online Status: Offline Posts: 1880
|
Posted: November 28 2009 at 11:11 | IP Logged
|
|
|
I would trigger it with Insteon Group In. The fact the event even occurred is what you want. If you trigger on ACK then you may be seeing a delay if there is recovery going on. For the time frame you would stick something like this in the Boolean field.
IF ( NOW() > RELATIVETIME( 00:00:00, [SUNSET] ) AND NOW() < 02:00:00 , 1, 0)
On the trying what Lee suggested snapshot the trigger and the links from the Insteon Explore screen.
__________________ Pete - X10 Oldie
|
Back to Top |
|
|
grif091 Super User
Joined: March 26 2008 Location: United States
Online Status: Offline Posts: 1357
|
Posted: November 28 2009 at 11:33 | IP Logged
|
|
|
The PLM is like any other device so it must be linked as a Responder to the Controller (I/O Linc in this case) for it to get Insteon messages from the I/O Linc. Most likely the link is not active. Check the event log, you are looking for a Group Broadcast followed by a Group Cleanup from the I/O Linc to the PLM. If the messages are in the event log then the link is working and the trigger is in question. If the messages are not in the event log the link is the place to look. Also be sure to unlink the switches from the I/O Linc Input otherwise the Input Off will turn the devices Off with messages directly from the I/O Linc to the switches.
I'm doing some yard work this afternoon. Pete is very knowledgeable on the subject of triggers and macros so if you post what he asked for he can get things working.
__________________ Lee G
|
Back to Top |
|
|
k2zs Senior Member
Joined: October 22 2009 Location: United States
Online Status: Offline Posts: 113
|
Posted: November 28 2009 at 11:38 | IP Logged
|
|
|
BeachBum wrote:
I would trigger it with Insteon Group In. The fact the event even occurred is what you want. If you trigger on ACK then you may be seeing a delay if there is recovery going on. For the time frame you would stick something like this in the Boolean field.
IF ( NOW() > RELATIVETIME( 00:00:00, [SUNSET] ) AND NOW() < 02:00:00 , 1, 0)
On the trying what Lee suggested snapshot the trigger and the links from the Insteon Explore screen.
|
|
|
Thanks Pete, That did the trick. It's working fine now. So actually I could create a "Home" and "Awat" button in control center that activates or de-activates the I/O link relay to bypass the input so subsiquent door status changes don't fire the macro.
__________________ Scott, K2ZS
Home Automation Ideas
|
Back to Top |
|
|
BeachBum Super User
Joined: April 11 2007 Location: United States
Online Status: Offline Posts: 1880
|
Posted: November 28 2009 at 11:42 | IP Logged
|
|
|
Lee… Oh the never ending task of getting rid of the leaves in the fall. Palm fronds don’t shed and the cocoanuts you can eat.
Edited by BeachBum - November 28 2009 at 11:43
__________________ Pete - X10 Oldie
|
Back to Top |
|
|
k2zs Senior Member
Joined: October 22 2009 Location: United States
Online Status: Offline Posts: 113
|
Posted: November 29 2009 at 20:44 | IP Logged
|
|
|
So I tried an experiment with global variables and am having a problem with the formula. To keep the trigger from firing every time the door gets opened once I am already home I created the global variable "Home". I included a line in the "Hello" macro that sets the global "Home" to 1. I see it get set when the macro runs and have verified it in powerhome explorer. I changed the trigger formula to this:
IF ( NOW() > RELATIVETIME( 00:00:00, [SUNSET] ) AND {HOME} = 0, 1, 0)
For some reason the trigger still fires the macro. Am I calling it wrong? I know other languages sometimes use different switches.
__________________ Scott, K2ZS
Home Automation Ideas
|
Back to Top |
|
|
k2zs Senior Member
Joined: October 22 2009 Location: United States
Online Status: Offline Posts: 113
|
Posted: November 29 2009 at 20:47 | IP Logged
|
|
|
ahha! <> did the trick
__________________ Scott, K2ZS
Home Automation Ideas
|
Back to Top |
|
|
grif091 Super User
Joined: March 26 2008 Location: United States
Online Status: Offline Posts: 1357
|
Posted: November 29 2009 at 21:01 | IP Logged
|
|
|
You can double click on the Boolean field which will take you to the Formula Builder. Clicking on Verify will run the formula and show the result. Easy way to test formula variations. If there is a problem the result will show "!". It will also show the result of a successful execution so you can tell from the 1 or 0 whether the if resulted in true or false. This also works on formulas in macros as well.
__________________ Lee G
|
Back to Top |
|
|
k2zs Senior Member
Joined: October 22 2009 Location: United States
Online Status: Offline Posts: 113
|
Posted: November 29 2009 at 21:52 | IP Logged
|
|
|
Thanks Lee,
I discovered that earlier. Thats how I found that <> worked as opposed to =. This is a new language for me so I will have to get used to it. PHP uses == in it's equal tests but that didn't work so I used <> and it worked. Actually it worked better because it evaluated with a NULL value as well.
__________________ Scott, K2ZS
Home Automation Ideas
|
Back to Top |
|
|
k2zs Senior Member
Joined: October 22 2009 Location: United States
Online Status: Offline Posts: 113
|
Posted: November 30 2009 at 19:38 | IP Logged
|
|
|
OK....
All the best laid plans and stuff....
I arrive home today expecting the welcome routine to fire and nothing. I had altered my idea and added a second trigger based on the same I/O input that was supposed to fire a different macro between the hours of midnight and sunrise. When I looked at the event log to see why I found the first trigger never fired and it was the after midnight trigger that fired and of coarse no macro was triggered.
In my experiments I found that there can only be up to 2 conditions in an IF statement. I tried nesting IF statements and it worked. Since the global HOME is the primary test I nested my time checks in the "True" portion of the global test. It looks like this:
IF ( {HOME} <> 1, IF ( NOW() > RELATIVETIME( 00:00:00, [SUNSET] ) OR NOW() < RELATIVETIME( 00:00:00, [SUNRISE] ) , 1, 0), 0 )
Is that acceptable practice or is ther another way I should do that? It worked... just curious.
__________________ Scott, K2ZS
Home Automation Ideas
|
Back to Top |
|
|
BeachBum Super User
Joined: April 11 2007 Location: United States
Online Status: Offline Posts: 1880
|
Posted: November 30 2009 at 19:47 | IP Logged
|
|
|
Try this:
IF ( {HOME} <> 1 AND NOW() > RELATIVETIME( 00:00:00, [SUNSET] ) OR NOW() < RELATIVETIME( 00:00:00, [SUNRISE] ) , 1, 0)
__________________ Pete - X10 Oldie
|
Back to Top |
|
|
k2zs Senior Member
Joined: October 22 2009 Location: United States
Online Status: Offline Posts: 113
|
Posted: December 01 2009 at 00:34 | IP Logged
|
|
|
Hmmmm.... I had tried that before but it didn't work, now it does
__________________ Scott, K2ZS
Home Automation Ideas
|
Back to Top |
|
|