blozzy
(BLOZZY)
September 25, 2022, 2:55pm
1
Hi,
i would like to track the max Wind within 24 hrs from a Bresser 433 RTL, so far, HA is receiving the value, but if i try, to figure out the max value on a day it fails with expected title failure message. Here is my YAML;
mqtt:
- name: "windmax_outside_bresser61"
state_topic: rtl_433/bresser61/wind_max_m_s
value_template: “{{ value | round(2) | float }}”
icon: mdi:windsock
unit_of_measurement: "ms"
- platform: statistics
name: "max wind over last 24 hours"
entity_id: sensor.windmax_outside_bresser61
state_characteristic: value_max
max_age:
hours: 24
sampling_size: 500
precision: 1
Thank you
tom_l
September 26, 2022, 1:28am
2
Why are you putting the statistics sensor under the mqtt integration?
The other item you have under mqtt is not correct either.
it should be something like this:
in configuration.yaml:
mqtt:
sensor:
- name: "windmax_outside_bresser61"
state_topic: rtl_433/bresser61/wind_max_m_s
value_template: “{{ value | round(2) | float }}”
icon: mdi:windsock
unit_of_measurement: "ms"
sensor:
- platform: statistics
name: "max wind over last 24 hours"
entity_id: sensor.windmax_outside_bresser61
state_characteristic: value_max
max_age:
hours: 24
sampling_size: 500
precision: 1
If you already have something like this in your configuration.yaml file:
sensor: !include sensors.yaml
Then put the statistics sensor in there instead.
sensors.yaml
- platform: statistics
name: "max wind over last 24 hours"
entity_id: sensor.windmax_outside_bresser61
state_characteristic: value_max
max_age:
hours: 24
sampling_size: 500
precision: 1
blozzy
(BLOZZY)
September 26, 2022, 5:28am
3
hi, it is still separated in files, but merged for the topic
tom_l
September 26, 2022, 5:41am
4
How were we supposed to know that?
blozzy
(BLOZZY)
September 26, 2022, 5:54am
5
thats not relevant for the syntax or problem, if the declaration is in one conf.yaml or not. thx
tom_l
September 26, 2022, 6:33am
6
It very much is relevant. If you post invalid config the first thing someone is going to do is waste their time correcting it for you. Like I did.