Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Sets thermostat to away mode if all mobile devices are away
- - alias: 'Away Mode'
- trigger:
- - platform: state
- entity_id: group.mobile_devices
- from: "home"
- to: "not_home"
- condition:
- - condition: state
- entity_id: group.mobile_devices
- state: "not_home"
- - condition: state
- entity_id: input_boolean.location_override
- state: "off"
- action:
- - service: climate.set_away_mode
- entity_id:
- - climate.downstairs
- data:
- away_mode: true
- # Sets thermostats to home mode if mobile devices change from away to home
- - alias: 'Home Mode'
- trigger:
- - platform: state
- entity_id: group.mobile_devices
- from: "not_home"
- to: "home"
- condition:
- - condition: state
- entity_id: group.mobile_devices
- state: "home"
- - condition: state
- entity_id: input_boolean.location_override
- state: "off"
- action:
- - service: climate.set_away_mode
- entity_id:
- - climate.downstairs
- data:
- away_mode: false
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement