Sonoff Zigbee coordinator using MQTT Broker

Hi

I am trying to set up a Sonoff/Tasmota Zigbee Bridge with OH3. I have many Sonoff/Tasmota power switches working with MQTT Broker/Mosquito just fine. I flashed the Sonoff bridge with both Tasmota files and it paired nicely with a Sonoff Zigbee temperature and humidity senor. Using the Tasmota console I can see the MQTT messages sent out. I am able to use MQTT-Spy and received the following from the MQTT server.
tele/tasmota_9C813D/SENSOR = {“ZbReceived”:{“0xAA13”:{“Device”:“0xAA13”,“Temperature”:30.14,“Endpoint”:1,“LinkQuality”:107}}}
I have JSONPath Transformation installed.
I set up a thing “Sonoff Zigbee Coordinator” and it shows “online”. I then added a channel to received the following MQTT State Topic
“tele/tasmota_9C813D/SENSOR”
and added the following in the “Incoming Value Transformations”
“JSONPATH:$.ZbReceived.Device.Temperature”
I then linked an item to this channel to display the temperature but all I see is “NULL”
The item is type “number” and point.measurement
Can someone provide a hint as to what I’m doing wrong?

Thank you in advance

You need to create a ‘Generic MQTT thing’. The other things looks ok. What kind of thing did you create?

Nope.

{"ZbReceived":{"0xAA13":{"Device":"0xAA13","Temperature":30.14,"Endpoint":1,"LinkQuality":107}}}

Path is ZbReceived → 0xAA13 → Temperature

1 Like

GREAT !!! thanks very much

“Path is ZbReceived → 0xAA13 → Temperature”

Fixed it!!

One last thing, how do I convert the temperature from C to F ?

I have read and tried a number of openhab 2 methods but they don’t work using the UI

Thanks

Unlike Zigbee, MQTT binding doesn’t yet know anything about units. And in this case, your Temperature data has arrived without units anyway.

So you’re going to have to do work.
If you can get your data into a Number:Temperature type Item, you can get auto-conversion to whatever unit you want… To do that properly, you’ll need to add the units (that you know the data comes in) yourself.
Simplest way is to create a Number:Temperature Item, and link it to your MQTT channel with a transformation profile. Use a JS javascript profile that just adds the string " °C" to the raw data.
When that is working, you can give any suitable unit in the Item’s state presentation / pattern metadata, and openHAB will convert for you.