diff --git a/packages/cameras.yaml b/packages/cameras.yaml
index f8daf14..a2072cb 100644
--- a/packages/cameras.yaml
+++ b/packages/cameras.yaml
@@ -851,14 +851,31 @@ automation:
name: "frontyard"
#
- # Every 15 minutes, change stream to alternate view
+ # Every 15 minutes, change stream to alternate view with random cameras
#
- alias: Reset Stream On Chromecast
trigger:
- platform: time_pattern
minutes: "/15"
action:
+ - service_template: "script.{{- ['driveway', 'patio', 'playarea'] | random -}}_cam"
+
+script:
+ driveway_cam:
+ sequence:
- service: script.stream2chromecast
data_template:
url: !secret driveway_camera_stream_url
name: "driveway"
+ patio_cam:
+ sequence:
+ - service: script.stream2chromecast
+ data_template:
+ url: !secret patio_camera_stream_url
+ name: "patio"
+ playarea_cam:
+ sequence:
+ - service: script.stream2chromecast
+ data_template:
+ url: !secret playarea_camera_stream_url
+ name: "playarea"
diff --git a/packages/door_sensors.yaml b/packages/door_sensors.yaml
index 38b26ef..e9c7074 100644
--- a/packages/door_sensors.yaml
+++ b/packages/door_sensors.yaml
@@ -259,9 +259,9 @@ automation:
data_template:
message: >
{% if trigger.to_state.state | lower == "on" %}
- Your {{ trigger.to_state.attributes.friendly_name.replace('Sensor', '') -}} is OPEN.
+ Your {{ trigger.to_state.attributes.friendly_name.replace('Sensor', '') |lower -}} is open.
{% else %}
- Your {{ trigger.to_state.attributes.friendly_name.replace('Sensor', '') -}} is CLOSED.
+ Your {{ trigger.to_state.attributes.friendly_name.replace('Sensor', '') |lower -}} is closed.
{% endif %}
- alias: When Front Door Opens Turn Front Room Lights ON
diff --git a/packages/scripts.yaml b/packages/scripts.yaml
index e46b1fe..9103d7a 100644
--- a/packages/scripts.yaml
+++ b/packages/scripts.yaml
@@ -39,6 +39,18 @@ script:
ringtone_id: 10
ringtone_vol: 30
+ play_fav_song:
+ sequence:
+ - service: media_player.volume_set
+ entity_id: media_player.living_room, media_player.upstairs
+ data:
+ volume_level: "0.15"
+ - service: media_player.play_media
+ data:
+ entity_id: media_player.living_room, media_player.upstairs
+ media_content_id: !secret fav_song_url
+ media_content_type: "music"
+
play_dog_sounds:
sequence:
- service: media_player.volume_set
diff --git a/packages/test.yaml b/packages/test.yaml
index f05a96f..30f214f 100644
--- a/packages/test.yaml
+++ b/packages/test.yaml
@@ -1006,3 +1006,86 @@
# data_template:
# entity_id: climate.cooler_fan
# temperature: "{{ states.climate.main_floor.temperature |float }}"
+
+# automation:
+# - id: sensor
+# alias: sensor
+# trigger:
+# - platform: state
+# entity_id: binary_sensor.door
+# from: "off"
+# to: "on"
+# for: "00:00:10"
+# action:
+# - service_template: "homeassistant.turn_{{- 'off' if trigger.to_state.state == 'on' else 'on' }}"
+# entity_id: switch.luce_corridoio
+
+# homeassistant:
+# group:
+# kitchen:
+# name: Kitchen
+# entities:
+# - light.family_room
+# - light.gateway_light_34ce008ad65d
+# - light.hue_color_lamp_1
+# - light.hue_color_lamp_2
+# - light.hue_color_lamp_3
+# - light.master_bedroom
+# - light.master_bedroom_1
+# - light.master_bedroom_2
+
+# - alias: "doods fremme video"
+# trigger:
+# platform: state
+# entity_id: image_processing.doods_fremme
+# # condition:
+# # condition: template
+# # value_template: "{{ 'person' in state_attr('image_processing.doods_fremme', 'summary') }}"
+# action:
+# - service: input_boolean.toggle
+# entity_id: input_boolean.dummy
+# - service: camera.record
+# data_template:
+# entity_id: camera.fremme
+# filename: "/tmp/{{- trigger.entity_id.split('.')[1].split('_')[1] -}}_{{- states.input_boolean.dummy_fremme.last_updated.strftime('%Y%m%d-%H%M%S') -}}.mp4"
+# duration: 20
+# lookback: 10
+# - delay: "00:00:20"
+# - service: notify.eirikz_telegram
+# data_template:
+# title: "Doods"
+# message: "fremme"
+# data:
+# video:
+# file: "/tmp/{{- trigger.entity_id.split('.')[1].split('_')[1] -}}_{{- states.input_boolean.dummy_fremme.last_updated.strftime('%Y%m%d-%H%M%S') -}}.mp4"
+
+# homeassistant:
+
+# input_boolean:
+# dummy_fremme:
+# name: "Dummy Fremme Input Boolean!"
+# icon: mdi:sticker-emoji
+# initial: on
+
+# input_label:
+# file_1:
+# file_2:
+
+# automation:
+# - alias: "my test"
+# initial_state: "on"
+# trigger:
+# platform: state
+# entity_id: switch.kitchen
+# action:
+# - service: input_boolean.toggle
+# entity_id: input_boolean.dummy
+# - service: input_label.set_value
+# data_template:
+# entity_id: "input_label.file_1"
+# value: "/tmp/{{- trigger.entity_id.split('.')[1] -}}_{{- states.input_boolean.dummy.last_updated.strftime('%Y%m%d-%H%M%S') -}}.mp4"
+# - delay: "00:00:05"
+# - service: input_label.set_value
+# data_template:
+# entity_id: "input_label.file_2"
+# value: "/tmp/{{- trigger.entity_id.split('.')[1] -}}_{{- states.input_boolean.dummy.last_updated.strftime('%Y%m%d-%H%M%S') -}}.mp4"
diff --git a/packages/watchdog.yaml b/packages/watchdog.yaml
index d988fd6..90c632e 100644
--- a/packages/watchdog.yaml
+++ b/packages/watchdog.yaml
@@ -114,11 +114,9 @@ automation:
- switch.office_room
- switch.prayer_room
- switch.upstairs_fragrance
- - switch.wemoswitch1
- switch.zwave_smart_switch_switch
- light.family_room
- light.family_room_2
- - light.gateway_light_34ce008ad65d
- light.hue_color_lamp_1
- light.hue_color_lamp_2
- light.hue_color_lamp_3
diff --git a/packages/xiaomi_magic_cubes.yaml b/packages/xiaomi_magic_cubes.yaml
index b757502..b7e449a 100644
--- a/packages/xiaomi_magic_cubes.yaml
+++ b/packages/xiaomi_magic_cubes.yaml
@@ -392,7 +392,7 @@ automation:
action:
- service_template: >
{% if states('input_boolean.home_mode_away') == 'off' %}
- script.play_ringtone
+ script.play_fav_song
{% else %}
script.play_dog_sounds
{% endif %}
diff --git a/zwcfg_0xd89c4f0c.xml b/zwcfg_0xd89c4f0c.xml
index 31ffdc6..bfcd465 100644
--- a/zwcfg_0xd89c4f0c.xml
+++ b/zwcfg_0xd89c4f0c.xml
@@ -22,7 +22,7 @@
-
+
@@ -34,10 +34,10 @@
-
+
-
+
@@ -168,7 +168,7 @@
-
+
@@ -216,9 +216,9 @@
-
+
-
+
@@ -350,7 +350,7 @@
-
+
@@ -710,7 +710,7 @@
-
+
@@ -728,9 +728,9 @@
-
-
-
+
+
+
@@ -984,7 +984,7 @@
-
+
@@ -1006,11 +1006,11 @@
-
-
-
+
+
+
-
+
@@ -1181,7 +1181,7 @@
-
+
@@ -1190,8 +1190,8 @@
-
-
+
+
@@ -1339,7 +1339,7 @@
-
+
@@ -1369,7 +1369,7 @@
-
+
@@ -1416,7 +1416,7 @@
-
+
@@ -2023,7 +2023,7 @@
-
+
@@ -2038,7 +2038,7 @@
-
+
@@ -2248,7 +2248,7 @@
-
+
@@ -2262,9 +2262,9 @@
-
+
-
+