RaspBee binding compatibility

Hi!
Could you pls make the compiled result available?!!
Could you run all on the same hardware?
Thanks
Micahel

Hi Peter,

can you please share a link that enabled you to compile the sources?
Thanks
Michael

Hi!

Does anyone know how to define as static the deCONZ ip address? The problem I have is that deCONZ are connecting to my static IP address after boot. As deCONZ boots quicker than OpenHAB2, this one is addressing a random IP.

Thanks!

Hi again,

the problem remains and I dont know what more to do. I have the problem that deCONZ and OpenHAB2 are connected by default to the same IP address but with different ports. I get this error when I try to configure the “Raspbee controller” with Hue Binding at Paper UI:

2017-07-28 02:23:20.459 [INFO ] [binding.hue.handler.HueBridgeHandler] - Creating new user on Hue bridge 192.168.42.100 - please press the pairing button on the bridge.
2017-07-28 02:23:20.471 [WARN ] [binding.hue.handler.HueBridgeHandler] - Failed creating new user on Hue bridge
java.io.FileNotFoundException: http://192.168.42.100/api/
at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1872)[:1.8.0_131]
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1474)[:1.8.0_131]
at org.eclipse.smarthome.binding.hue.internal.HttpClient.doNetwork(HttpClient.java:62)[189:org.eclipse.smarthome.binding.hue:0.9.0.201707190720]
at org.eclipse.smarthome.binding.hue.internal.HttpClient.post(HttpClient.java:36)[189:org.eclipse.smarthome.binding.hue:0.9.0.201707190720]
at org.eclipse.smarthome.binding.hue.internal.HueBridge.link(HueBridge.java:759)[189:org.eclipse.smarthome.binding.hue:0.9.0.201707190720]
at org.eclipse.smarthome.binding.hue.internal.HueBridge.link(HueBridge.java:750)[189:org.eclipse.smarthome.binding.hue:0.9.0.201707190720]
at org.eclipse.smarthome.binding.hue.handler.HueBridgeHandler.createUserOnPhysicalBridge(HueBridgeHandler.java:340)[189:org.eclipse.smarthome.binding.hue:0.9.0.201707190720]
at org.eclipse.smarthome.binding.hue.handler.HueBridgeHandler.createUser(HueBridgeHandler.java:328)[189:org.eclipse.smarthome.binding.hue:0.9.0.201707190720]
at org.eclipse.smarthome.binding.hue.handler.HueBridgeHandler.onNotAuthenticated(HueBridgeHandler.java:314)[189:org.eclipse.smarthome.binding.hue:0.9.0.201707190720]
at org.eclipse.smarthome.binding.hue.handler.HueBridgeHandler$1.run(HueBridgeHandler.java:139)[189:org.eclipse.smarthome.binding.hue:0.9.0.201707190720]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)[:1.8.0_131]
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308)[:1.8.0_131]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)[:1.8.0_131]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)[:1.8.0_131]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[:1.8.0_131]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)[:1.8.0_131]
at java.lang.Thread.run(Thread.java:748)[:1.8.0_131]

I think that the “http://IP/api” is the problem because the 2 programs are trying to address themselves the same. I dont know how to do for avoid that. Trying to add two different static IPs doesnt solve anything, deCONZ address all of the static IP automatically.

Thanks in advance if somebody know what to do.

I was able to add deCONZ as a hue bridge(thing), but only manualy with IP:port (as I use a non default port), then I was able to add lights (as things), again manually with their IDs. Everything is showing as ONLINE on the Paper UI Things section.
I was able to add Items for the lights (Color Temperature, Brightness) and all the controls are shown on the Control section, but none of the controls make any changes to the lights.

I have created a Deconz binding for real-time sensors and buttons (everything else is supported by the Hue binding already):

Cheers,
David

2 Likes

Hi, this sounds very cool… do you have any idea when the new bingings will be availible in openhab2 or do I need to build my own release to get access to your changes?
Actually I am using fhem and want to switch to openhab, therefore I am not very familiar with openhab…

Thanks and best regards
Jens

The binding is done and is waiting for a second review round. The guys are just busy at the moment, I guess.
But I’m very sure it will be in for OH 2.4 (this year).

You can download the addon jar file from

https://openhab.jfrog.io/openhab/libs-pullrequest-local/org/openhab/binding/org.openhab.binding.snapcast/2.4.0-SNAPSHOT/

Search for the one that has “deconz” in it.

Great! Thanks, I will try to get it running :slight_smile:

Thanks for your effort! I already installed your Snapcast binding. Afterwards i tried to search for new things, without any finding. Do i have to configure your binding or do something else?
I am using the openHabian Image with deconz/raspbee installed. I already connected a working xiaomi door sensor to deconz and want to use it with openHab.

Thanks for your work!

@David_Graeff Do you have any plans for additional sensor types like humidity and air pressure?

I don’t have those sensor types so not planning to add anything at the moment.

Cheers, David

I have no clue how your binding works but do you really need to manually add each sensor Type? As deconz is already providing all the Information, couldn’t you make some kind of dynamic classes in your binding based on the deConz information? Maybe this thought is just to simple and therefore not working but I just wanted to mention.

Apart from this, is the only reason for not integrating the lights that you can already access them via the Hue Binding? The benefit of having the lights in your binding would be the realtime external change information (i. e. zigbee wall switches which could trigger rules).

Yes the reason for not supporting lights is the original hue binding, I don’t want to duplicate code. The devonz binding is more like a temporary thing until rasbees are directly supported by the ZigBee binding (which might take a few years).

I still hope that Philips adds a websocket connection to their API, that was the two bindings could be united.

It is not possible to dynamically generate channels without applying a ton of heuristics. And then the cleaner approach is just to add the sensor in question, I mean it is a finite amount of devonz supported sensors.

Cheers David

Hi @David_Graeff

I have a bunch of Xiaomi ZigBee sensors/switches already paired with my deconz/raspbee, but they are actually not (completely) supported in your new binging. What do you exactly need to add the sensors/values to your deconz binding? I already got the responses from the raspbee REST API for my sensors, except my water detection sensor, which cannot be paired in the moment, but should be fixed in deconz 2.05.51…

I also took a short look into your binding source code and perhaps I can try to help adding my sensors, if this is okay for you? Java programming is some time ago, but maybe I can help :wink:

Thanks and best regards.

I know we’ve had this discussion in the past, but if someone was to actually spend some time to work on it, it would likely take a few days - not years. Of course, if no-one spends any time, then yes, it will be years or longer :wink:

The majority of code is written, it just needs someone to pick it up and try get it working reliably.

If there’s someone out there interested, then please feel free to contact me, or discuss on this issue -:

That’s the issue. So far nobody jumped in, and I have the mqtt subsystem to maintain, busy with extending the hue emulation to the state that even the original hue app can’t tell any difference, and writing a new binding for coap.

It was faster for me to write the deconz binding than to dive into the zigbee code base.

It would help a lot of you put together a small instruction list for building, debugging and where you think that unstable code is located or more testing is required.

Time :smiley: You can help by creating a pull request where you add all the missing sensor things and channels to the thing xml file already and add missing fields to the sensor value class.

Sure - I was simply trying to advertise the issue here so that people are aware of it.

Maybe - maybe not…

Just to reiterate (again, for anyone who wants to look at this) that you don’t need to jump in to the whole codebase. The driver fundamentally works, and is quite self contained. You had thought that the writing of the code would take a LONG time (I think you said many man months of work when we discussed this on GH) and really I don’t think this is the case.

Please see the issue I referenced above. I’m happy to answer questions etc if someone wants to look at it - that was the purpose of this issue.

I’m not sure where the “unstable” code is as it was a long time ago that I looked at this. However, there are only a couple of Java files that form the main part of the driver (yes - that really is 2 files, and under 1000 lines of code!), so it’s a pretty small codebase (there are maybe another dozen or so that are used for formatting frames, but I doubt the issue is there).

Hi Jens,

I am happy to read someone else tries the same. Currently, I am struggling with getting xiaomi aqara things recognized by deconz binding in OH. Of course without success, then I found your comment while looking for helpful hints. For now it seems, the best way for me is to use http binding until someone implements the additional sensor types (water, window/door).

Regards,
Marek

If you follow github a little, you’ll notice that sensor types are added like crazy recently. I recommend the binding instead of http for real-time updates. Polling is never a good solution, but you probably know that.

Cheers, David