Skip to content

Commit

Permalink
covers use service group instead of single calls
Browse files Browse the repository at this point in the history
  • Loading branch information
rpanfili committed Jul 6, 2019
1 parent facb456 commit 2f2f69e
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 110 deletions.
106 changes: 4 additions & 102 deletions automations.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@
- condition: time
after: "08:00:00"
action:
service: automation.turn_on
entity_id: automation.all_roller_shutter_up
- service: cover.open_cover
entity_id: all
# - condition: or
# conditions:
# - condition: time
Expand All @@ -67,8 +67,8 @@
event: sunset
# offset: "00:30:00"
action:
service: automation.turn_on
entity_id: automation.all_roller_shutter_down
service: cover.close_cover
entity_id: all

- id: "notify_homeassistant_startup"
alias: "Notify HomeAssistant startup"
Expand Down Expand Up @@ -178,101 +178,3 @@
service_template: '{{ trigger.event.data.service }}'
data_template:
entity_id: '{{ trigger.event.data.entity_id }}'

- id: 'weekend_roller_shutter_up'
alias: "Weekend roller shutter up"
initial_state: False
trigger:
- platform: state
entity_id: automation.weekend_roller_shutter_up
to: 'on'
action:
- service: script.roller_shutter_set_position
data:
entity_id: input_number.living_room_left_rolling_shutter
position: 100
- service: script.roller_shutter_set_position
data:
entity_id: input_number.living_room_right_rolling_shutter
position: 100
- service: script.roller_shutter_set_position
data:
entity_id: input_number.kitchen_left_rolling_shutter
position: 100
- service: script.roller_shutter_set_position
data:
entity_id: input_number.kitchen_right_rolling_shutter
position: 100
- service: cover.open_cover
data:
entity_id: cover.green_room
- service: script.roller_shutter_set_position
data:
entity_id: input_number.pink_room_rolling_shutter
position: 100
- service: script.roller_shutter_set_position
data:
entity_id: input_number.bathroom_rolling_shutter
position: 100

- service: input_select.select_option
data:
entity_id: input_select.roller_shutters_scene
option: "day"
- service: automation.turn_off
entity_id: automation.weekend_roller_shutter_up

- id: 'all_roller_shutter_up'
alias: "All roller shutter up"
initial_state: False
trigger:
- platform: state
entity_id: automation.all_roller_shutter_up
to: 'on'
action:
- service: cover.open_cover
entity_id: cover.bedroom
- service: cover.open_cover
entity_id: cover.bathroom
- service: cover.open_cover
entity_id: cover.living_room_left
- service: cover.open_cover
entity_id: cover.living_room_right
- service: cover.open_cover
entity_id: cover.kitchen_left
- service: cover.open_cover
entity_id: cover.kitchen_right
- service: cover.open_cover
entity_id: cover.pink_room
- service: cover.open_cover
entity_id: cover.green_room
- service: automation.turn_off
entity_id: automation.all_roller_shutter_up


- id: 'all_roller_shutter_down'
alias: "All roller shutter down"
initial_state: False
trigger:
- platform: state
entity_id: automation.all_roller_shutter_down
to: 'on'
action:
- service: cover.close_cover
entity_id: cover.bedroom
- service: cover.close_cover
entity_id: cover.bathroom
- service: cover.close_cover
entity_id: cover.living_room_left
- service: cover.close_cover
entity_id: cover.living_room_right
- service: cover.close_cover
entity_id: cover.kitchen_left
- service: cover.close_cover
entity_id: cover.kitchen_right
- service: cover.close_cover
entity_id: cover.pink_room
- service: cover.close_cover
entity_id: cover.green_room
- service: automation.turn_off
entity_id: automation.all_roller_shutter_down
8 changes: 1 addition & 7 deletions configuration.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -487,13 +487,7 @@ input_number:
step: 5
initial: 60
unit_of_measurement: "%"
icon: mdi:water-percent

input_boolean:
avoid_bedroom_roller_shutter_up_during_weekend:
name: "Avoid bedroom roller shutter up during weekend"
initial: on
icon: mdi:sleep
icon: mdi:water-percent

binary_sensor: !include_dir_merge_list binary_sensor/

Expand Down
1 change: 0 additions & 1 deletion ui-lovelace.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,6 @@ views:
entities:
- automation.roller_shutter_sunrise
- automation.roller_shutter_sunset
- input_boolean.avoid_bedroom_roller_shutter_up_during_weekend
- switch.automatic_cat_passage
- input_number.covers_min_position

Expand Down

0 comments on commit 2f2f69e

Please sign in to comment.