Simple turn A/C off rule in newest rule machine?

VERY new to Hubitat and trying my hand at my first Rule Machine rule.

I can find references to what I’m trying to do but they all seem to show examples from an older version of Rule Machine and I can’t figure out how to duplicate it in the current version.

All I’m trying to do is a simple If/Then rule to turn my AC off when a door is left open for more than 3 minutes and then switch it back to auto mode when the door is closed.

I can get the IF part done easily even in the Simple Rules app. What I can’t figure out is how to get it to switch back to auto when the door is closes. That why I assume I need Rule Machine but I can’t for the life of me figure out how to do the IF/THEN/ELSE stuff that all the older examples are listing in these blue bubble boxes (part of old rule machine??).

Any help would be really great!

I do it with two rules as it makes it easier… until I figure out a simpler way. Here are my two…

1 Like

I do it with one rule with a slightly different approach. You'll find that there are almost always several ways to do anything, and which you choose is mostly preference.

This rule is triggered by a door or window left open for more than 5 minutes. It shuts the thermostat off. Then it waits for all of the windows and doors to be closed. And it turns the thermostat back on.

1 Like

You may also want to handle the situation where the thermostat is turned on while the door is already open.

2 Likes

Not likely to happen in my case. But I think I'd do that with a separate rule to make it simpler.

1 Like

This should do it. I think I'll add a "shut the door" message also.

1 Like

I would encourage caution with this type of automation, especially for a time-period as short as 3 minutes, for two reasons:

  1. It can potentially lead to short cycling, which is terrible for comfort, and
  2. The highest wear and tear on a compressor is during startup. That’s when it pulls a lot of amps and generates heat. Why encourage that wear and tear for a measly 3 minutes?

As an alternative, why not use use audio or visual notifications (with increasing “intensity”) encouraging occupants to shut the specified door or window?

Thanks @sburke781 - I think we’re thinking along the same lines.

4 Likes

Well for me the weather here is nice for multiple weeks of the year and I want to open the front and back doors and during that time it can get warmer or colder than what the thermostat is set to so I need to do something to keep the unit from coming on.

1 Like

Thanks for the replies/suggestions all!

My problem is not that I don’t understand the logic behind what I want to do. My issue is how the heck do you configure it inside of Rule Machine?

I see a lot of you have IF/THEN statement but how are you entering that in Rule Machine?

I don’t see anywhere that you can type it out long hand, which I suspect no one is doing but I also don’t see where you can choose IF’s or THEN’s etc if you take my meaning?

Conditionals

You could do something like this, but have it additionally turn off the AC when you silence the notification (meaning you're leaving the door open)

Essentially what this rule does is if either the front or back door are left open for more than 5 minutes it sends a notification that that particular door is open and to close it. (I had tts on here but switched to Homepod mini's and waiting for @bcopeland to work on that, he's busy on some other stuff right now though).

If the door is closed the rule resets and the notifications stop. If I want to leave the door(s) open I have a virtual button that I can turn on via my phone or a pico by the front door that will silence the notifications. Again, if at anytime the door(s) close the rule resets. You could modify this to add in turning off AC if you silence the notifications (meaning you're leaving the doors open)

You might start with something a bit simpler since you are new to all of this.

You can also use my app to group the contact sensors :grin:

3 Likes

You actually want wait for condition here. Currently if you opened two of them then waited and then closed just one of them it would turn the heating back on.

So where you have wait for event you also have wait for expression I think it's now called.

Hi @aaiyar and all,

I also run ac (heat pump) automation, but for different reasons. I share the concern about short-cycling esp. the compressor.

In my case I have two Ecobee thermostats, and new heat pumps with motor controllers (variable speed air handlers too).

So, instead of turning the thermostats on or off, I change the set points signicantly and allow the system to ramp up or down normally. The power traces look normal when run this way.

One caveat with this approach is that these are “Smart” thermostats. They use a schedule with “comfort” settings for each period. The t-stat will anticipate the next set point and try to reach that value in time for the start of the next period.

I work around this issue by setting the schedules to avoid such issues.

Maybe I’ll try on/off and see if the heat pump systems turn on and off gradually.

1 Like

I would recommend sticking to this. It is sensible, and safeguards your inverter heat-pumps.

1 Like

Nah...they have the "wait for event" set to "all contact closed"

1 Like

I was thinking I should do that... :wink:

1 Like

I have all contact closed so if only one closes but another is still open the heat won't come on.

That's a good idea!

1 Like