Fixing previous day rainfall sensor and automations
This commit is contained in:
parent
189e4d87a4
commit
fb5bc0583a
|
@ -448,8 +448,7 @@
|
|||
- service: script.text_notify
|
||||
data:
|
||||
who: all_ios
|
||||
message: The Garden has received {{ states('sensor.previous_rainfall') | int
|
||||
| round(2) }} inches of rain in the last 48 hours.
|
||||
message: The Garden has received {{ states('sensor.previous_rainfall') | round(2) }} inches of rain in the last 48 hours.
|
||||
mode: single
|
||||
- id: '1627078744808'
|
||||
alias: buy more xlm
|
||||
|
|
|
@ -244,7 +244,7 @@ sensor:
|
|||
value_template: "{{ state_attr('sensor.daily_rainfall_in', 'last_period') }}"
|
||||
previous_rainfall:
|
||||
friendly_name: "Past 48h Rainfall"
|
||||
value_template: "{{ states('sensor.daily_rainfall_in') | int + state_attr('sensor.daily_rainfall_in', 'last_period') | int }}"
|
||||
value_template: "{{ states('sensor.daily_rainfall_in') | float + state_attr('sensor.daily_rainfall_in', 'last_period') | float }}"
|
||||
lightning_warning:
|
||||
friendly_name: "Lightning Warning"
|
||||
value_template: >-
|
||||
|
|
Loading…
Reference in New Issue