Universal Override Timer

I would like to see a feature of a universal override timer. This feature would allow you to temporarily override the state of a device and have it return to its natural state after a pre-defined time without the need for a separate trigger such as occupancy state, motion or day/night. This could allow you to set a temporary temperature setting change, on/off change etc. and it would only stay in that state temporarily. Many commercial building automation systems have a similar feature to allow you to temporarily light or cool a room at night or on a weekend day, for example but return to the natural unoccupied state after a defined time. Otherwise, the room would may stay light or conditioned through the period until the next occupancy schedule changed it making for a waste of energy.

You can easily automate that.

I’m aware that I can create an automation for each instance but I’m not aware of an automation that would be universal. Is there a way to do that with one automation that would work with any type of override?

When you use “override” do simply mean “change”? For example, you want a means of temporarily changing a climate entity’s state (let’s say it’s currently heat) to off for, say, 3 hours and then have it automatically revert to heat. Is that the general idea?

If it is then to create a so-called ‘universal’ mechanism to achieve that would involve designing a blueprint. It would guide the user to select the entity (climate, light, lock, etc), the temporary state they want, the time period for the temporary state, and then the blueprint would produce the required automation to execute it.

Yes, you have the concept correct. One example I have is turning on some things automatically when the home is occupied like basement AC, lights, etc. There are times that someone may remain at home but all of this is not needed. If you turn it off manually, it will not come back on automatically until the home is unoccupied and then reoccupied again. What I’m thinking of is exactly how you have described where I would want to turn off basement lights or AC for 6 hours and then let it come back on when the later when it is actually needed. On some commercial BAS systems I’ve used, if I manually turn on a light, for example, I can tell it to stay on for 6 hours and then it will return back off. That “override” is universal in the sense that any change can easily be made temporary.

I thought about the blueprint and may have to look into that some to try to make a template that would allow me to input the device, the temporary and return state and the time.

Home Assistant, is by it’s nature, a way to make things work more efficiently and save on energy resources and I was just suggesting that this additional feature would help in that effort since something does not have to be left on longer than needed just so it will be picked up by an automation trigger.

What I suggest you do first is create an automation that can temporarily change a specific entity’s state to some other value for a given period of time.

After you are satisfied that the automation works the way you want, proceed to convert the concept to a blueprint.

To get a better understanding of blueprints, review other people’s blueprints posted here:

Thanks for the suggestions. I’ll certainly look into the blueprints and I know a blueprint or automation will do what I’m looking for but still not exactly what I’m suggesting. I’m proposing an action such that when a switch it toggled, for example, that there is an option to tell it how long it should stay in that state. This seems to be more of an attribute added to the switch than a separate automation or blueprint. These are both set up for an anticipated situation. I’m suggestion a simple “one off” type of capability where it could be applied to any switch and on the fly from a phone or from anyone who does uses Home Assistant but not necessarily programs Home Assistant.

Thanks again.

It’s far more than merely an additional ‘attribute’. You’re asking for an architectural change that affects every entity’s functionality.

  1. This Feature Request has to inspire a volunteer developer to invest their time to implement it.
  2. It’s an architectural change so they first have to propose it in the Home Assistant’s Github Architecture repository where it must be vetted by the development team. If rejected, that’s where it ends.
  3. If the architectural change is accepted, the volunteer developer must submit their code to Home Assistant’s Github Core repository where it will be vetted, yet again, by the development team. If rejected, they have to make the recommended revisions.
  4. If it all finally passes muster, it will appear in a future release of Home Assistant. Otherwise, no.

I suggest you begin exploring blueprints because this Feature Request isn’t likely to be implemented any time soon.

I really appreciate the reply and even more, appreciate the work you describe. Not being a professional programmer, it’s hard to imagine all of the work that goes into HA and the awesome features it has. Understanding all that would be needed to add features is a big help.

I created a blueprint to perform this tasks. I created this to manually toggle a device and then return it to its default state after the defined time and can obviously use this as a tool to do the same for other entities. My original blueprint used a separately created button helper to trigger the automation but the button name is baked into the blueprint and therefore triggers all automations created from this blueprint. Is there a way of having an !input button that can create a unique trigger associated with the automations created rather than me creating a custom helper for each one?

@jlrosssc Are you in a position to share your code? I am looking for the functionality that you describe as outlined in my question Disable/enable a schedule through an automation

I’m not sure what I created would solve your dilemma. I’ve had a similar issue where the thermostat’s internal schedule overrides an automation. I’m not sure how to disable that but have accomplished the following scenarios that may help some. Here is what I have done: When we are away from home >5 miles, I reset the temperature setpoint on a sliding scale based on how far I am away from the house and based on heating or cooling and outdoor temperature. For example, if I have a 0.1 degree change for per mile, I run an automation every 5 minutes to update the set point with this new calculated set point. That allows the HVAC to respond based on how far I am away from the house and allows adequate recovery time and does not rely strictly on time of day. With me updating this every 5 minutes, it essentially corrects any impact from an internal thermostat schedule.

Hopefully that helps you with your challenge.