Automate manual state setting

I’ve read up on some python scripting that would allow for automated state changes, but is there really nothing more simple? I have lots of automations that are based on my wife and I (Family) leaving the home zone. Whenever we have a babysitter staying in the house, after we leave, I go into developer settings and manually change Family back to “home” after we’ve been detected as “not_home”; this turns everything back on and it will stay as such until we come home and leave the next time.

I was just hoping to set up an automation that would allow me to make this state change with the press of a widget.

Manually pushing a button, sacrilege! Install the companion app and use that for presence detection?

Or perhaps router/AP integration as many are supported.

If you really want a button. Create a Template Switch and add that to Lovelace perhaps.

Companion app is installed and I am using it for presence detection already. My wife and I are in the Family group, whose state change activates certain automations. However, we occasionally leave the home when others remain, so I change the state manually to turn everything back on. I was hoping to simplify that manual input by having a widget.

Create an input select helper. Give it options like:

automation_mode:
  name: Automation Mode
  options:
  - 'Normal'
  - 'Baby Sitter'
  - 'Party Mode'
  - 'etc...'

Use this input select as a state condition in your automations to prevent them running when you dont want them to.

This way you only have to set one input select option in your dashboard to affect the operation of multiple automations.

2 Likes

Similar to this, I just use an input_boolean as a guest mode. Tom’s idea is simple and gives you more options. I’ve been using my version almost since the day I started this hobby without modification (> 2 years).

2 Likes

How is the above any different than me simply changing the state to “home” in developer tools? This state change affects all my automations, it’s not like I have multiple parameters to change.

Where would I be choosing these inputs described above?

Never mind, I understand how it works now. Created a boolean toggle which turns Guest mode on/off and created the widget on my phone. Using that boolean helper in my automations, as you suggested, to be a condition.

Thanks!