From 305a009ac2f2bef636679a1936ea08ed3a705465 Mon Sep 17 00:00:00 2001 From: Przemek Grondek Date: Sat, 30 Apr 2022 18:09:12 +0200 Subject: [PATCH] Fix automation for lowering bathroom music volume --- .../automations/bathroom-shower-motion.yaml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/configuration/automations/bathroom-shower-motion.yaml b/configuration/automations/bathroom-shower-motion.yaml index 752c7d1..d409fe6 100644 --- a/configuration/automations/bathroom-shower-motion.yaml +++ b/configuration/automations/bathroom-shower-motion.yaml @@ -20,7 +20,8 @@ target: entity_id: media_player.bathroom -- alias: '[Bathroom] Shower Motion Off' +- id: bathroom-shower-motion-off + alias: '[Bathroom] Shower Motion Off' mode: restart trigger: - platform: state @@ -48,13 +49,18 @@ sequence: - repeat: until: - - condition: state + - condition: numeric_state entity_id: media_player.bathroom attribute: volume_level - state: '0.45' + below: '0.45' sequence: - service: media_player.volume_down target: entity_id: media_player.bathroom - delay: seconds: 10 + - service: media_player.volume_set + data: + volume_level: 0.45 + target: + entity_id: media_player.bathroom \ No newline at end of file