Sonoff zigbee HUB + asustor NAS

Hello. I am running home assistant in docker container on an asustor NAS. It works fine, I added all my tuya WiFi and aqara zigbee devices and they communicate pretty good, Aldo some fonctionnality from the different zigbee devices is lacking.
I’m trying to make sonoff zigbee hub TI CC2256P through the zigbee home automation integration in HA. The problem is that I cannot forward the serial device to the docker container.
This is what I tried so far
SSH into the NAS as root
dmesg | grep USB
I get a list of devices and the module seems to be recognised
[ 4.406605] usb-storage 2-2:1.0: USB Mass Storage device detected
[ 4.471124] usb 1-5: new full-speed USB device number 3 using xhci_hcd
[ 4.605688] usb 1-5: New USB device found, idVendor=10c4, idProduct=ea60, bcdDevice= 1.00
[ 4.614692] usb 1-5: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 4.622553] usb 1-5: Product: Sonoff Zigbee 3.0 USB Dongle Plus

But I don’t have any folder called /dev/serial/by-id
Maybe this means the drivers are missing ? Is there a way to add them to this version of Linux ?
Any way you can point me in the right direction ?
Thanks, have a nice day

I am not sure if you are having the same issue as I did, but if that is the case, I will try and help you out best I can! I stumbled upon your post when looking for a solution for my own problem.

Issue: Sonoff zigbee 3.0 USB Dongle Plus not working due to missing drivers. (Looks like the same issue as you are having)
Solution: Since I could find none, I built the missing driver for the kernel version and architecture used by my Asustor nas.
The missing driver was cp210x, and I don’t know why it (and many other drivers) aren’t shipped with ADM.

If am running ADM 4.1.0.RLQ1 on an AS66 (64 bit intel cpu). (ADM 4.2 was released just hours ago, so it might not work there, as I haven’t checked)

ADM 4.1 is running linux kernel 5.13.x.

I am not gonna give you the details on how to build it (as that might become too complex if you are a novice), instead I am gonna give you this link: Deleted to the driver for you to simply “install”. :slight_smile:

If you are running a different version of ADM, or a with a differnt arch cpu, the driver I am posting might not work for you. But perhaps I can build it for you, if you let me know which nas and adm version you are running.

First of all, you need to transfer the file to your nas. Once you have done that, open a ssh shell and login to your nas.

Now locate the file and move it to /lib/modules (run as sudo)
i.e.

sudo mv /lib/modules/5.13.x/cp210x.ko

Then we need to “install” it using insmod.

sudo insmod /lib/modules/5.13.x/cp210x.ko

Now reinsert the dongle and run dmesg and rejoice :slight_smile:

Hopefully this works for you!

1 Like

This file is no longer on line. Would you be able to repost please.

I am running ADM4.2 on an AS6604T.

Hi Johan. This helped me tremendously - and I saved the file and tried to keep it that way (I have to run this every time my NAS restarts).

It has, however, vanished, and the download link does not work anymore. Could you please re-upload it? (or give a hint as to how to actually build it, as I might have to graduate from novice to master, to get my lights back on :smiley: )

Thanks in advance.

I found the cp210x driver in the Asustor app library now: ADM Kernel Extensions

My steps were:

  1. Install ZHA extension through HACS
  2. Inserting Sonoff USB
  3. Install the ADM Kernel Extension (from Asustor App store)

From this, Home Assistant detected my Sonoff USB device. :slight_smile:

Description

ADM Kernel Extensions brings a number of new and optional features to your NAS. Install ADM Kernel Extensions today to take advantage of new optional features.
List of features supported by ADM Kernel Extensions:
WireGuard VPN Client
cp210x.ko for Zigbee devices

I am using the Asustor with Home Assistant and the Conbee II zigbee radio. I had no issues getting HA to recognize the Conbee II USB radio, but it constantly switch from /dev/ttyACM0 to /dev/ttyACM1 (requiring me to to reconfigure in HA). The Asustor doesn’t seem to allow udev rules like a typical Linux installation would. Did this Kernel Extension provide any additional support for a symlink or persistent USB mapping?

Which zigbee integration are you using? Both Z2M and ZHA will let you define the coordinator path using /dev/serial/by-id instead of /dev/tty. This never changes and should fix your issue.

AFAIK the existence of device entries in /dev/serial/by-id depends on distro/OS support (they are not created by the kernel or by drivers), and it could very well be that the AsusStor OS doesn’t create them (Synology DSM also doesn’t).

Well, the earlier posts in this thread seem to indicate that it’s entirely possible to build them yourself. In the case of the Asustor, you can just download it from the library apparently.

I am using ZHA and I believe @robertklep is correct, the Asustor OS (ADM) does not map serial devices to /dev/serial. I’ve also tried making udev rules and the OS seemed to ignore them.

I was hoping this kernel extension brought some of that functionality, but the thread above seems unclear if it does that or just provides drivers. @robertklep it sounds like you’ve maybe seen similar issues in DSM, if so, any tips to getting a static mapping?

I stopped using DSM a long time ago for HA, but if I remember correctly, the change of device file (from /dev/ttyUSB0 to /dev/ttyUSB1 for instance) only happened when you removed the dongle from the NAS, then plugged it in again, which is something that in normal use never really happened. If it did, I just rebooted the NAS so it would assign the dongle back to the original file.

Thanks for the follow up. Mine seems to remap everytime the HomeAssistant container is restarted and possibly more than that.
However, I have the ADM Extension (mentioned above) installed and no different behavior, so maybe I’ll start a different thread focused on my issue, maybe even directly with Asustor.

What could be happening is that your dongle restarts and reconnects, caused by something inside the container, but that would basically mean the dongle is crashing. Otherwise the container shouldn’t have control over the device file that gets assigned to the device on the host side.