JGLI Posted March 10, 2017 Share Posted March 10, 2017 Once again, thanks for the help you folks have provided. My shabbos code sort of worked last week but I want to make sure its right. Here is the main macro for lights going off; the idea is that there are three groups followed by the alarm being set at the end. Does this look correct? I wish there was an easier way of creating a delay. Lightsoff.tiff Link to comment Share on other sites More sharing options...
Cyknight Posted March 10, 2017 Share Posted March 10, 2017 There is, it's called adding a delay (under programming control) - but it's not always recommended to use that for very long delays (ie more than a couple of seconds, MAYBE a few minutes). That said - don;t thing your macro is correct? Basically you start a timer every time, then check to se if that timer is NOT running - but it always will be. Oh and one line isn't embedded like it should be. I believe you're overthinking it here - but I can only guess because I you don't state what you actually want to do - meaning what is the overall desired effect that you are looking for. But it appears like you're doing this backwards...please explain what you want clearer. Link to comment Share on other sites More sharing options...
JGLI Posted March 10, 2017 Author Share Posted March 10, 2017 I'm trying to accomplish a simple task. When that Macro is called (from another macro), start turning off the lights at three separate times, and at the end turn on the alarm. Turn off first group wait 15 minutes turn off second group wait 10 minutes turn off third group wait 60 minutes activate alarm Seems like there has to be an easy way to do this.... Link to comment Share on other sites More sharing options...
msgreenf Posted March 10, 2017 Share Posted March 10, 2017 I would approach this a little differently. 1)Macro 1 = "first group off" 2)Timer - "Group 2 delay" 15 minutes 1) First group off code: -Execute scene or lights off -Start timer "group 2 delay" on timer programming when timer 2 expires: Execute macro 2 "2nd group off" -execute scene or lights off -start group 2 delay timer and so on... Link to comment Share on other sites More sharing options...
JGLI Posted March 10, 2017 Author Share Posted March 10, 2017 msgreenf, will my code work? I'd like to keep it all in one spot so it's easier to add/remove stuff in the future rather than having to go to each timer... if not I'll break it into those pieces. Link to comment Share on other sites More sharing options...
msgreenf Posted March 10, 2017 Share Posted March 10, 2017 not really....what you wrote in your code is not the same as what you wrote in words Link to comment Share on other sites More sharing options...
msgreenf Posted March 10, 2017 Share Posted March 10, 2017 macros execute right way....so you if timer is not running test runs right after you start the timer, so it will never work Link to comment Share on other sites More sharing options...
d1amund Posted March 10, 2017 Share Posted March 10, 2017 JGLI all those really long delays are poor programming; use Timers. Link to comment Share on other sites More sharing options...
JGLI Posted March 10, 2017 Author Share Posted March 10, 2017 Confused - if 4 minutes ago, d1amund said: JGLI all those really long delays are poor programming; use Timers. I'll break the code into pieces. Thanks. Link to comment Share on other sites More sharing options...
msgreenf Posted March 10, 2017 Share Posted March 10, 2017 Confused - if I'll break the code into pieces. Thanks. Use my example above as a template Sent from my STV100-1 using Tapatalk Link to comment Share on other sites More sharing options...
JGLI Posted March 10, 2017 Author Share Posted March 10, 2017 That's what I did, now to fix the lightswitch LEDs (i started another thread). Link to comment Share on other sites More sharing options...
JGLI Posted March 12, 2017 Author Share Posted March 12, 2017 Everyone, The revised code worked well, but my activate Shabbat code had problems. Are there issues with Macros calling Macros and there not being enough time to complete them? My activate Macro calls another macro for thermostats, sends a command to HAI and activates a lighting scene. Not all the lights came on as they should and the HAI macro didn't run. Should I add a 1 or 2 second delay between them? Link to comment Share on other sites More sharing options...
msgreenf Posted March 12, 2017 Share Posted March 12, 2017 Shouldn't need to but it may not hurt Sent from my Nexus 6P using Tapatalk Link to comment Share on other sites More sharing options...
eddy.trochez Posted March 12, 2017 Share Posted March 12, 2017 Your Shabbat lights off routine didn't require a macro. In fact, I don't even know how you can accomplish what you want with a macro. Link to comment Share on other sites More sharing options...
JGLI Posted March 12, 2017 Author Share Posted March 12, 2017 2 minutes ago, eddy.trochez said: Your Shabbat lights off routine didn't require a macro. In fact, I don't even know how you can accomplish what you want with a macro. How would you do it without a macro? FWIW, it worked. Link to comment Share on other sites More sharing options...
VINCELdUB Posted March 13, 2017 Share Posted March 13, 2017 An advanced lighting scene with delays would do this nicely. Could call a lighting scene after another has been activated or a timer as well. HAI lighting, what driver do you have ? Happy Automating! Link to comment Share on other sites More sharing options...
VINCELdUB Posted March 13, 2017 Share Posted March 13, 2017 Light scene with all lights in it. Then for first group zero delay, second group at 15, third at 25 minutes and alarm at 85 minutes Happy Automating! Link to comment Share on other sites More sharing options...
VINCELdUB Posted March 13, 2017 Share Posted March 13, 2017 One advanced lighting scene. DONE Happy Automating! Link to comment Share on other sites More sharing options...
JGLI Posted March 13, 2017 Author Share Posted March 13, 2017 Thanks, will look into advanced lighting with delays, didn't know it was possible. Link to comment Share on other sites More sharing options...
SMHarman Posted March 13, 2017 Share Posted March 13, 2017 Light scene with all lights in it. Then for first group zero delay, second group at 15, third at 25 minutes and alarm at 85 minutes Happy Automating! How long can am advanced lighting scene run? And how many levels? Thinking about this for rgb leds Link to comment Share on other sites More sharing options...
VINCELdUB Posted March 13, 2017 Share Posted March 13, 2017 As many delays for as long as you like. I have never run into a roadblock on amount of actions and delays. And fade times as well. Three lights in scene for example. 1 on 1 delay 2 minutes then fade off over 30 seconds 2 on 2 delay 2 minutes then fade off over 30 seconds 3 delay 45 seconds then on 3 delay 15 minutes then off over 30 seconds This is something I do a lot for pathway lighting with a room at the end. Like a welcome home midroom and hallway and kitchen. Kitchen stays on for 15 minutes hall and mudroom 2 minutes and 30 seconds. Happy Automating! Link to comment Share on other sites More sharing options...
VINCELdUB Posted March 13, 2017 Share Posted March 13, 2017 I have gotten much more complicated as well with as many as 6 actions per Light. Right click and add action is all that is needed. Happy Automating! Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.