Trying to get a D1-Mini working with a DHT11 temperature/humididty sensor to send info to openhab and display on the HABPanel correctly.
I am able to send the info from the DHT11 to open hab and I can see it in the logs coming in, however on HABPanel it is not easy to read and I cannot figure out how to transform the incoming data to just display temperature or humidity.
For example, I added a “Selection” widget (only one I could get to do anything) and it displays
{“Time”:“2019-08-06T18:02:19”,“DHT11”:{“Temperature”:26.0,“Humidity”:64.0},“TempUnit”:“C”}
How do I get this to just display the current Temperature and Humidity only? Is this done via Value Transformation?
depends on your JSON format
if using tasmota it should be something like
JSONPATH:$.BME280.Temperature
search for name of your sensor in mqtt message
and you need two channels, one for humidity and one for temperature
I have for example three
Channels:
Type number : temperature "Temperature" [ stateTopic="home/diningroom/climate/tele/SENSOR", transformationPattern="JSONPATH:$.BME280.Temperature" ]
Type number : humidity "Humidity" [ stateTopic="home/diningroom/climate/tele/SENSOR", transformationPattern="JSONPATH:$.BME280.Humidity" ]
Type number : pressure "Pressure" [ stateTopic="home/diningroom/climate/tele/SENSOR", transformationPattern="JSONPATH:$.BME280.Pressure" ]
All kick back the same error from the log of openhab
Transformation service JSONPATH for pattern $.BME280.Temperature not found!
Transformation service JSONPATH for pattern $.DHT11.Temperature not found!
Transformation service JSONPATH for pattern $.barnrelay1.Temperature not found!