Deconz for Hass.io


#1

I would want to run deconz on my hass.io-RPi. Is there any way to do that? I understand that there is a way to install it on a separate server and link it to hass.io, but I would want to have it all on one RPi.

Thank you in advance


#2

#3

It is relatively easy to do, but takes some tweaking to the resinOs that is running all of the docker for hass.io. Then I suppose it is a bit depending on if you have a Raspbee or a Conbee. With this I mean all the help in the topic mentioned by Robban helps if you have a Conbee, but for some reason I could not get it to work with Raspbee.

I’ve build a custom hassio addon for that (that borrows some from other attempts), you can find it here deCONZ Raspbee addon.

For Raspbee to be detected properly I had to add the following lines to the config.txt (only editable when you put the SDCard in a computer)

enable_uart=1
dtoverlay=pi3-disable-bt

Hass.io + deCONZ + RaspBee = Flailure
#4

Nice work!
Too bad about the shares folder.
Is there a way to put this in the Hassio Add-Ons via a repository link instead of downloading it?


#5

Because it is still a work in progress, especially with the shares folder, I’m not comfortable releasing it to a public docker registry yet. Otherwise it would be possible to download the image from the public docker registry.

As soon as it is more stable I will look into releasing it to docker. After it is in a public docker I can create a repository around it for Hass.io


Installing deconz on my raspberry pi runnin hassio?
#7

Thank you for your answers. I finally got deconz connected to my hassio installation and imported two temp sensors. Funny I don´t see any of them in deconz.


#8

You might not see the sensors in the Deconz web interface, you should be able to see them and change their names in the Phoscon app though:


#9

Correct. Thank you.

Now I only have to wait for some other Xiaomi devices to get another challenge. The sensors seem to work very well. Now I can finally clean my house from 433-devices.


#10

gjong thanks for the great work creating the deconz docker, I’m new to docker so I may be doing something wrong but once I had built the docker image I was unable to run due to a permission denied error. I had to add the following to the Dockerfile
RUN chmod +x start.sh

Once done worked a treat


#11

Very new to this, but managed to get the deconz addon show up in hass.io, but then I try to Install it just try for a few seconds then this message shows up in log.
ERROR (SyncWorker_6) [hassio.docker.addon] Can’t build local/armhf-addon-conbee_deconz:1.1: ADD failed: failed to GET http://dl-cdn.alpinelinux.org/alpine/edge/testing/armhf/qt5-websockets-5.9.1-r0.apk with status 404 Not Found: I guess Its a file that is missing in the alpine index or maybe have been replaces with at newer. Anything I can do myself to solve this?
Best Regards //Richard


#12

@gjong I’m having an issue running the hassio addon. The log is not really helpful though… Any idea where shall I start debugging it?

[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 00-banner.sh: executing... 
[cont-init.d] 00-banner.sh: exited 267.
[cont-finish.d] executing container finish scripts...
[cont-finish.d] 99-message.sh: executing... 
s6-maximumtime: warning: child process crashed
[cont-finish.d] 99-message.sh: exited 111.
[cont-finish.d] done.
[s6-finish] syncing disks.
[s6-finish] sending all processes the TERM signal.

#13

I presume you downloaded the code from bitbucket and deployed it locally into the hassio addon directory. If so and you did so recently there might be an issue with it trying to pull in a docker image from the public registry, I had to update the configuration to prevent this. Could you try the latest version from bitbucket and see if the problem still persists after a rebuild.


#14

Sorry for the late reply. I tested the builds locally on armv6 (pi zero) and it seems to segfault aka error 139. I’d assume this has to do with upstream image. Yet I was unable to build an image that would work although running through hassioaddons/build-env and qemu seems to produce an image. The weird thing is that the segfaults do not happen on images fetched from hassioaddons repository. Which are based of the same base images.


#15

Hi, @gjong i installed your add-on and it works, but i can’t upgrade the firmware using the command
bash docker run --rm -it --entrypoint "/bin/bash" --privileged --device /dev/ttyAMA0:/dev/ttyAMA0:rwm local/armhf-addon-deconz GCFFlasher_internal -f /usr/share/deCONZ/firmware/deCONZ_Rpi_0x261e050 0.bin.GCF

the error is

bash: docker: No such file or directory


#16

You will need to log into the physical machine that runs resin containers rather than hass itself: https://home-assistant.io/developers/hassio/debugging/

Something along the lines:
$ ssh [email protected] -p 22222


#17

@peel I’m not exactly sure what is happening in your build. Does it fail during the building process with the segmentation failure or during running. I’ve not yet tested building using the build-env tools from franck, but this is something I’m going to be looking into. What I noticed from your comment is that you are on armv6 with your Pi, I haven’t tested using that hardware before so I’ll try and help you best I can without that hardware. I know the base image is based on arm32v7, so I’m not sure if that may cause issues in the image.

I usually build it on a Windows machine first locally to test the build is working and then pull the changes into my Pi3 to build it through the UI of Hass.io. So far this has worked most of the builds, and if it failed it was due to a mistake in my build script. I try to fix those as quickly as possible or my wife will get angry when she can’t control the lights for more then a few hours.


#18

@peel ok i’ve connected to ssh as you said but there isn’t a folder /usr/share/deCONZ


#19

and now i can’t connect anymore to hassio.local:8123


#20

You should do the following steps to update firmware

  • stop the addon with in Your home assistant website
  • SSH into the resinos machine, that is Your raspberry pi under port 2222
  • then run the docker commando, this should result in the container starting that the flash was Successfully.
  • after this you can Start the addon again.

Note the folder is not in Your resinos machine, but in the deconz docker image.


#21

Some error but is it ok?

[email protected]:~# bash
[email protected]:~# docker run --rm -it --entrypoint "/bin/bash" --privileged --device /dev/ttyAMA0:/dev/ttyAMA0:rwm local/armhf-addon-deconz GCFFlasher_internal -f /usr/share/deCONZ/firmware/deCONZ_Rpi_0x261e0500.bin.GCF
rmmod: ERROR: ../libkmod/libkmod.c:514 lookup_builtin_file() could not open builtin file '/lib/modules/4.4.50/modules.builtin.bin'
rmmod: ERROR: Module ftdi_sio is not currently loaded
rmmod: ERROR: ../libkmod/libkmod.c:514 lookup_builtin_file() could not open builtin file '/lib/modules/4.4.50/modules.builtin.bin'
rmmod: ERROR: Module usbserial is not currently loaded
GCFFlasher V2_11 (c) dresden elektronik ingenieurtechnik gmbh 2017/12/10
no device specified use RaspBee (/dev/ttyAMA0)
using firmware file: /usr/share/deCONZ/firmware/deCONZ_Rpi_0x261e0500.bin.GCF
reset target
flashing 126124 bytes: |==============================|
verify: ....
SUCCESS
modprobe: ERROR: ../libkmod/libkmod.c:586 kmod_search_moddep() could not open moddep file '/lib/modules/4.4.50/modules.dep.bin'
modprobe: FATAL: Module usbserial not found in directory /lib/modules/4.4.50
modprobe: ERROR: ../libkmod/libkmod.c:586 kmod_search_moddep() could not open moddep file '/lib/modules/4.4.50/modules.dep.bin'
modprobe: FATAL: Module ftdi_sio not found in directory /lib/modules/4.4.50