Posting from my phone, so apologies for poor formatting.
I have the following rule set up. However it almost never seems to run on its own. I know the rule works because I have a trigger set up that evaluates the rule when a routine runs. Whenever I run the routine and it kicks off the evaluation, then it works instantly. I think it running on its own has only worked a handful of times.
Point of the rule is I have two time slots everyday when I would like to turn those house lights on. This accomplishes that.
Iāve always found the rule truth option to be really unreliable. Iāve never been able to get it to work consistently.
This is how I have most of my lighting rules set up and they are rock solid.
I recommend the following changes:
Front house lights rule -
remove the rule truth completely from conditions and define rule
now add this, just like thisā¦
Conditions - private Boolean: this rule: false
Rule - private Boolean: this rule: false
for both of the other rules, do this -
Actions for true - set private Boolean: front house lights rule: false
Actions for false - set private Boolean: front house lights rule: true
On the second two rules, in the private Boolean sections for actions for true and actions for false, make them both look like this picture ( but choose your rule āfront house lightsā.
Interestingā¦ so if I have a flaky running rule and want to correct it I am wondering if I go back and just do edits that would be enough but maybe I need to delete them and start over? I have a couple rules that I keep blaming the ST platform issues for not executing.
Wellā¦I figured I would wait a week or so before I came back on here with a response, Iām not seeing much of a difference.
I have not changed my rule set up, and they still seem to be fairly unreliable. Itās 1PM right now, and I just had to turn off my porch, balcony, driveway lights from work, when they were supposed to turn off at sunrise this morning. And last night I had to turn my lights off manually as well, when they were supposed to turn off at 10:00PM
Iām going to add text message alerts to all of the timed rules to make sure I know when they are properly running. That way itās not in my head, I will actually have a log. (I know I can check the built in logs, but I like using texts as a way of separating and filtering).
I have a time based rule to switch on socket between 8pm and 11pm. Been running reasonably reliably for weeks yet tonight didnt fire until I went into RM rule and refreshed.
Where in IDE can I check logs? Is it under the events section of the device? Nothing showed at 8pm but only at 8:46pm when I refreshed rule or is there anywhere else to look?
Under the scheduled jobs of the rule it shows next scheduled stop and start runtime but nothing under previous run time and status states āpendingā.
In the app (I know you said IDE), you can look in the āRecentlyā tab for any device and you will see the rule name being executed, and then all the events to that device.
In the IDE, go to Locations > āList SmartAppsā > Click on the name of the rule youāre looking at, and WAIT for the larger pop-up, at the bottom is a job history.
There may be a better way, that was my first search to find it in the IDE just now.
Well, thatās the thingā¦Is it ST? Rule Machine? Our devices? Our device handlers? who knows.
Iām using ST outlets, a GE in-wall smart light switch, and 3 OSRAM lightify smart bulbs, all on the same rule. So it canāt be the device or the handlers, because none of them are working. So it must be ST or Rule Machine. But all of my other rules that donāt rely on time of day work fine. So maybe itās a problem with Rule Machine specifically with time of day rules.
I just changed the rule to be based on Private booleans instead, as @bamarayne had suggested. Weāll see if that helps.
bamarayne
(Jason "The Enabler" as deemed so by @Smart)
17
I set my lights up like this and they are extremely reliable. You can give it a shot if you want.
Rule one - lights on/off
Condition - private boolean: true
Rule - private boolean: true
Actions for true - turn on lights
Actions for false - turn off lights
Rule two - morning lights
Conditions - between two times: 5am - sunrise
Rule - between two times: 5am - sunrise
Actions for true - set private boolean: rule one: true
Actions for false - set private boolean: rule one:false
Rule three - evening lights
Conditions - between two times: Sunset +30 and 10pm
Rule - between two times: sunset +30 and 10pm
Actions for true - set private boolean: rule one: true
Actions for false - set private boolean: rule one:false
I have all of my lighting set up like this and it is very reliable. Itās also very easy to set up an override or to add new times, conditions, whatever.
Thatās exactly what I just did. So weāll see how they do tonight.
What drives me crazy, is when I first set all of these rules up, they worked perfectly for a couple weeks.
bamarayne
(Jason "The Enabler" as deemed so by @Smart)
19
Also, with it set up like this, itās easy to tell where it failed. If the pb isnāt right you know it was that part. If the pb is right, and the rule says true, and the light is off, then is either the device, message not sent, or timed out.
Well the weird part with the Rule truth method. I would sit there wondering why the lights arenāt on yet. I would go into the sub-rules, and see one was marked as True, I would go into the main-rule, and show it was true, yet the lights were not on.
So thatās when I set up a trigger that I could manually run which would update and evaluate all of my rules, and then the lights would turn on.