I have an ESP8266 with a ds18b20 sensor on it. Every ten seconds it sends an MQTT message with the temperature in fahranheit. Just a number (in a string) like this: “85.24”. No problem getting Home Assistant to display the sensor:
I wanted to add more ds18b20 sensors to the hardware and I changed my ESP code to send the data in JSON format:
{"ds0":{"Temperature":85.00}}
And in Home Assistant:
- platform: mqtt
name: "TempProbe"
state_topic: "ds18b20x2/temperature"
value_template: "{{ value_json['ds0'].Temperature }}"
force_update: true
Now the data is displayed thus:
Here’s my question. It’s the same data (84.00). Why is there a resolution difference from the raw data and the JSON data, and can I control it?