-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathscripts.yaml
174 lines (174 loc) · 5.31 KB
/
scripts.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
ring_simon_phone:
alias: Simon Handy klingeln lassen
sequence:
- service: notify.mobile_app_pixel_7a
data:
title: Home Assistant
message: Wo bist du? Ich suche dich schon überall!
data:
ttl: 0
importance: high
priority: high
tag: Find
channel: alarm_stream
ring_lisa_phone:
alias: Lisa Handy klingeln lassen
sequence:
- service: notify.mobile_app_lisa_note12pro
data:
title: Home Assistant
message: Wo bist du? Ich suche dich schon überall!
data:
ttl: 0
importance: high
priority: high
tag: Find
channel: alarm_stream
lina_schlafenszeit:
alias: Lina Schlafenszeit
icon: mdi:human-baby-changing-table
sequence:
- service: light.turn_off
data: {}
target:
entity_id:
- light.schlafzimmer_deckenleuchte
- light.kinderzimmer_deckenleuchte
- service: light.turn_on
data:
entity_id:
- light.kinderzimmer_nachttisch
- service: media_player.select_source
data:
source: 90 Minutes Womb Sounds (Baby-Einschlafhilfe)
entity_id: media_player.lisi_sonoszp_schlafzimmer
mode: single
simon_pc_aufwecken:
alias: Simon PC - Aufwecken
sequence:
- service: wake_on_lan.send_magic_packet
data:
mac: 74-D4-35-B0-E5-F7
broadcast_address: 192.168.178.255
simon_pc_herunterfahren:
alias: Simon PC - Herunterfahren
sequence:
- service: mqtt.publish
data:
topic: iotlink/workgroup/simon-pc/commands/shutdown
payload: ""
sonos_say:
alias: Sonos TTS script
sequence:
- service: sonos.snapshot
data_template:
entity_id: "{{ sonos_entity }}"
- service: media_player.unjoin
data_template:
entity_id: "{{ sonos_entity }}"
- service: media_player.volume_set
data_template:
entity_id: "{{ sonos_entity }}"
volume_level: "{{ volume }}"
- service: tts.speak
data_template:
entity_id: "{{ sonos_entity }}"
message: "{{ message }}"
- delay: "{{ delay }}"
- service: sonos.restore
data_template:
entity_id: "{{ sonos_entity }}"
vacuuming_of_selection:
alias: Vacuuming of selection
icon: mdi:robot-vacuum
sequence:
- service: script.turn_on
target:
entity_id: script.vacuum_clean_segments_message
data:
variables:
segments:
'{{expand("group.vacuum_rooms") | selectattr("state","eq","on")
| map(attribute="attributes.room_id") | list | to_json}}'
iterations: "{{states('input_number.general_robot_vacuum_cleaner_zone_repetitions')}}"
- if:
- condition: state
entity_id: input_boolean.living_room_select_vacuuming
state: "on"
then:
- service: input_datetime.set_datetime
target:
entity_id: input_datetime.living_room_last_vacuumed
data:
date: "{{ now().strftime('%Y-%m-%d') }}"
- if:
- condition: state
entity_id: input_boolean.kitchen_select_vacuuming
state: "on"
then:
- service: input_datetime.set_datetime
target:
entity_id: input_datetime.kitchen_last_vacuumed
data:
date: "{{ now().strftime('%Y-%m-%d') }}"
- if:
- condition: state
entity_id: input_boolean.floor_select_vacuuming
state: "on"
then:
- service: input_datetime.set_datetime
target:
entity_id: input_datetime.hallway_last_vacuumed
data:
date: "{{ now().strftime('%Y-%m-%d') }}"
- service: input_boolean.turn_off
target:
entity_id:
- input_boolean.living_room_select_vacuuming
- input_boolean.kitchen_select_vacuuming
- input_boolean.bath_room_select_vacuuming
- input_boolean.floor_select_vacuuming
- input_boolean.office_select_vacuuming
- input_boolean.stairs_select_vacuuming
data: {}
- service: input_number.set_value
data:
value: 1
target:
entity_id: input_number.general_robot_vacuum_cleaner_zone_repetitions
mode: single
vacuum_clean_segments_message:
alias: vacuum_clean_segments_message
sequence:
- service: mqtt.publish
data:
topic: valetudo/FalseScrawnyHornet/MapSegmentationCapability/clean/set
payload_template: '{"segment_ids": {{segments}}, "iterations": {{iterations}}}'
mode: single
vacuum_go_to_the_trash_can:
alias: vacuum_go_to_the_trash_can
sequence:
- service: mqtt.publish
data:
topic: valetudo/FalseScrawnyHornet/GoToLocationCapability/go/set
payload: '{"coordinates": {"x": 27340, "y": 22120}}'
mode: single
vacuum_repetitions:
alias: Vacuum Repetitions
sequence:
- if:
- condition: numeric_state
entity_id: input_number.general_robot_vacuum_cleaner_zone_repetitions
above: 2
then:
- service: input_number.set_value
data:
value: 1
target:
entity_id: input_number.general_robot_vacuum_cleaner_zone_repetitions
else:
- service: input_number.increment
data: {}
target:
entity_id: input_number.general_robot_vacuum_cleaner_zone_repetitions
mode: single