Changing Thermostat based on Time, Occupancy, etc

I started writing a bunch of Rule Machine rules to accomplish a goal, but things got more and more complicated with nuance of "well, oops, if that happens, then this instead"

Initially I was going to create a "Sitting Room Heater Mode" variable -- and make it OFF, HOLD, PREHEAT, OCCUPIED, IDLE etc -- and then set up rules based on the different modes, and rules to activate different modes. Rules would then turn on/off/change setpoints on a thermostat. Realized I'd have like a dozen rules.

I stopped. Figured I was going down a rabbit hole that was the wrong way to pull it off -- and smarter minds would have a better, more eloquent solution.

USE CASE: My wife's "sitting room" is rather cold. But I don't want to heat it 24x7. She uses it in the morning to have her coffee, and then at random times on some days (like to crochet, chat with a girlfriend, etc). And once in awhile, we have a guest sleeping over. Want the automation to be "very soft" (the less involvement, the more WAF).

  1. PREHEAT Mode: In the mornings, if the global Away mode is off -- then pre-heat it at 5:15am through 6:30am, or until occupancy detected (eg, warm up the sitting room before my wife wakes up -- so it's warm and cozy for her coffee time)
  2. OCCUPANCY Mode: Outside of that time - when occupancy detected - raise the heat setpoint (I have sensors to detect occupancy)
  3. IDLE Mode: No matter what, don't let it go below xx - (Except if OFF)
  4. OFF Mode: Allow for a "off" mode to be set - full off. Until turned back on (useful for several circumstances)
  5. HOLD Mode: Allow for holding at a current set temperature, until resuming automation (useful for sleeping, etc -- when occupancy may not be detected or a non-standard heating setpoint is desired)

"Thermostat Schedule" doesn't quite do what I'm needing. I could create the different "schedules" -- but in this use-case, my needs aren't time-oriented (except pre-heat) -- and I don't see how in RM5 to switch between the different schedules on demand. I can CHANGE the schedules, but not SWITCH BETWEEN schedules

And, bonus points, adjust the target setpoints (for each mode) based on outside temperature -- like, if it's 30 outside -- then the room probably only needs to be 65 degrees. But if it's -5 outside, then it might need to be 70 as it "really feels cold" dependent on how frigid it is outside. (and the IDLE setting, the minimum to keep the room might need to be a few degrees higher)

As an aside -- in the "sitting room" -- there's an electric radiant oil heater, on a plug, and a temperature sensor -- the "vThermostat by nclark" takes care of making that act/look like a regular thermostat that can be controlled by her Alexa in the room

I would break it up into individual rules... Easier to manage than just trying an all in one rule.

Like @rlithgow1 recommends, I also think separate rules are the way to go.

Sounds like 3 and 4 are going to have an issue with each other… If set to off, will it really not let it go below XX? I will assume that OFF mode means that the schedules will not operate, but it will still keep a minimum temp.

To handle 3, I would set the set point to that temperature for all other rules when it is turned off.

Rule for 1 is pretty simple, required expression is that the ā€œOFF Modeā€ is disabled; trigger is the time.
Rule 2 is same as Rule 1 (clone would make it easy to create) with the only difference that the trigger is occupancy. Rule 1 and 2 could likely be combined into the same with the trigger being either time or motion.
Rule 5 would trigger ā€œOFF Modeā€ and set the temperature to whatever you are looking for based on a switch trigger.

@rlithgow1 -- concur -- I hate massive rules. Too hard to troubleshoot.

@Sebastien Yea - I meant to say -- I wanted a hard-OFF -- but if we're not in hard-OFF -- then keep a minimum temperature (fixed my post). Example: Wife is away for a week, no point in running any schedule, or pre-heating. Home isn't in AWAY since I'm home.


So, the general consensus is -- nothing magical from the "app world" to help here -- I'll just have to craft the rules I need.

No biggie -- just wanted to make sure I wasn't missing something "to make my life a lot easier"

Thanks folks!

2 Likes

Just a final here. Ended up creating a set of rules. A few "modes" took more than one to handle some unique contingencies. If anyone is interested in further, I can give more details

Also, for creativity -- I used "Alexa, set the guest room to cool" ("guest room" is the name of the thermostat) -- as a trigger to go back/forth on a "hold mode" (reverts back to heat, but locks-down the temperature until reset)

I'll get creative on a custom "Alexa" routine in their app, once my wife decides on how she wants to "ask Alexa to do it"

1 Like

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.