mysmarthome/packages/tts.yaml

50 lines
1.1 KiB
YAML
Raw Permalink Normal View History

2019-04-17 22:46:06 +00:00
homeassistant:
input_text:
tts:
name: Text To Speech
initial: Initial text
input_boolean:
greeting:
name: Greeting
initial: off
input_number:
tts_volume_level_morning:
name: Morning TTS Volume
min: 0
max: 1
2019-12-20 15:32:28 +00:00
step: 0.1
2019-04-17 22:46:06 +00:00
tts_volume_level_afternoon:
name: Afternoon TTS Volume
min: 0
max: 1
2019-12-20 15:32:28 +00:00
step: 0.1
2019-04-17 22:46:06 +00:00
tts_volume_level_evening:
name: Evening TTS Volume
min: 0
max: 1
2019-12-20 15:32:28 +00:00
step: 0.1
2019-04-17 22:46:06 +00:00
tts_volume_level_alert:
name: TTS Volume Alert Mode
initial: 1
min: 0
max: 1
step: 0.1
automation:
2019-12-20 15:32:28 +00:00
###############################################################################
# The text entered in the text box will be announced in the house
###############################################################################
2019-04-17 22:46:06 +00:00
- alias: Text Changed Event
initial_state: true
trigger:
- platform: state
entity_id: input_text.tts
action:
- service: script.voice_notify
2022-12-05 00:02:34 +00:00
data:
2019-04-17 22:46:06 +00:00
message: "{{ trigger.to_state.state }}"
2019-12-20 15:32:28 +00:00
greeting: "{{ 'yes' if states('input_boolean.greeting') == 'on' else 'no' }}"