Hello,
I am running openHAB 2.4.0-1 (Release Build) on my RPi and I got some issues with adding my tasmota devices from mqtt. The switches are working fine, but I can’t get the sensors running. The logs are telling, what openhab is getting from mqtt. It seems like it can’t decode the json from the topics. I followed multiple tutorials, but it just doesn’t work. Could somebody please help me with that?
This topic looks similar, but I don’t see any difference to my configuration: [SOLVED] [MQTT 2.4] tasmota switch stop working after adding channel for temperature sensor
These are my logs regarding the issue:
2019-08-11 15:10:36.697 [WARN ] [l.generic.ChannelStateTransformation] - Transformation service JSONPATH for pattern $.BME280.Temperature not found!
2019-08-11 15:10:36.703 [WARN ] [eneric.internal.generic.ChannelState] - Incoming payload '{"Time":"2019-08-11T14:10:36","BME280":{"Temperature":30.9,"Humidity":36.5,"Pressure":996.2},"PressureUnit":"hPa","TempUnit":"C"}' not supported by type 'NumberValue'
2019-08-11 15:12:39.771 [WARN ] [l.generic.ChannelStateTransformation] - Transformation service JSONPATH for pattern $.ENERGY.Total not found!
2019-08-11 15:12:39.778 [WARN ] [eneric.internal.generic.ChannelState] - Incoming payload '{"Time":"2019-08-11T14:12:39","ENERGY":{"TotalStartTime":"2019-07-23T19:31:50","Total":0.112,"Yesterday":0.009,"Today":0.003,"Period":0,"Power":0,"ApparentPower":0,"ReactivePower":0,"Factor":0.00,"Voltage":0,"Current":0.000}}' not supported by type 'NumberValue'
These are my Things inside Bridge MQTTBroker:
// computer
Thing mqtt:topic:computer "Licht am Schrank" @ "MQTT" {
Channels:
Type switch : switch "Schalter" [
stateTopic="stat/computer/POWER",
commandTopic="cmnd/computer/POWER",
on="ON",
off="OFF"
]
Type number : power "Energie [%.1f kWh]" [
stateTopic="tele/computer/SENSOR",
transformationPattern="JSONPATH:$.ENERGY.Total"
]
}
// bme1
Thing mqtt:topic:bme1 "Zimmer BME280" @ "MQTT" {
Channels:
Type number : temp "Temperatur [%.1f °C]" [
stateTopic="tele/bme1/SENSOR",
transformationPattern="JSONPATH:$.BME280.Temperature"
]
Type number : humi "Luftfeuchtigkeit [%.1f %%]" [
stateTopic="tele/bme1/SENSOR",
transformationPattern="JSONPATH:$.BME280.Humidity"
]
}
And for last the Items:
Number:Temperature ZimmerTemp "Temperatur" <temperature> (Zimmer) {channel="mqtt:topic:bme1:ZimmerTemp"}
Number ZimmerHumi "Luftfeuchtigkeit" <humidity> (Zimmer) {channel="mqtt:topic:bme1:ZimmerHumi"}
Switch ComputerSchalter "Computer" <light> (Zimmer) ["Switchable"] {channel="mqtt:topic:computer:switch"}
Number ComputerVerbrauch "Computer" <energy> (Zimmer) {channel="mqtt:topic:computer:power"}