diff --git a/automations/files/daily.yaml b/automations/files/daily.yaml index 6931904..38d8e77 100644 --- a/automations/files/daily.yaml +++ b/automations/files/daily.yaml @@ -5,6 +5,16 @@ at: '10:55' condition: [] action: + - service: light.turn_on + data: + brightness: 200 + rgb_color: + - 0 + - 0 + - 255 + entity_id: + - light.computer_left + - light.computer_right - service: light.turn_on data: flash: long @@ -23,7 +33,13 @@ trigger: - platform: time at: '11:25' - condition: [] + condition: + - condition: state + entity_id: light.computer_left + state: 'on' + - condition: state + entity_id: light.computer_right + state: 'on' action: - service: light.turn_on data: @@ -31,4 +47,9 @@ entity_id: - light.computer_left - light.computer_right + - delay: 5 + - service: light.turn_off + entity_id: + - light.computer_left + - light.computer_right mode: single diff --git a/automations/files/finished-work.yaml b/automations/files/finished-work.yaml new file mode 100644 index 0000000..4bea1d1 --- /dev/null +++ b/automations/files/finished-work.yaml @@ -0,0 +1,33 @@ +- id: work_finished + alias: Notify when finished work + description: '' + trigger: + - platform: state + entity_id: binary_sensor.luxoft + to: 'on' + for: + hours: 8 + condition: [] + action: + - service: light.turn_on + data: + brightness: 200 + rgb_color: + - 0 + - 255 + - 0 + entity_id: + - light.computer_left + - light.computer_right + - service: light.turn_on + data: + flash: long + brightness: 200 + rgb_color: + - 0 + - 0 + - 255 + entity_id: + - light.computer_left + - light.computer_right + mode: single diff --git a/automations/templates/lights.yaml.j2 b/automations/templates/lights.yaml.j2 index 41de985..fa6c0c0 100644 --- a/automations/templates/lights.yaml.j2 +++ b/automations/templates/lights.yaml.j2 @@ -39,7 +39,7 @@ condition: - condition: state entity_id: {{ light.entityId }} - state: 'off' + state: 'on' action: - service: light.turn_on data: diff --git a/automations/vars/main.yaml b/automations/vars/main.yaml index 899fb6f..7ffeea5 100644 --- a/automations/vars/main.yaml +++ b/automations/vars/main.yaml @@ -7,6 +7,8 @@ lights: name: TV Middle - entityId: light.tv_right name: TV Right + - entityId: light.couch_lamp + name: Couch lamp - entityId: light.kitchen_01 name: Kitchen 01 - entityId: light.kitchen_02