Zigbee Dongle, ZHA, Home Assistant VM, USB Cable = WTF

So I have a Home Assistant VM on Unraid with ZHA. I have a Sonoff Zigbee 3.0 USB Dongle.

If I plug the dongle into a usb extension cable, boot, hotplug in the dongle, all works fine 100%.

If I plug the dongle into the exact same port on the mobo, it recognizes the dongle in the VM, but does not pass info. No devices can connect, no data flows in, no new devices can be added. Same goes if I add in the device to the template, start, etc. Nothing. Tried every combination. Reverted back to previous versions of HA, Unraid, and firmwares on the dongle. NADA.

Other USB ports do the exact same thing. And yes, they are all USB 3.0 and so is the extension.

Ideas how to fix this? Don’t even know why this would be a thing?

So it doesn’t work when you don’t use the extension cable? That’s exactly why you need to use that cable, USB3.0 can cause interference on 2.4Ghz which can lead to all kinds of random issues.

Also, if possible, plug the extension cable with the dongle in a USB2 port to minimise interference even more.

Is it ok to use a cable and attach a usb 2.0 hub to that cable. I am using three different usb devices.

I think that should work. If not, you can always use a shortish cable between the hub and the computer, and use the longer extension cord between the hub and the dongle.

I know using virtualbox I have to jump through hoops to get the stick to be recognized.
To get the stick to recognize you have to plug it in. Then in Virtual box settings, USB, click the plus and add the stick. Then remove the stick and shut down the virtual machine. While the VM is off, plug in the stick and start the VM. The stick should be recognized.

FYI, there is another known design flaw with length of the USB port on dongle that can also be related

https://community.home-assistant.io/t/iteads-sonoff-zigbee-3-0-usb-dongle-plus-based-on-texas-instruments-cc2652p-20dbm-radio-mcu-now-sold-for-14-99/340705

  • To avoid EMF interference strongly recommended buy and use → Long USB extension cable
    • Another reason for using a USB extension cable is that the USB-plug design of ITead’s Sonoff Zigbee 3.0 USB Dongle Plus hardware adapter is a little short which makes it harder and sometimes impossible to plug it into some USB ports if the computer enclosure/chassis/casing is to thick around the USB-port as that will physically prevent the USB dongle from actually making a proper connection inside the USB port even if it looks like it is plugged in all the way that is possible.

Tip is also to use in it in a powered USB 2.0 hub as USB 3.0 can cause serious interferece to Zigbee.

Regardless, be sure to follow setup tips and best practices as Zigbee is very sensitive to interference:

https://github.com/home-assistant/home-assistant.io/pull/18864/commits/970295a277e8f01d3ee39eeeaacf453625b988d3 from → https://github.com/home-assistant/home-assistant.io/pull/18864

and

https://www.home-assistant.io/integrations/zha#best-practices-to-avoid-pairingconnection-difficulties

Unplug the dongle and extension cable
Clear the USB settings for the VM.
Plug The Cable and dongle back in and set the USB passthrough.
Unplug the cable/dongle again.
Shut down the VM
Plug teh dongle and usb cable back in
Restart the VM and home assistant.

@Rich37804 Is there anyway to have the VM connect the USB dongle automatically when it boots and initiates HA ?

I’m thinking of a script that starts when the VM initializes and starts running. My VM is running on a QNAP NAS.

I really dont think so. Best thing Ive done is set up a bare metal machine and gotten away from the VM. Not had a single issue since.

1 Like

+1 for this approach. I know the machine is overkill for a HA instance but it was only gathering dust.