hello, i have a problem with 1 sensor wind from Oregon. In my log i have this :
2020-08-12 20:45:05 DEBUG (MainThread) [homeassistant.components.mqtt] Received message on rflink/Oregon_Wind-1AFE: b'{"WINDIR":0003,"WINGS":4.6,"WINSP":4.6,"BAT":"OK"}
Your sensor appears to be putting out JSON format data to HA… do you have an entity for this? You can look in dev/states to verify the entity name if it exists.
For example, I have an arduino nano plugged to my pi usb, which sends data to HA as a serial_sensor. The resulting entity, sensor.serial_sensor has JSON data for it’s state, which looks exactly like this {"battery":912,"mains":854,"bell":11,"brick":1019}. To use this JSON formatted data in HA, you can use templates that look like this:
- platform: template
sensors:
mains_power:
friendly_name: 'Mains Power'
value_template: >
{% set level = state_attr('sensor.serial_sensor','mains') | int %}
{% if level >= 500 %}
on
{% else %}
off
{% endif %}
This gives me an entity called sensor.mains_power, which turns on or off depending on the value. I add 3 more templates like that to use battery, bell, and brick data as well. If I want to read a floating point number like you would have to do, it would look like this: