deCONZ hardware support

Xiaomi, Ikea TRÅDFRI, Philips Hue and more.

Moderator: leecollings

eiaro
Posts: 12
Joined: Monday 22 May 2017 12:30
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Norway
Contact:

deCONZ hardware support

Post by eiaro »

I have a deCONZ (RaspBee / ConBee) and I need to interface with stuff that PHue can't/won't support. The deCONZ is developed with open source, and the hardware isn't very expensive, so I think it is something that should be supported by Domoticz.

I have 3 options:
  • Modify and adapt the existing Philips Hue hardware. Actually have the deCONZ working with PHue hardware as we speak and a PR is possible. To get the real advantages from deCONZ it would need a bigger rewrite however.
  • Make a Phyton plugin. Not really feasible as callbacks and threads are unavoidable.
  • Create a new hardware code for just deCONZ. I would add a few libraries to the code if I was to go this route.
Is there any interest for this? If not I'll just fork off and make it for myself.

PS! I tried to get access to the Slack, but so far no invite
Dahl1632
Posts: 8
Joined: Monday 26 June 2017 21:03
Target OS: OS X
Domoticz version:
Contact:

Re: deCONZ hardware support

Post by Dahl1632 »

Yeah! I just got my ConBee stick. Right now it's running on another Raspberry and i use homebridge to get it working in my home. The sad thing is that it isn't talking with domoticz.. I tried to use their REST API to send http commands from domoticz to deconz/conbee but its a bit tricky...
User avatar
remb0
Posts: 499
Joined: Thursday 11 July 2013 22:21
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: The Netherlands
Contact:

Re: deCONZ hardware support

Post by remb0 »

can it be used in zigbee2mqtt? then the support would be a lot easier.
eiaro
Posts: 12
Joined: Monday 22 May 2017 12:30
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Norway
Contact:

Re: deCONZ hardware support

Post by eiaro »

Dahl1632 wrote: Monday 08 October 2018 21:58 The sad thing is that it isn't talking with domoticz..
Just to tease you... One of my IKEA Motion sensors.
Image
remb0 wrote: Monday 08 October 2018 23:10 can it be used in zigbee2mqtt? then the support would be a lot easier.
zigbee2mqtt is home-assistant coined. Home Assistant has "native" support for deCONZ already, so doubt much work is put into zigbee2mqtt for it. Do you suggest we switch to Home Assistant? ;-)
eiaro
Posts: 12
Joined: Monday 22 May 2017 12:30
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Norway
Contact:

Re: deCONZ hardware support

Post by eiaro »

Here is a screen from the log. There is still ways to go though, and I'm impressed by the lack of communication between the developers.
Image
User avatar
remb0
Posts: 499
Joined: Thursday 11 July 2013 22:21
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: The Netherlands
Contact:

Re: deCONZ hardware support

Post by remb0 »

of course not. zigbee2mqtt is a project. you can use it in home-assistant. BUT also very easy in domoticz:
http://www.domoticz.com/forum/viewtopic ... 65&t=24975
I think even easier :P

eiaro wrote: Wednesday 10 October 2018 11:58
Dahl1632 wrote: Monday 08 October 2018 21:58 The sad thing is that it isn't talking with domoticz..
Just to tease you... One of my IKEA Motion sensors.
Image
remb0 wrote: Monday 08 October 2018 23:10 can it be used in zigbee2mqtt? then the support would be a lot easier.
zigbee2mqtt is home-assistant coined. Home Assistant has "native" support for deCONZ already, so doubt much work is put into zigbee2mqtt for it. Do you suggest we switch to Home Assistant? ;-)
eiaro
Posts: 12
Joined: Monday 22 May 2017 12:30
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Norway
Contact:

Re: deCONZ hardware support

Post by eiaro »

Image

To me it seems easier to buy the gateway and just connect Domoticz to it. But thats just me, I work with protoboards and servers and have no fun doing it at home and I'm more than happy with this solution that even the Wife can setup.

I might release a PR with basic functionality soon-ish.

PS! The zigbee2mqtt is based on zigbee-shepherd, and it has bad support for ZLL. So only devices that is ZHA (or those times ZLL share the same ZCL that ZHA) will be compatible - mostly. Athom Homey has the same issue.
eiaro
Posts: 12
Joined: Monday 22 May 2017 12:30
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Norway
Contact:

Re: deCONZ hardware support

Post by eiaro »

PR for deCONZ support is submitted.
User avatar
remb0
Posts: 499
Joined: Thursday 11 July 2013 22:21
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Location: The Netherlands
Contact:

Re: deCONZ hardware support

Post by remb0 »

Nice combining powers ;)
eiaro wrote: Friday 12 October 2018 12:32 PR for deCONZ support is submitted.
Thorgal789
Posts: 815
Joined: Wednesday 15 August 2018 14:38
Target OS: -
Domoticz version:
Contact:

Re: deCONZ hardware support

Post by Thorgal789 »

This PR will manage sames devices than their REST plugin ? (ATM or in the future)
It mean Philips/ikea/osram/Xiaomi/Jiawen/ ect ...
Because I m reading the code, and it seem some fonctions are missing for the moment, for exemple Humidity sensor or plug.

BTW, thx a lot, I think I will use it soon.
eiaro
Posts: 12
Joined: Monday 22 May 2017 12:30
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Norway
Contact:

Re: deCONZ hardware support

Post by eiaro »

Yes, the goal is to support all devices deCONZ support. I might need some help as I don't have all the sensors myself and can't really see how they behave in Domoticz.

And you are right, currently there isn't much sensors in the PR, and the reason for this is that the update on the sensors I have is too slow with using only polling. Imagine going to the toilet and the motion sensor isn't read until the next poll. Or pressing a remote switch and it's not enacting until 15 seconds.

I am working on adding the websocket connection that will give you instant sensor updates in Dom. This will give good response on motion, remotes and switches.
couchadonis
Posts: 4
Joined: Sunday 23 September 2018 10:55
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Germany
Contact:

Re: deCONZ hardware support

Post by couchadonis »

I would really be very happy if deCONZ could be integrated into Domoticz! Domoticz is still new territory for me, but I've been using deCONZ for a while now (<90 devices). It's very stable.

What I did not understand yet (beginner question): What does "PR" mean? Does that mean I can already integrate deCONZ as hardware?
eiaro
Posts: 12
Joined: Monday 22 May 2017 12:30
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Norway
Contact:

Re: deCONZ hardware support

Post by eiaro »

couchadonis wrote: Sunday 14 October 2018 13:36 I would really be very happy if deCONZ could be integrated into Domoticz! Domoticz is still new territory for me, but I've been using deCONZ for a while now (<90 devices). It's very stable.
Yeah. Very stable and very much in motion to support new devices.
couchadonis wrote: Sunday 14 October 2018 13:36 What I did not understand yet (beginner question): What does "PR" mean? Does that mean I can already integrate deCONZ as hardware?
PR means "pull request", and it means there is code made by someone outside the team, that the team must review and accept into the Domoticz code. It's a process... :)
couchadonis
Posts: 4
Joined: Sunday 23 September 2018 10:55
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Germany
Contact:

Re: deCONZ hardware support

Post by couchadonis »

Got it. :oops: Nothing I have't heard before, but I didn't know the acronym yet. ;) Well, then I'll wait for the things to come. Hopefully...

Thank you for your prompt reply!
Thorgal789
Posts: 815
Joined: Wednesday 15 August 2018 14:38
Target OS: -
Domoticz version:
Contact:

Re: deCONZ hardware support

Post by Thorgal789 »

You have cancel your PR ? Abandoned project ?
eiaro
Posts: 12
Joined: Monday 22 May 2017 12:30
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Norway
Contact:

Re: deCONZ hardware support

Post by eiaro »

Not abandoned, it just took too long to get it included and it ended up crashing with another project.
MattiasW
Posts: 1
Joined: Friday 07 December 2018 12:26
Target OS: Linux
Domoticz version:
Location: Sweden
Contact:

Re: deCONZ hardware support

Post by MattiasW »

when will you start working on this project again ?.
or is there somwhere to download the code that is done to get the support in domiticz ?
Thorgal789
Posts: 815
Joined: Wednesday 15 August 2018 14:38
Target OS: -
Domoticz version:
Contact:

Re: deCONZ hardware support

Post by Thorgal789 »

While waiting for hardware support, you can try a python version https://github.com/Smanar/Domoticz-deCONZ
Dahl1632
Posts: 8
Joined: Monday 26 June 2017 21:03
Target OS: OS X
Domoticz version:
Contact:

Re: deCONZ hardware support

Post by Dahl1632 »

Thorgal789 wrote: Friday 07 December 2018 16:58 While waiting for hardware support, you can try a python version https://github.com/Smanar/Domoticz-deCONZ
Thanks! I got my only IKEA Tradfri bulb into Domoticz, but, my two Philips Hue Outdoor strip didnt work:

2018-12-10 18:19:07.396 (deConz) ### Request lights
2018-12-10 18:19:07.396 (deConz) Send Command /api/6A62745855/lights/ with None
2018-12-10 18:19:07.447 (deConz) onConnect called
2018-12-10 18:19:07.501 (deConz) Classic Data : {'2': {'hascolor': True, 'state': {'reachable': True, 'alert': 'none', 'on': True, 'bri': 254, 'effect': 'none', 'sat': 254, 'ct': 325, 'colormode': 'xy', 'xy': [1, 1], 'hue': 12750}, 'name': 'Plank Hue 2', 'etag': '5c09695afa6062f7d8da1f1dc8b1dd72', 'type': 'Extended color light', 'ctmin': 153, 'manufacturername': 'Philips', 'swversion': '1.30.5_r23952', 'ctmax': 500, 'uniqueid': '00:17:88:01:03:a3:94:cf-0b', 'modelid': 'LST004'}, '3': {'hascolor': False, 'name': 'Gubi', 'etag': 'cd180439122ec8ea1e30fdbb81258ad3', 'type': 'Dimmable light', 'state': {'reachable': True, 'alert': 'none', 'on': True, 'bri': 173}, 'manufacturername': 'IKEA of Sweden', 'swversion': '1.2.214', 'uniqueid': 'd0:cf:5e:ff:fe:2f:b1:a0-01', 'modelid': 'TRADFRI bulb E27 W opal 1000lm'}, '1': {'hascolor': True, 'state': {'reachable': True, 'alert': 'none', 'on': True, 'bri': 254, 'effect': 'none', 'sat': 254, 'ct': 275, 'colormode': 'xy', 'xy': [1, 1], 'hue': 14358}, 'name': 'Plank Hue', 'etag': '0485004d94fef6072187735fcdb502c7', 'type': 'Extended color light', 'ctmin': 153, 'manufacturername': 'Philips', 'swversion': '1.30.5_r23952', 'ctmax': 500, 'uniqueid': '00:17:88:01:03:a3:95:08-0b', 'modelid': 'LST004'}}
2018-12-10 18:19:07.501 (deConz) ### Device > 2 Name:Plank Hue 2 Type:Extended color light Details:{'reachable': True, 'alert': 'none', 'on': True, 'bri': 254, 'effect': 'none', 'sat': 254, 'ct': 325, 'colormode': 'xy', 'xy': [1, 1], 'hue': 12750}
2018-12-10 18:19:07.501 Error: (deConz) 'onMessage' failed 'NameError':'name 'b' is not defined'.
2018-12-10 18:19:07.502 Error: (deConz) ----> Line 627 in /home/dahl/domoticz/plugins/Domoticz-deCONZ/plugin.py, function onMessage
2018-12-10 18:19:07.502 Error: (deConz) ----> Line 175 in /home/dahl/domoticz/plugins/Domoticz-deCONZ/plugin.py, function onMessage
2018-12-10 18:19:07.502 Error: (deConz) ----> Line 440 in /home/dahl/domoticz/plugins/Domoticz-deCONZ/plugin.py, function NormalConnexion
2018-12-10 18:19:07.502 Error: (deConz) ----> Line 348 in /home/dahl/domoticz/plugins/Domoticz-deCONZ/plugin.py, function InitDeconz
2018-12-10 18:19:07.502 Error: (deConz) ----> Line 186 in /home/dahl/domoticz/plugins/Domoticz-deCONZ/fonctions.py, function ProcessAllState
2018-12-10 18:19:07.502 Error: (deConz) ----> Line 257 in /home/dahl/domoticz/plugins/Domoticz-deCONZ/fonctions.py, function ReturnUpdateValue

Any idea?
Dahl1632
Posts: 8
Joined: Monday 26 June 2017 21:03
Target OS: OS X
Domoticz version:
Contact:

Re: deCONZ hardware support

Post by Dahl1632 »

2018-12-10 18:21:19.122 (deConz) ###### WebSocket Data : {'r': 'lights', 'e': 'changed', 'id': '1', 'uniqueid': '00:17:88:01:03:a3:95:08-0b', 'state': {'on': False}, 't': 'event'}
2018-12-10 18:21:19.123 (deConz) Banned device > 1 (lights)
2018-12-10 18:21:19.123 (deConz) ###### WebSocket Data : {'r': 'lights', 'e': 'changed', 'id': '2', 'uniqueid': '00:17:88:01:03:a3:94:cf-0b', 'state': {'on': False}, 't': 'event'}
2018-12-10 18:21:19.175 (deConz) ###### WebSocket Data : {'state': {'all_on': False}, 'r': 'groups', 'e': 'changed', 't': 'event', 'id': '1'}
2018-12-10 18:21:19.175 (deConz) Banned device > 1 (groups)
2018-12-10 18:21:19.175 (deConz) ###### WebSocket Data : {'state': {'any_on': False}, 'r': 'groups', 'e': 'changed', 't': 'event', 'id': '1'}
2018-12-10 18:21:19.176 (deConz) Banned device > 1 (groups)

I get this when i try to turn the strip on/off. I checked banned_devices.txt but nothing in there.
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest