-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtemplates.yaml
100 lines (98 loc) · 3.28 KB
/
templates.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
- sensor:
- name: Floor Helper Motion Sensor Temperature Fixed
unique_id: mysensor0001
state: >-
{{
(states('sensor.floor_helper_motion_sensor_temperature') | float(0.0) + 1.8) | round(2)
}}
device_class: temperature
state_class: measurement
unit_of_measurement: '°C'
- name: Floor Motion Sensor Temperature Fixed
unique_id: mysensor0002
state: >-
{{
(states('sensor.floor_motion_sensor_temperature') | float(0.0) + 1.8) | round(2)
}}
device_class: temperature
state_class: measurement
unit_of_measurement: '°C'
- name: Outdoor Temperature
unique_id: mysensor0003
state: >-
{{
state_attr('weather.home', 'temperature') | float(0.0)
}}
device_class: temperature
state_class: measurement
unit_of_measurement: '°C'
- name: Outdoor Humidity
unique_id: mysensor0004
state: >-
{{
state_attr('weather.home', 'humidity') | float(0.0)
}}
device_class: humidity
state_class: measurement
unit_of_measurement: '%'
- name: Outdoor Pressure
unique_id: mysensor0005
state: >-
{{
state_attr('weather.home', 'pressure') | int
}}
device_class: pressure
state_class: measurement
unit_of_measurement: 'hPa'
- name: Daytime Light Brightness
unique_id: mysensor0008
state: >-
{% if states('input_select.daytime') == 'Morning' or states('input_select.daytime') == 'Daytimes' -%}
254
{% elif states('input_select.daytime') == 'Evening' -%}
135
{% elif states('input_select.daytime') == 'Night' -%}
80
{% endif %}
- name: Daytime Light Color Temp
unique_id: mysensor0009
state: >-
{% if states('input_select.daytime') == 'Morning' or states('input_select.daytime') == 'Daytimes' -%}
180
{% elif states('input_select.daytime') == 'Evening' -%}
350
{% elif states('input_select.daytime') == 'Night' -%}
480
{% endif %}
- binary_sensor:
- name: Shutter Operation To Cold Or Windy
unique_id: binary_sensor0001
device_class: safety
state: >-
{{
states('sensor.outdoor_temperature') | float(0.0) <= -10.0
or
state_attr('weather.home', 'wind_speed') | float(0.0) > 50.0
}}
- name: Christian Schwarzgruber Alarm
unique_id: binary_sensor0003
state: >-
{{
not is_state('input_datetime.christian_schwarzgruber_next_alarm', 'unavailable')
and
(as_timestamp(states('input_datetime.christian_schwarzgruber_next_alarm')) - 60) | timestamp_custom('%H:%M')
== as_timestamp(states('sensor.date_time_iso')) | timestamp_custom('%H:%M')
and
states('person.christian_schwarzgruber') == 'home'
and
states('input_boolean.christian_schwarzgruber_alarm_set') == 'on'
}}
- name: Update Available Sensor
unique_id: binary_sensor0005
device_class: update
state: >-
{{
states('binary_sensor.home_assistant_versions_update_available') == 'on'
or
states('sensor.hacs') | int(0) >= 1
}}