conversation:
# Enables support for tracking state changes over time
-history:
- exclude:
- domains:
- - automation
- - group
- - input_boolean
- - input_text
- - script
-
+history: !include history.yaml
+
# View all events in a logbook
-logbook:
- exclude:
- domains:
- - automation
- - group
- - input_boolean
- - input_text
- - script
+logbook: !include logbook.yaml
# Log Management
logger: !include logger.yaml
--- /dev/null
+######################################################################\r
+# History Configuration\r
+######################################################################\r
+\r
+exclude:\r
+ entities:\r
+ - sensor.time\r
+ - sensor.time_date\r
+ domains:\r
+ - automation\r
+ - group\r
+ - input_boolean\r
+ - input_text\r
+ #- script
\ No newline at end of file
--- /dev/null
+######################################################################\r
+# Logbook Configuration\r
+######################################################################\r
+\r
+exclude:\r
+ entities:\r
+ - sensor.time\r
+ - sensor.time_date\r
+ domains:\r
+ - automation\r
+ - group\r
+ - input_boolean\r
+ - input_text\r
+ #- script\r
purge_keep_days: 30\r
purge_interval: 1\r
exclude:\r
+ entities:\r
+ - sensor.time\r
+ - sensor.time_date\r
domains:\r
- automation\r
- group\r
- - script
\ No newline at end of file
+ #- script\r
--- /dev/null
+######################################################################
+# Alarm: Start Alarm
+#
+# Operations:
+# - script.notify_text
+# - media_player.volume_set
+# - media_player.play_media
+######################################################################
+
+start_alarm:
+ alias: "Attiva Allarme"
+ sequence:
+ - service: script.notify_text
+ data_template:
+ title: "Allarme"
+ message: "Rilevato allarme"
+ enable_persistent: 1
+
+ - service: media_player.volume_set
+ data_template:
+ entity_id: 'media_player.google_home'
+ volume_level: 0.5
+
+ - service: media_player.play_media
+ data_template:
+ entity_id: 'media_player.google_home'
+ media_content_type: 'audio/mp4'
+ media_content_id: 'https://home.giorgioravera.it/local/audio/alarm.mp3'
+
+######################################################################
+# Alarm: Stop Alarm
+#
+# Operations:
+# - media_player.media_stop
+# - script.volume_manager
+######################################################################
+
+stop_alarm:
+ alias: "Interrompi Allarme"
+ sequence:
+ - service: media_player.media_stop
+ data_template:
+ entity_id: 'media_player.google_home'
+
+ - service: script.volume_manager
+ data_template:
+ media_player: 'media_player.google_home'
# 1 -> bell'affare\r
#\r
# Operations:\r
+# - script.volume_manager\r
# - media_player.play_media\r
######################################################################\r
\r
entity_id: input_boolean.speech_notifications\r
state: 'on'\r
\r
- - service: script.notify_volume_manager\r
+ - service: script.volume_manager\r
data_template:\r
- media_player: "{{ media_player }}"\r
+ media_player: >-\r
+ {# Check Null Input #}\r
+ {% if media_player | length == 0 %}\r
+ {% set media_player = 'media_player.google_home' %}\r
+ {% endif %}\r
+ {{ media_player }}\r
volume_level: "{{ volume_level }}"\r
\r
- service: media_player.play_media\r
+++ /dev/null
-######################################################################
-# MQTT: Shelly Upgrade
-# - mqtt.publish
-######################################################################
-
-shelly_upgrade:
- alias: "Shelly: Aggiornamento Firmware"
- sequence:
- # Shelly 2 Tapparella Cucina
- - service: mqtt.publish
- data:
- topic: 'shellies/shellyswitch-55980F/command'
- payload: 'update_fw'
-
- # Shelly 2 Tapparella Sala
- - service: mqtt.publish
- data:
- topic: 'shellies/shellyswitch-135454/command'
- payload: 'update_fw'
-
- # Shelly 2 Tapparella Studio
- - service: mqtt.publish
- data:
- topic: 'shellies/shellyswitch-13572B/command'
- payload: 'update_fw'
-
- # Shelly 2 Tapparella Camera
- - service: mqtt.publish
- data:
- topic: 'shellies/shellyswitch-559C49/command'
- payload: 'update_fw'
# - media_player.volume_set\r
######################################################################\r
\r
-notify_volume_manager:\r
+volume_manager:\r
alias: Gestione Volume\r
sequence:\r
- service: media_player.volume_set\r
entity_id: input_boolean.speech_notifications\r
state: 'on'\r
\r
- - service: script.notify_volume_manager\r
+ - service: script.volume_manager\r
data_template:\r
media_player: "{{ media_player }}"\r
volume_level: "{{ volume_level }}"\r
--- /dev/null
+######################################################################
+# Shelly: Upgrade
+# - mqtt.publish
+######################################################################
+
+shelly_upgrade:
+ alias: "Shelly: Aggiornamento Firmware"
+ sequence:
+ # Shelly 2 Tapparella Cucina
+ - service: mqtt.publish
+ data:
+ topic: 'shellies/shellyswitch-55980F/command'
+ payload: 'update_fw'
+
+ # Shelly 2 Tapparella Sala
+ - service: mqtt.publish
+ data:
+ topic: 'shellies/shellyswitch-135454/command'
+ payload: 'update_fw'
+
+ # Shelly 2 Tapparella Studio
+ - service: mqtt.publish
+ data:
+ topic: 'shellies/shellyswitch-13572B/command'
+ payload: 'update_fw'
+
+ # Shelly 2 Tapparella Camera
+ - service: mqtt.publish
+ data:
+ topic: 'shellies/shellyswitch-559C49/command'
+ payload: 'update_fw'