Jump to content
C4 Forums | Control4

Return to preset light level


clifcox

Recommended Posts

I am trying to have my theater/office lights flash when the doorbell rings. I've got the flashing part down, but am having difficulty getting the lights to return to their pre-flash level. I've posted my code below. Any hints would be greatly appreciated.

Link to comment
Share on other sites

  • 2 weeks later...

Thanks, Slemay.

So if I'm at 15%, toggle will take me to 0, and a 2nd toggle will return to 15%?

And just out of curiousity (in an attempt to gain more clarity), why doesn't setting a variable to the preexisting light level work?

Thanks

Link to comment
Share on other sites

Ahhh... I didn't take that into account - so no.

Toggle will just toggle the light on and off (to it's preset value). So if the preset value is 15% - then it would come back to that... but that's as setting in Composer HE that you set.

To come back to the preset level that you dimmed to... hmmm... I'm not positive you could do that... I would experiment with setting a variable to the current dimmer setting (if it's an option) - then you could do a flip of that afterwards.

I've never had that be a concern - as usually the lights that are "flashed" are not theater - but hallways, or kitchens etc... and those are almost always at their preset "ON" level (which we usually set to 84%).

Link to comment
Share on other sites

I am trying to have my theater/office lights flash when the doorbell rings. I've got the flashing part down, but am having difficulty getting the lights to return to their pre-flash level. I've posted my code below. Any hints would be greatly appreciated.

I'm not a dealer so my experience with loops is limited (they're not available in ComposerHE) but I would think that in your final IF statement, if you move the Change Variable to False statement to be AFTER you set the cans back to the variable preset level, then it might work.

The way I would interpret Loops to work, as soon as you change the variable back to FALSE, the loop statement ends and the loop actions would cease. I'm not sure whether it would continue to execute the code or (as appears to be happening now) it would just exit the loop.

Would you mind moving the "Change Variable to False" line to be AFTER the "Return cans to prior level" line and report back if it changes anything?

--Jason

Link to comment
Share on other sites

...

And just out of curiousity (in an attempt to gain more clarity), why doesn't setting a variable to the preexisting light level work?

Thanks

I have wondered this too. I can create a variable and assign it the preexisting value of a dimmers light level. I can then change the light level of said dimmer. However when I try to set the dimmers light level back the the previously saved level it fails.

Link to comment
Share on other sites

...

And just out of curiousity (in an attempt to gain more clarity)' date=' why doesn't setting a variable to the preexisting light level work?

Thanks[/quote']

I have wondered this too. I can create a variable and assign it the preexisting value of a dimmers light level. I can then change the light level of said dimmer. However when I try to set the dimmers light level back the the previously saved level it fails.

Sorry, I missed this part of the problem. It does work correctly for me. If I create a numeric variable and store the current light level in that variable, say 40, then do whatever I want with the light, then set the light equal to the level of the variable, it does so.

To program it, in the ACTIONS pane I go to the relevant light, then click the + sign to expand the underlying elements. I go to LIGHT LEVEL. I then select the last option in LIGHT LEVEL, which is SET TO THE VALUE OF. In the drop down list, which is huge, I scroll almost all the way down to the VARIABLES section and find the relevant variable. In my case, I have several variables named LL_x_yyyyy where LL indicates it's a variable to hold Light Levels, x is the floor and yyyyy is the name of the light. That way everything sorts nicely in the drop down list.

When I do this, and then execute the programming, the light goes to the prior level . . .

--Jason

Link to comment
Share on other sites

  • 4 weeks later...

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.