From b86b332fb7e87c797a954a07f8ec169f474f5ed4 Mon Sep 17 00:00:00 2001 From: pgrondek Date: Sat, 21 Nov 2020 04:28:38 +0100 Subject: [PATCH] Update automations --- automations/files/finished-work.yaml | 8 ++--- automations/files/goto-sleep.yaml | 5 ++- automations/files/humidity.yaml | 17 ++++++++++ automations/files/ryzen.yaml | 50 ---------------------------- 4 files changed, 25 insertions(+), 55 deletions(-) create mode 100644 automations/files/humidity.yaml delete mode 100644 automations/files/ryzen.yaml diff --git a/automations/files/finished-work.yaml b/automations/files/finished-work.yaml index 4bea1d1..9b2aa49 100644 --- a/automations/files/finished-work.yaml +++ b/automations/files/finished-work.yaml @@ -14,8 +14,8 @@ brightness: 200 rgb_color: - 0 - - 255 - - 0 + - 200 + - 83 entity_id: - light.computer_left - light.computer_right @@ -25,8 +25,8 @@ brightness: 200 rgb_color: - 0 - - 0 - - 255 + - 200 + - 83 entity_id: - light.computer_left - light.computer_right diff --git a/automations/files/goto-sleep.yaml b/automations/files/goto-sleep.yaml index 969e592..1c120b7 100644 --- a/automations/files/goto-sleep.yaml +++ b/automations/files/goto-sleep.yaml @@ -3,7 +3,7 @@ description: '' trigger: - platform: time - at: '23:55' + at: '23:25' condition: - condition: time weekday: @@ -28,5 +28,8 @@ - light.computer_left - light.computer_right - delay: '0:05:00' + - condition: state + entity_id: binary_sensor.desktop + state: 'on' - service: shell_command.poweroff_pc mode: single diff --git a/automations/files/humidity.yaml b/automations/files/humidity.yaml new file mode 100644 index 0000000..dfeceab --- /dev/null +++ b/automations/files/humidity.yaml @@ -0,0 +1,17 @@ +- id: humidity_notificaiton + alias: Humidity notification + trigger: + - platform: numeric_state + entity_id: sensor.ble_humidity_bedroom_sensor + below: '40' + condition: [] + action: + - service: tts.google_translate_say + data: + language: pl + message: Niska wilgotność uzupełnij wodę w nawilżaczu + entity_id: media_player.livingroom_speaker + - service: notify.mobile_app_sm_g965f + data: + message: Niska wilgotność uzupełnij wodę w nawilżaczu + mode: single diff --git a/automations/files/ryzen.yaml b/automations/files/ryzen.yaml deleted file mode 100644 index 8fa8e7b..0000000 --- a/automations/files/ryzen.yaml +++ /dev/null @@ -1,50 +0,0 @@ -- id: ryzen_notify - alias: Ryzen Notifications - description: '' - trigger: - - platform: state - entity_id: sensor.imap_notifications - condition: - - condition: template - value_template: '{{ trigger.to_state.state | int > trigger.from_state.state | int }}' - action: - - service: light.turn_on - data: - brightness: 200 - rgb_color: - - 244 - - 117 - - 30 - entity_id: - - light.computer_left - - light.computer_right - - service: light.turn_on - data: - flash: long - brightness: 200 - rgb_color: - - 255 - - 0 - - 0 - entity_id: - - light.computer_left - - light.computer_right - - service: tts.google_translate_say - data: - language: pl - message: UWAGA Ryzen jest dostępny kupuj teraz - entity_id: media_player.livingroom_speaker - - service: notify.mobile_app_sm_g965f - data: - message: Ryzen 5900X jest dostępny - - delay: 0:00:05 - - service: media_player.volume_set - data: - volume_level: 1 - entity_id: media_player.livingroom_speaker - - service: media_player.play_media - data: - media_content_id: media-source://media_source/local/JohnCena.mp3 - media_content_type: music - entity_id: media_player.livingroom_speaker - mode: single