Hi everyone, I am a newbie in OpenHAB, and I have something don’t understand when I want to add a MQTT Thing
Following this, there are 6 steps to add a Thing to OpenHAB, and step 3 is add Thing and configure. And I can configure by add a .things file with syntax: Thing <binding_id>:<type_id>:<thing_id> “Label” @ “Location” [ ]. But I wondering, with MQTT what are binding_id, type_id, thing_id? Can you write a example for me?
When I read this to add a MQTT Thing, I add a file services/mqtt.cfg with content: “m2m-eclipse.url=tcp://m2m.eclipse.org:1883” and then I add and configure files in items folder and sitemap folder. But according this, I just add a Item not a Thing? I’m wondering about this? Can somebody explain for me? Or OpenHAB do not support add MQTT Things?
The binding name and version tell me its a legacy binding. Only version 2 or above will ever support a thing and some of them don’t either as there isn’t a need for them always.
I have SONOFF devices, which I can contact and command by items I created.
Now as I have alot of those devices in my house, I want to combine all the different capabilities of a device into a THING. I am aware that a THING is not needed for MQTT, but I want to have for all my devices that really excist a THING defined.
Can somebody tell me, how the THING declaration must look for a MQTT device?
My aim is to have in the paper UI under things all physical devices and that I can go look there what channels (capabilities), each of the devices has.
This I want to write into the sonoff.things, but I have no clue, what to write into the binding part…
PLEASE HELP? And yes I know that things are not needed, but I want a proper structure and want to see under things in the paper UI all my physical devices.
The MQTT binding is a 1.9x version binding that is compatible with the 2.x openHAB
Unfortunately the MQTT binding doesn’t support things. I don’t think you will be able to achieve that.
There will be a 2.x version of the MQTT binding eventually. This will support things.
But the items themself I have working since a year. So that is not an issue. I tried to combine/group MQTT into THINGS, which is not working due to the fact that 1.9 bindings do not support THINGS (as simple as that).
Another idea of me was now to integrate the MQTT SONOFF devices in the CCU2 (then I would have things), but the MQTT support is so poor and the community behind is like 1 developper, that I dropped that idea. Also the useage of HTML binding makes no sense for me. (delay/NW traffic).
=> Let’s see what happens first… an updated MQTT Binding or another way (MQTT to xxx converter)
=> Meanwhile I group my “channels items” in an item file
My question was already answered here, thanks to you all.