General questions on first GW and sensor setup
Crumpy10 last edited by
This is my first post so hello to everyone, I have been a lurker for some time and have just setup my first ethernet GW with a DHT11 sensor on a node. Both running on Arduino uno clones. I have an existing Openhab setup thats been running for a couple of years now but decided there were a lot of Mysensor projects that I wanted to try!
Although I have the GW setup with the Node and they are talking to each other, and Openhab discovered both the temp and humidity sensor, I can not get the data to display on my sitemap. So I have a few questions-:
Do I need to have a manual things file as below?
Do I need to specify in the Arduino sketch a Node ID as below or does openhab assign them?
Below are my .items , sitemap and openhab thing screenshot. Has anyone done a recent Openhab 2.4 install with an ethernet gateway that can see any mistakes?
Hope someone can help, I am so close but not quite there.... I am no programmer so go easy on me!
There is no need to. You may configure your devices in PaperUi or in the files (or use both types)
No. The ID is assigned automatically by the binding. But you are free to define one in the sketch.
The screenshot from PaperUi with the things looks good. What is the problem? Are there any updates in the control view from Openhab? What does the log say?
Crumpy10 last edited by
Thanks for the reply.
OK So if I can use a mixture of either self discovery and files thats fine BUT as soon as I un-comment the sensors in mysensors.items the thing sensors double up in Openhab? See below?
Openhab discovered the highlighted sensors (only after I reset the sensor node!) and then when I ticked the discovered sensors it added the extra two sensors not highlighted?!? Weird as I have only one DHT11 sensor... Any ideas whats going on?
I started out this evening by deleting the sensors and the gateway in openhab, restarted openhab. I then added the gateway, reset the node which added the 4 things.
Now I am getting data on the sitemap for the first time! Eh.....
Should I have each sensor doubled up then? and I didnt link any channels either....
Now I am confused...
@crumpy10 Well, that may seem confusing, but this is how the binding does work.
You may create as much things as you like and it doesn't matter if you create those things via PaperUi or the text files. If node id and child Id do match on an incoming messages the thing gets updated.
Discovery by Openhab is only possible if and when the node presents itself. In most MySensors sketches this is done on initialization of the code. This is why a reboot of the node is needed for discovery. There is no list of known nodes (in the gateway) that the binding may read out.
There is some code in the binding that should prevent the discovery (inbox) of already known things but that doesn't work in some cases. I've the same problem with my sonos things which get discovered all the time although I've already configured them via text files.
The discovered things in inbox will disappear after a timeout.