-
Notifications
You must be signed in to change notification settings - Fork 52
/
Copy pathtemplate.yaml
131 lines (124 loc) · 4.56 KB
/
template.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
# Compos
- trigger:
- platform: mqtt
topic: "sensor/rtl_433_attic"
payload: "True"
value_template: "{{ value_json.model == 'Acurite-00275rm' and value_json.id == 16725 }}"
sensor:
- name: "Compost External Temperature"
state: "{{ trigger.payload_json.temperature_F | float | round(2) }}"
unit_of_measurement: "°F"
device_class: temperature
- name: "Compost External Humidity"
state: "{{ trigger.payload_json.humidity | float | round(2) }}"
unit_of_measurement: "%"
device_class: humidity
- name: "Compost Internal Temperature"
state: "{{ trigger.payload_json.temperature_1_F | float | round(2) }}"
unit_of_measurement: "°F"
device_class: temperature
binary_sensor:
- name: "Compost Battery"
state: "{{ trigger.payload_json.battery_ok != 1 }}"
device_class: battery
# Deep Freeze
- trigger:
- platform: mqtt
topic: "sensor/rtl_433_attic"
payload: "True"
value_template: "{{ value_json.model == 'Acurite-Tower' and value_json.id == 14574 }}"
sensor:
- name: "Deep Freeze Temperature"
state: "{{ trigger.payload_json.temperature_F | float | round(2) }}"
unit_of_measurement: "°F"
device_class: temperature
- name: "Deep Freeze Humidity"
state: "{{ trigger.payload_json.humidity | float | round(2) }}"
unit_of_measurement: "%"
device_class: humidity
binary_sensor:
- name: "Deep Freeze Battery"
state: "{{ trigger.payload_json.battery_ok != 1 }}"
device_class: battery
# Rain
# - trigger:
# - platform: mqtt
# topic: "sensor/rtl_433_attic"
# payload: "True"
# value_template: "{{ value_json.model == 'Oregon-PCR800a' and value_json.id == 58 }}"
# sensor:
# - name: "Rain Rate"
# state: "{{ trigger.payload_json.rain_rate_in_h | float | round(2) }}"
# unit_of_measurement: "in/h"
# - name: "Rain Total"
# state: "{{ trigger.payload_json.rain_in | float | round(3) }}"
# unit_of_measurement: "in"
# - name: "Rain Battery OK"
# state: "{{ trigger.payload_json.battery_ok == 1 }}"
# device_class: battery
# Neighbor Rain
# - trigger:
# - platform: mqtt
# topic: "sensor/rtl_433_attic"
# payload: "True"
# value_template: "{{ value_json.model == 'Acurite-Rain899' and value_json.id == 11516 }}"
# sensor:
# - name: "Neighbor Rain Total"
# state: "{{ trigger.payload_json.rain_in | float | round(5) }}"
# unit_of_measurement: "in"
# Neighbor 5in1 wind / temp
- trigger:
- platform: mqtt
topic: "sensor/rtl_433_attic"
payload: "True"
value_template: "{{ value_json.model == 'Acurite-5n1' and (value_json.message_type == 56 or value_json.message_type == 49) }}"
sensor:
- name: "Neighbor 5in1 Wind"
state: "{{ trigger.payload_json.wind_avg_mi_h | float | round(2) }}"
unit_of_measurement: "mph"
device_class: wind_speed
# Neighbor 5in1 rain
- trigger:
- platform: mqtt
topic: "sensor/rtl_433_attic"
payload: "True"
value_template: "{{ value_json.model == 'Acurite-5n1' and value_json.message_type == 49 }}"
sensor:
- name: "Neighbor 5in1 Rain Total"
state: "{{ trigger.payload_json.rain_in }}"
unit_of_measurement: "in"
# Outdoor Weather Wittime (back porch on top of column)
- trigger:
- platform: mqtt
topic: "sensor/rtl_433_attic"
payload: "True"
value_template: "{{ value_json.model == 'GT-WT03' and value_json.id == 0 and value_json.channel == 1 }}"
sensor:
- name: "433 Weather Temperature"
state: "{{ trigger.payload_json.temperature_F | float | round(2) }}"
unit_of_measurement: "°F"
device_class: temperature
- name: "433 Weather Humidity"
state: "{{ trigger.payload_json.humidity | float | round(2) }}"
unit_of_measurement: "%"
device_class: humidity
binary_sensor:
- name: "433 Weather Battery"
state: "{{ trigger.payload_json.battery_ok != 1 }}"
device_class: battery
- trigger:
# - platform: mqtt
# topic: "sensor/rtl_433_office"
# payload: True
# value_template: "{{ value_json.model == 'Smoke-GS558' and value_json.id == 13751 and value_json.code == '06b6fd' }}"
- platform: mqtt
topic: "sensor/rtl_433_attic"
payload: "True"
value_template: "{{ value_json.model == 'Smoke-GS558' and value_json.id == 13751 and value_json.code == '06b6fd' }}"
sensor:
- name: "433 Motion Master Bathroom"
state: "{{ now() }}"
binary_sensor:
- name: "433 Motion Master Bathroom"
state: "{{ 1==1 }}"
device_class: motion