ConBee ZigBee Stick and HA, will this work together?

@Robban, sorry, the entity id inside HA.
The uniqueid is different for all sensors, also for the three sensors in one case, i.e.:
{ "17": { "config": { "on": true, "reachable": true }, "ep": 1, "etag": "b61545be155759f8150333ed15f1e932", "manufacturername": "LUMI", "modelid": "lumi.weather", "name": "bathroom_temperature", "state": { "lastupdated": "2018-01-04T11:08:38", "temperature": 1972 }, "type": "ZHATemperature", "uniqueid": "00:15:8d:00:01:ab:4b:0e-01-0402" }, "18": { "config": { "on": true, "reachable": true }, "ep": 1, "etag": "b61545be155759f8150333ed15f1e932", "manufacturername": "LUMI", "modelid": "lumi.weather", "name": "bathroom_humidity", "state": { "humidity": 4909, "lastupdated": "2018-01-04T11:08:38" }, "type": "ZHAHumidity", "uniqueid": "00:15:8d:00:01:ab:4b:0e-01-0405" }, "19": { "config": { "on": true, "reachable": true }, "ep": 1, "etag": "b61545be155759f8150333ed15f1e932", "manufacturername": "LUMI", "modelid": "lumi.weather", "name": "bathroom_pressure", "state": { "lastupdated": "2018-01-04T11:08:38", "pressure": 991 }, "type": "ZHAPressure", "uniqueid": "00:15:8d:00:01:ab:4b:0e-01-0403" } }

Using it as the entity id inside HA, the entities would become the same object again, even if your deCONZ database was fried.
The names however, become the default ones again after you would rebuild your DB.

I already started working on this as a custom component, but you finished it before I did :slight_smile:
Anyway, it was my initial thought, to ensure that even a complete new deCONZ implementation, would simply get the same customizations again, as you would have applied them based on the entity_id = hardware’s uniqueid.

Thanks!

@marthocoo is working on proper docker support for deconz. Unfortunately it is not as clear cut as creating an image due to the way that deconz communicate with the hardware.

It’s a good suggestion .The biggest issue with it is readability when using the lights in any way inside of hass.

Hi,

I have read most of the above and it looks like great progress. I’m just starting out in the HA world and have ordered myself :

  • Raspberry Pi 3
  • Raspbee
  • Ikea Light and Switch
  • Some Sonoff touch switches and Relays (I’ll be flashing these with the MQTT firmware)
  • A Mi Temp sensor.

I just wanted to check the current state of things with regard to deCONZ etc, it looks like the PR above has been accepted, but not sure when that rolls into the production release of HA. Specifically my questions are :

  1. Should I be installing HASS.IO or do I need a standard Rasbian install to get deCONZ up and running? I’m not sure if you can install extra stuff on a HASS.IO box or if its just changes to the docker container you can’t do without it upgrading itself.

  2. Once I have installed deCONZ, can I add my devices (IKEA and MI) when its in headless mode, or will I have to have a X environment to do the initial setup? I see there is a beta web interface, Phoscon, as part of the deCONZ platform, but I wasn’t sure if that can be used to configure the network.

If there are any how to guides that cover the above I’ll happily go away and read them if you can link me to one.

Regards

Ben

1 Like

Welcome to the beautiful world of home automation. :slight_smile:

  1. Right now the separate deconz instance doesn’t work in docker and because of that in hass.io. @marthocoo is working on getting deconz to work in docker together with Dresden Elektroniks. If you have a second computer running you can have it running there instead. I don’t know if you can install deconz in the base operating system outside of docker, might be worth looking in to.
  2. Even when running in headless mode deconz still have a web Gui, there is also a newer separate Gui that is in beta, Phoscon it is called. The component exposes the full rest api of deconz though, which means you can reach all settings and functionality of deconz directly through the deconz service in hass.

I think most is covered in the component documentation, if it is not, maybe I should improve it. You can find the raw documentation here since it won’t be available on the home page until 0.61 has been released.

https://github.com/home-assistant/home-assistant.github.io/blob/next/source/_components/binary_sensor.deconz.markdown
https://github.com/home-assistant/home-assistant.github.io/blob/next/source/_components/deconz.markdown
https://github.com/home-assistant/home-assistant.github.io/blob/next/source/_components/light.deconz.markdown
https://github.com/home-assistant/home-assistant.github.io/blob/next/source/_components/scene.deconz.markdown
https://github.com/home-assistant/home-assistant.github.io/blob/next/source/_components/sensor.deconz.markdown

Hey @Robban, congrats on getting the PR merged!

To the first question, there’s currently no way to get the deCONZ server software working on the same machine as Hass.io, this requires first deCONZ to be working in Docker which I am working on and hoping to get some support for from DE soon.

You can however have deCONZ running on an install of Raspbian natively and also have Home Assistant running on the same RPi either in a python virtual environment or under Docker (this is how I’m currently running it while I work on a Docker container for deCONZ).

To the second question, you don’t need an X session running to get lights sensors, etc working in deCONZ. I’ve been able to use both the original web app and the Phoscon web app in combination to do everything I’ve wanted to do (including adding new devices, changing names, making groups, and so on). DeCONZ now comes with a systemd startup script that you can enable to run the server in headless mode.

I suspect we may not see a release of 0.61 until next weekend but I have created a Docker image of Home Assistant that includes a slightly earlier version of @Robban’s component on top of 0.60 that I’ve been using in the meanwhile that you can read about at https://github.com/marthoc/home-assistant-deconz and use on the RPi if you want to get up and running and setting your devices up before 0.61 drops.

Any other questions @Ben.S just let me know.

1 Like

Great that seems like the way to do it. Looks like you still get all the hass.io advantages of guy updates etc, but on a system you can run other things on at the same time (like deCONZ and specific daemons like one for a UPS etc). Do that’s the route I shall take.

I shall read the docs on your site and the ones @Robban linked me to. I’m pretty sure I shall have some questions in this process :wink: but I’ll try to keep them sensible!

I see 0.60.1 is released, so I guess your right that we won’t get 0.61 till next weekend now.

Ben

This chart helped me alot ty for that.
Could you also post the code in the switches to identify which one is triggered?
hope you see that :smile:

Hey @Robban and others, congrads with all the progress you made in such short time. I have a raspbee since October last year, but haven’t got the time (or skills) to add it to home assistant. Will definitely be using this component to throw out the Xiaomi hub (and its connection to the Chinese servers)

One question: is there also a possibility to include the double click event of the Xiaomi wireless button? I’m using this a lot for my buttons.

Thanks!

1 Like

All different button clicks will be exposed to home assistant

I get this errors in my setup, I have tried reinstalling everything and stil get the same. Where can I continue my search?

2018-01-09 22:50:26 ERROR (MainThread) [homeassistant.components.binary_sensor] Error while setting up platform deconz
Traceback (most recent call last):
File “/srv/homeassistant/lib/python3.5/site-packages/homeassistant/helpers/entity_component.py”, line 171, in _async_setup_platform
SLOW_SETUP_MAX_WAIT, loop=self.hass.loop)
File “/usr/lib/python3.5/asyncio/tasks.py”, line 400, in wait_for
return fut.result()
File “/usr/lib/python3.5/asyncio/futures.py”, line 293, in result
raise self._exception
File “/usr/lib/python3.5/asyncio/tasks.py”, line 239, in _step
result = coro.send(None)
File “/usr/lib/python3.5/asyncio/coroutines.py”, line 210, in coro
res = func(*args, **kw)
File “/srv/homeassistant/lib/python3.5/site-packages/homeassistant/components/binary_sensor/deconz.py”, line 29, in async_setup_platform
if sensor.type in DECONZ_BINARY_SENSOR:
AttributeError: ‘NoneType’ object has no attribute ‘type’

What sensors have you got connected?

Can you enable the logger component and set it to debug?

Hi! Looking for the most compatible and cheap way of integrating zigbee lights, I stumbled over this topic and have read most of the above. Thanks for your amazing work! It would be great, if somebody could answer these few questions:

  • I understand you are expecting the deCONZ component to be added in 0.61 release, am I correct?
  • Is there any difference in using RaspBee vs. ConBee? I have a spare Pi2, but I might still go for the ConBee because of the simple USB interface.
  • A simple transition over a couple of minutes with a simple hue bulb will surely work using the new component, will it? I would like to build a wake-up-light with a ~ 15 mins transition time…
1 Like
  • Yes, it is merged to dev branch so it is ready for next release
  • No difference, only the hardware interface differs. I recommend the conbee if you wish to migrate to a different hardware platform than the pi
  • Transition time is supported
1 Like

I have no sensors added in Home Assistant but multiple in deconze. Do I have to add sensors?

I meant to Deconz. What sensors have you got registered with Deconz?

AHi all, total n00b here, running:

  • Raspberry Pi3./Hassio 0.61.1
  • Dresden-elektronik, ZigBee ConBee USB-dongle
  • Z-Wave Aeon Labs Z-Stick Gen5

I have stuffed my ConBee into one of USB-port of my Raspberry Pi3.

Checked out this:

Also tried to find the USB-port using this:

And got this as a result:
ZigBeeUSB

I have added the following to the config-file:
zigbee:
device: /dev/ttyACM4 (- with two leading spaces)

Tried …/ttyACM2 and 3 and 4 (1 is for Z-wave)

Restarted ResinOS and Hassio.
And getting this ERROR:

Log Details (ERROR)
Fri Jan 19 2018 20:41:56 GMT+0100 (Romance Standard Time)

Unable to open serial port for ZigBee: [Errno 2] could not open port /dev/ttyACM4: [Errno 2] No such file or directory: ‘/dev/ttyACM4’
Traceback (most recent call last):
File “/usr/lib/python3.6/site-packages/serial/serialposix.py”, line 244, in open
self.fd = os.open(self.portstr, os.O_RDWR | os.O_NOCTTY | os.O_NONBLOCK)
FileNotFoundError: [Errno 2] No such file or directory: ‘/dev/ttyACM4’

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “/usr/lib/python3.6/site-packages/homeassistant/components/zigbee.py”, line 93, in setup
ser = Serial(usb_device, baud)
File “/usr/lib/python3.6/site-packages/serial/serialutil.py”, line 182, in init
self.open()
File “/usr/lib/python3.6/site-packages/serial/serialposix.py”, line 247, in open
raise SerialException(msg.errno, “could not open port {}: {}”.format(self._port, msg))
serial.serialutil.SerialException: [Errno 2] could not open port /dev/ttyACM4: [Errno 2] No such file or dir’/dev/ttyACM4’

Please someone.
What is the correct code in the configuration.yaml for ZigBee ConBee and how do I find the right USB-port to use. Do I use “database_path: zigbee.db”?

It’s not quite clear to me what hardware you have. It seems like it’s the HUSBZB-1 Zwave/ZigBee combo stick which is NOT a RaspBee or Conbee so has nothing to do with this thread. You’re looking instead for the zha component… and there are other threads dealing with the setup and config of that component.

This is my hardware:

  • RPI3
  • Z-Wave Aeon Labs Z-Stick Gen5
  • Dresden-elektronik, ZigBee ConBee USB-dongle

Check out the last few posts here DeCONZ, ZHA and Zigbee components and compatible hardware

1 Like