Files
fresh-home/scripts/master_bedroom/wake_up_the_master_bedroom.yaml
T
2025-11-14 16:46:44 -05:00

61 lines
1.8 KiB
YAML

alias: Wake Up the Master Bedroom
mode: single
icon: mdi:alarm
sequence:
- repeat:
while:
- condition: state
entity_id: binary_sensor.bed_presence_c175a4_bed_occupied_either
state: "on"
sequence:
- variables:
volume: "{{ 0.5 + (repeat.index * 0.05) }}"
- action: media_player.volume_set
target:
entity_id: media_player.ma_home_assistant_voice_097b44_media_player
data:
volume_level: "{{iif(volume>1,1,volume)}}"
# - action: media_player.play_media
# data:
# media_content_id: media-source://media_source/alarms/Alarm_Clock.mp3
# media_content_type: music
# target:
# entity_id: media_player.ma_home_assistant_voice_097b44_media_player
# - delay:
# hours: 0
# minutes: 0
# seconds: 12
# milliseconds: 0
- action: tts.speak
target:
entity_id: tts.google_translate_en_com
data:
media_player_entity_id: media_player.ma_home_assistant_voice_097b44_media_player
message: "Its {{ now().strftime('%-I:%M %p') }} so you need to get out of bed and get ready for work and get the kids ready for school"
# - action: tts.speak
# target:
# entity_id: tts.google_ai_tts
# data:
# cache: false
# message: "Wake the user in a flirtacious and seductive voice: {{ response.text }}"
# media_player_entity_id: media_player.great_room
# options:
# voice: Callirrhoe
- delay:
hours: 0
minutes: 5
seconds: 0
milliseconds: 0
- action: input_select.select_option
data:
option: Auto
target:
entity_id: input_select.master_bedroom_mode