Author |
|
bhlonewolf Senior Member
Joined: March 29 2007
Online Status: Offline Posts: 198
|
Posted: April 22 2007 at 20:23 | IP Logged
|
|
|
Hi all,
Looking for a little help here.
I have a basic setup where some outdoor lights will come on at 50% brightness at sunset, and stay on until about 11. This is currently done with a PLC-defined group (Insteon). What I'd like to do is bypass the shut off if the user manually turned on the lights (presumably to full brightness).
So, what I'm thinking is easiest is a simple check on the level when it goes to shut off. If the level is 50% (or whatever the on-level was), shut off, otherwise, ignore the shut off command.
There's probably other ways to do this too, but this approach lets me easily "resume" the program if I want to just be turning the group back on.
Any pointers for this? I understand the logic steps involved, but still getting used to PH and building macros.
|
Back to Top |
|
|
TonyNo Moderator Group
Joined: December 05 2001 Location: United States
Online Status: Offline Posts: 2889
|
Posted: April 23 2007 at 07:23 | IP Logged
|
|
|
Use this for the Off section...
Code:
JUMP if( ph_getinsteonlevel( [ID] ) = [level], 1, 2)
[off]
[next line] |
|
|
|
Back to Top |
|
|
bhlonewolf Senior Member
Joined: March 29 2007
Online Status: Offline Posts: 198
|
Posted: April 23 2007 at 08:32 | IP Logged
|
|
|
Thanks Tony...
One additional thing I've thought of -- and not really a big deal -- is that I need to manually do all the devices.
In my case, I have a few devices as part of a scene ... so when the scene gets turned on, it's easy enough to tell the group to turn on ... but when turning off, I'd need to query each device in the group ...
|
Back to Top |
|
|
TonyNo Moderator Group
Joined: December 05 2001 Location: United States
Online Status: Offline Posts: 2889
|
Posted: April 23 2007 at 13:58 | IP Logged
|
|
|
Yup. Sounds like you would just need those lines above for each device in the group.
It does look like you can query the status of a group, though, based on the web status screen I'm looking at. I just turned a group on, and the status does show that the group is on.
|
Back to Top |
|
|
bhlonewolf Senior Member
Joined: March 29 2007
Online Status: Offline Posts: 198
|
Posted: April 23 2007 at 16:03 | IP Logged
|
|
|
True -- but if a user intervenes and turns one of the lights on full (for example), or even off, the group would still show on (I think).
The exact scenario is this: one of the lights as part of my outdoor lights is an outdoor garage light. In the evening, I keep it dimmed to about 40%. It's enough to see by and saves energy. If I were expecting company, I'd turn it on full. In these cases I'd want the light to stay on until I turn it off, instead of going out around 11pm.
So I think this works :) Thx for the tips!
|
Back to Top |
|
|
cmhardwick Senior Member
Joined: July 08 2006 Location: United States
Online Status: Offline Posts: 290
|
Posted: April 23 2007 at 16:44 | IP Logged
|
|
|
Yes, if you do change the status manual of any light in a group, the group status does not change. In my case, I have a "sunset" group that goes on, of course, at sunset. I have an all off that happens about 12:30am, but the "group" still shows on even though the lights are off. I've added another timed event shortly after the all lights off to handle this little cleanup.
__________________ Cicero, Enjoying automation!
|
Back to Top |
|
|
bhlonewolf Senior Member
Joined: March 29 2007
Online Status: Offline Posts: 198
|
Posted: April 23 2007 at 22:46 | IP Logged
|
|
|
cmhardwick-- out of curiosity and probably a silly question: when you perform this little cleanup afterwards, is this a manual thing, or is there a way to tell devices to sync their status?
I suppose I'm answering my own question here, because the definition of "status" is arbitrary unless a single switch is controlling a single load.
|
Back to Top |
|
|
cmhardwick Senior Member
Joined: July 08 2006 Location: United States
Online Status: Offline Posts: 290
|
Posted: April 24 2007 at 09:49 | IP Logged
|
|
|
my timed event is just to send an off command to the "sunset" group. At that point, I'm not concerned with status of the lights as the "all lights off" has already run. If I'm still up reading, I just turn my bedside lights back on.
You could get fancy with some formulas in macros and triggers to keep it all in sync via the insteon change trigger, but for my purposes, it's not necessary. I just want the "sunset" group to not show as ON when the lights are off, so I turn it off.
Edited by cmhardwick - April 24 2007 at 09:51
__________________ Cicero, Enjoying automation!
|
Back to Top |
|
|