mirror of
https://github.com/skalavala/mysmarthome.git
synced 2025-09-13 23:14:32 +00:00
clean up and re-org
This commit is contained in:
@@ -47,55 +47,6 @@ input_datetime:
|
||||
has_time: true
|
||||
initial: "09:00"
|
||||
|
||||
#################################################################################
|
||||
# _____ _ _
|
||||
# / ____| (_) | |
|
||||
# | (___ ___ _ __ _ _ __ | |_ ___
|
||||
# \___ \ / __| '__| | '_ \| __/ __|
|
||||
# ____) | (__| | | | |_) | |_\__ \
|
||||
# |_____/ \___|_| |_| .__/ \__|___/
|
||||
# | |
|
||||
# |_|
|
||||
#################################################################################
|
||||
|
||||
script:
|
||||
###############################################################################
|
||||
# Notifies to take pills, starts timer again!
|
||||
# Voice notifications at home - only if the option is selected.
|
||||
###############################################################################
|
||||
remind_pill:
|
||||
sequence:
|
||||
- service: script.notify_me
|
||||
data:
|
||||
message: "ALERT: PLEASE TAKE YOUR TABLETS!"
|
||||
- service: timer.start
|
||||
entity_id: timer.timer_pill_reminder
|
||||
- condition: template
|
||||
value_template: "{{ states('input_boolean.pill_voice_notification') == 'on' }}"
|
||||
- service: script.voice_notify
|
||||
data_template:
|
||||
message: >
|
||||
Please take the tablets. It looks like you have forgotten to take today's
|
||||
dose of tablets... Once again, this is a reminder for you to take the tablets.
|
||||
|
||||
###############################################################################
|
||||
# Stops timer, Records that the pills are taken, and notifies!
|
||||
###############################################################################
|
||||
pill_taken:
|
||||
sequence:
|
||||
- service: timer.cancel
|
||||
entity_id: timer.timer_pill_reminder
|
||||
- service: input_boolean.turn_on
|
||||
entity_id: input_boolean.pill_taken
|
||||
- service: script.notify_me
|
||||
data:
|
||||
message: "Thank you for taking tablets on time!"
|
||||
- condition: template
|
||||
value_template: "{{ states('input_boolean.pill_voice_notification') == 'on' }}"
|
||||
- service: script.voice_notify
|
||||
data:
|
||||
message: "Thank you for taking tablets on time!"
|
||||
|
||||
###############################################################################
|
||||
# _ _ _
|
||||
# /\ | | | | (_)
|
||||
@@ -103,8 +54,7 @@ script:
|
||||
# / /\ \| | | | __/ _ \| '_ ` _ \ / _` | __| |/ _ \| '_ \/ __|
|
||||
# / ____ \ |_| | || (_) | | | | | | (_| | |_| | (_) | | | \__ \
|
||||
# /_/ \_\__,_|\__\___/|_| |_| |_|\__,_|\__|_|\___/|_| |_|___/
|
||||
#
|
||||
|
||||
###############################################################################
|
||||
automation:
|
||||
###############################################################################
|
||||
# Turn On "Pill Taken" Input Boolean when the Pill Box is Opened
|
||||
|
Reference in New Issue
Block a user