Rule machine - as per the app developer, this app is no longer available for new installs, distribution, or support

I would think, if I understand your question correctly, it would only make a difference if you had an AND mixed in.

condition = z AND condition = x OR condition = y
condition = z AND (condition = x OR condition = y)

Too add some more food for thought, in terms of ultimate flexibility for the actions there are some additional ideas. Your rule engine, or conditional evaluation part is incredibly flexible. Close to being able to take over for most apps. There are certain input limitations that prevent this, and the actions or outputs are not as flexible as some of the custom one off apps. Clearly, the condition evaluation part of rule machine is as deep as it can get - which I think was your big focus, and incredible contribution.

Say I make a rule to determine if the mode changes to home - if true then:
Front Door Lock UNLOCK
Light Living Room Turn switch ON
Light Driveway Turn switch ON
Light Front Door Turn switch ON
Wait 1800 seconds THEN Light Living Room Turn switch OFF
Wait 600 seconds THEN Light Front Door Turn switch OFF
Wait 600 seconds THEN Light Driveway Turn switch OFF
Wait 1200 seconds THEN Front Door Lock LOCK

So on this action I can set custom delays for each action I decide to take. Makes one rule be able to kick off a set of actions, close the loop and run them all down with different delays for each. Single rule does everything I need without virtual devices, etc

Just but one example.

Speaking of which, there are ways to do these things in other apps, rule builders and the such, the big advantage that I see to yours it I am not authing a 3rd party engine, this is all right in SmartThings. Not putting you on the spot or asking you to justify your app, I think it’s great. But the question is for all - what is the big advantage FOR YOU - your use cases, your preferences - of using this app over others?

For me, I’d love to get to the point where this collapses 98% of other apps,and keeps advanced condition evaluations and actions in a smarthings smartapp instead of going 3rd party.

I love this smart app, and really appreciate everything you put into it. I know you are getting a lot of requests for additional functionality. I don’t want this to turn into a full-time gig for you, but there is one thing that I would love to see added.

I would really like to see triggers worked in. For example, I would like to be able to say, when a switch is turned on…not just that it is on. In fact, I would like to do both.

Here is an example, I have some Z-wave switches wired with no-load and Hue bulbs in the fixtures. With Smart Lighting I can turn the lights on and off from the switch. However, if I use any other method to turn on the lights then the switch will not turn them off. The state of the switch is already OFF.

What I want it to do; WHEN the switch is Turned OFF…IF the bulb is ON…Turn the bulb OFF. The state of the switch would never change in this case.

This may already be possible in the current version of the Rule Machine and I just haven’t thought my way through it.

Also, would it be possible to use Routines as triggers? I know you can lunch a Routine as an action, but what about the other way around? Could you say, WHEN Good Morning is activated…do X? Now I’m just musing.

1 Like

I’m confused about what you’re asking for in this post… the scenario you suggest of turning lights on and then delayed off works, does it not for you?

Well, you’re right on base, not that this is bruce’s cross to bear, but the ‘inputs’ and ‘outputs’ here aren’t as flexible as would be required to take over the functionality of many apps I know I use.

The evaluation part is the incredibly flexible genius part.


I have specific delays for specific lights. Not all the same delay.

AND delays only currently work for a switch. Although my example was switch, the delay would be more flexible if it were merely an option you can add to any action.

You make a good point though, and I am going to modify my example to demonstrate locks. Varied delays to those actions as well.

What I want it to do; WHEN the switch is Turned OFF…IF the bulb is
ON…Turn the bulb OFF. The state of the switch would never change in
this case.

you would write a rule that has your switch and hue bulb as conditions, and set the switch condition as OFF and Hue Bulb ON, and your action would be to turn bulb OFF.

someone did suggest a universal delay/timer option, and I think that made it on the list of potential future updates. Though, if you really wanted to pull that kind of rule action for locks before any kind of universal timer in Rule Machine, you can add a virtual switch and tie it to the lock…

What happens there is; whenever I turn on the Hue bulb (not via the switch) it turns itself off immediately. The rule reads the two states as soon as one of them changes and activates.

Brutally honest question… why not set up your actions etc to turn the bulb on by the switch instead?

1 Like

Perfectly valid question. I do. However, I can not control color via the switch. So I have some automatons setup that can set colors and dim levels. Also, from time to time, I turn on the lamps and set the color directly form the ST app. I even use the Hue app occasionally.

At any rate, it was a simple example. I also want to make a toggle switch for my Garage door so that I don’t have to have an ON button and an OFF button. The wife doesn’t love that. Then there’s the fireplace control…

Not really and difference in terms of efficiency. However, read the paragraph in the original post about Rule Machine concerning how it evaluates the rule.

At this point there is no extension of Rule Machine into integrations (Harmony, Hue, Echo, etc.). It supports core ST capabilities.

This is well beyond the original intended scope of Rule Machine. Timers can be very tricky, and I maintain that they are best implemented in an app that has some context, which Rule Machine does not. I will look at enhanced timer functionality.

If effect, it already does this. The app subscribes to the events of a switch that is a condition. When the rule evaluates, obviously it looks at the state of the switch. Due to the subscription, when the switch is turned on or off, that triggers an evaluation, which discovers the state of the switch, and if the rule truth changed, caused the actions.


I found it easier not to mix functions with rules. What I mean by that, is I keep the “virtual toggle” functions separately from the Rule. You can set up " virtual groups" of switches in Smart Lighting that would tie your bulbs to the switch. Group A …when switch turns on/off, also turn bulbs on/off. This way your bulbs will always be in sync with your switch. One less condition to remember when setting up other rules…


Perhaps it was a poor example. But here is the issue; the switch is already off, but the bulb is on. If you press the OFF command (down) on the switch the state does not change. Since the state does not change it can not trigger an event. If I setup the rule to look for switch=off and bulb=on then anytime I turn on the bulb without turning on the switch it will turn itself off.

Here’s what I mean;

  • I keep my front porch light green & 50% dim. (
  • The switch is programmed to set the light to 100% white, so when the pizza guy comes to the door he can see.
  • If I turn off the switch when the light is on, AND i never turned on the swith, the light won’t turn off.
    Now, this is not that big of a deal because I can just turn on the switch then off again and it all resets. It drives my wife a little nutty but she copes. I would like to make it more seamless than that. We have a similar issue in my daughter’s room. Her Hue turns on pink to wake her in the morning on school days. Then the switch does not turn the light off unless she turns it on and off again.

I have many other things I would like to do in this manner. There are a number of rules I would like to set for my garage door, fireplace and lights in the TV room. All of which can be worked-around.

Anyway, it was just a suggestion. I really do appreciate the app as-is and all of the effort you have put into it. It’s still pretty bad-ass!

Thanks for the suggestion. I’ll give that a try. What I need to be able to do is have the bulb turn on with the switch AND have the switch turn on with the bulb without creating a loop.

1 Like

Ironically, I have the exact same problem in my Lutron integration. It gets synched when lights are turned off, but not when turned on, if the lights are turned on with a Lutron button. So I can’t turn them off from ST without first turning them on with ST, and then off, even when they are already on. Frustrating, no easy fix in sight.

1 Like

It probably won’t help with the other possible use cases you mention, but you can use Double Duty smart app to capture redundant off-presses of your already off switch to toggle your Hue bulbs off… UPDATED 10/7/2015 -- “Double Duty” - Use redundant switch presses to control other lights. You paid a lot for those switches, make them work Double Duty!


I’ll check it out. Thanks.

I have a small request…

Can you make it so when it sends an alert text that it can go to more than one phone number?

I know getting into timers can be like going down a rabbit hole, but think the cancel timer if False option would add real capability to this App, and expand it’s ability to replace other work arounds. So I really appreciate the consideration!!!