Help with zha, elelabs USB, zigbee and hass

Ok well that definitely verifies that the stick is at ttyUSB0.

Have you looked at the setup instructions for the stick on the Elelabs website:

it has instructions specific to home assistant. I looked there and saw that you need to include a baudrate entry to the zha config. The example they show is for hassio but it should also work for regular HA also. You just need to modify the db path. Here is what they show as a config (I changed the db path for HA):

zha:
  usb_path: /dev/ttyUSB0
  database_path: /home/homeassistant/.homeassistant/zigbee.db
  baudrate: 57600

I would add the baudrate: to the config and see if it helps

Also I saw you changed your db path in the last attempt. Make sure you change that back to what you had before to keep everything standard (I already did that in the code above).

Also if that doesn’t work the guide at the elelabs site also has instructions for setting your logger up to get debug logs for zha too. So maybe that will help if adding the baudrate doesn’t help.

Thanks finity. I tried the baudrate but no joy.

I’ll try the advanced debugging. Hopefully there is a clue in there somewhere!

Well, we’re definitely getting more information now that I have loaded that debugger!

I now get a whole bunch more detail (here’s the log info: https://hastebin.com/igoqexagil.bash)

The last few lines:

Jan 10 20:40:21 Lazio hass[31170]: 2019-01-10 20:40:21 DEBUG (MainThread) [bellows.ezsp] Send command setConfigurationValue
Jan 10 20:40:21 Lazio hass[31170]: 2019-01-10 20:40:21 DEBUG (MainThread) [bellows.uart] Sending: b'664c215754790eb4591cd87e'
Jan 10 20:40:21 Lazio hass[31170]: 2019-01-10 20:40:21 DEBUG (MainThread) [bellows.uart] Data frame: b'674ca157547915ec1b7e'
Jan 10 20:40:21 Lazio hass[31170]: 2019-01-10 20:40:21 DEBUG (MainThread) [bellows.uart] Sending: b'87009f7e'
Jan 10 20:40:21 Lazio hass[31170]: 2019-01-10 20:40:21 DEBUG (MainThread) [bellows.ezsp] Application frame 83 (setConfigurationValue) received
Jan 10 20:40:21 Lazio hass[31170]: 2019-01-10 20:40:21 DEBUG (MainThread) [bellows.ezsp] Send command networkInit
Jan 10 20:40:21 Lazio hass[31170]: 2019-01-10 20:40:21 DEBUG (MainThread) [bellows.uart] Sending: b'774d2157543d0cfe7e'
Jan 10 20:40:26 Lazio hass[31170]: 2019-01-10 20:40:26 DEBUG (MainThread) [bellows.uart] RSTACK Version: 2 Reason: RESET_POWER_ON frame: b'c102029b7b7e'

That’s where it seems to be getting stuck.

Any ideas?

At this point I’ve got nothing.

I did a search and there are some references to something similar but nothing exactly matching and no real resolution as far as I could find.

Maybe your best bet would be to continue this with Elelabs customer tech support.

Yeah, I was afraid you’d say that. :frowning: I have reached out to them before and haven’t had any response.

In fact, their website says they no longer sell this version of the USB stick, and new ones are coming in 2019. :angry:

Any better suggestions for Zigbee control from a Raspberry Pi?

I’ve been using the the HUSBZB-1 for about a year and a half ever since I started using HA.

I’ve “almost” never had any troubles with it…

I’ve only got some Sengled light bulbs connected to it and they have worked really well so far.

However, right after I got the stick and bulbs all connected and working i bought some zibee “compatible” Bosch motion sensors that were really cheap. And then I found out a couple of things. 1. they weren’t compatible with the zha version that HA uses. 2. The place where I bought them from had horrible customer service. When I requested a RMA to return them the guy basically told me he would gladly accept a return but he would charge me the entire amount of the order as a “restocking fee”. :roll_eyes: They’ve been sitting on the bench ever since.

Then about a couple of months ago out of the blue for some unknown reason the HUSBZB-1 stick started acting screwy. it would intermittently loose comms with the NUC i’m running HA on and/or the zigbee lights. I fought it for a few weeks then decided to try out zigbee2mqtt (which is my next recommendation after the HUSBZB stick) which would have the added benefit of possibly getting those “useless” motion sensors working since you can add functionality to the software to potentially integrate new devices.

But then while I was waiting on the CC2531 stick and programmer to be sent over on a slow boat from china :slightly_smiling_face: I thought about the fact that I still had my original RPi that had a perfectly working instance of HA on it that the stick ran on before I switched to the NUC. I plugged the stick in there and it’s been working perfectly ever since :confused:

So now I use MQTT from my main HA on the NUC to control zigbee devices connected to the stick running in HA on the RPi.

The zigbee2mqtt set up has the advantage of being cheaper than the HUSBZB-1 stick (US$45 on Amazon with prime shipping) even with buying the required programmer (~US$25 at Aliexpress) but like I said it takes forever to get shipped and you might have to put in a little work if your devices aren’t already included in the supported devices. But there are a bunch of supported devices already so the chances of that are less than what you might think.

https://github.com/Koenkk/zigbee2mqtt/blob/master/docs/information/supported_devices.md

hey @thecrane
I’ve also got an Elelabs stick but never ran into any of these problems. Originally I was using it on a Pi 3b with hassio, I setup exactly as you did in the configuration.yaml as /dev/ttyUSB0 and a database path. About a month or so back I moved over to an Asus Tinkerboard but still running hassio, this time I set it back up using the ‘Integrations’ page from the front end. I’ve not had any issues with that setup method either.

Nothing special on my frontend config either, just enabled. Updater and discovery disabled.

frontend:

config:

hassio:

Sorry realize this probably doesn’t help but thought to at least let you know it works on hassio
Maybe try setting the radio type on the config? radio_type: ezsp

image

It’s good to know that you at least have it working!

I am using HASS on Raspbian, as I had issues with hassio initially. But I can’t get it to load!

I’ve recently enabled the debugger and got some more information - it seems to be sticking here:

Jan 14 17:04:37 Lazio hass[673]: 2019-01-14 17:04:37 ERROR (MainThread) [homeassistant.core] Error doing job: Exception in callback SerialTransport._read_ready()
Jan 14 17:04:37 Lazio hass[673]: Traceback (most recent call last):
Jan 14 17:04:37 Lazio hass[673]:   File "/usr/lib/python3.5/asyncio/events.py", line 126, in _run
Jan 14 17:04:37 Lazio hass[673]:     self._callback(*self._args)
Jan 14 17:04:37 Lazio hass[673]:   File "/srv/homeassistant/lib/python3.5/site-packages/serial_asyncio/__init__.py", line 106, in _read_ready
Jan 14 17:04:37 Lazio hass[673]:     self._protocol.data_received(data)
Jan 14 17:04:37 Lazio hass[673]:   File "/srv/homeassistant/lib/python3.5/site-packages/bellows/uart.py", line 64, in data_received
Jan 14 17:04:37 Lazio hass[673]:     self.frame_received(frame)
Jan 14 17:04:37 Lazio hass[673]:   File "/srv/homeassistant/lib/python3.5/site-packages/bellows/uart.py", line 86, in frame_received
Jan 14 17:04:37 Lazio hass[673]:     self.data_frame_received(data)
Jan 14 17:04:37 Lazio hass[673]:   File "/srv/homeassistant/lib/python3.5/site-packages/bellows/uart.py", line 107, in data_frame_received
Jan 14 17:04:37 Lazio hass[673]:     self._application.frame_received(self._randomize(data[1:-3]))
Jan 14 17:04:37 Lazio hass[673]:   File "/srv/homeassistant/lib/python3.5/site-packages/bellows/ezsp.py", line 169, in frame_received
Jan 14 17:04:37 Lazio hass[673]:     assert expected_id == frame_id
Jan 14 17:04:37 Lazio hass[673]: AssertionError

According to the PDF that Elelabs has on their site:

That means your USB adapter has a different version, probably v6. While Home Assistant version is
<=0.66.

First, try to update the Home Assistant, probably later versions will support v6 ezsp protocol and
you will not have this issue.

Second, try to perform the Software Downgrade on the Elelabs USB Adapter to downgrade it to v5,
which is supported on 0.66. To do it you better contact us at [email protected].

Contacting them has resulted in radio silence. I’m running the latest build (0.84?) of HASS, so it can’t be that. I’m now trying to find out if I can manually update the ezsp support to v6?

Why is this soooo hard?! :frowning:

Thanks for all those details, @finity - I appreciate that. I will have to look a bit closer and see if this is an option for me.

To be honest, I would just use a SmartThings hub, but they only come in the z-wave frequency that is illegal in my part of the world.

Not knowing what issues you had with it–
maybe take another stab at hassio on a different SD card? see if that gets the Elelabs stick working

Thanks @cybergrimes - this is my fourth attempt on my third SD card (2nd Pi). :slight_smile: I’m really trying to eliminate everything.

I may revert back to trying it again, though. Really disappointed I can’t get it working. :frowning:

I am using the Raspberry Pi Shield on an ASUS Tinker board. It so far won’t work. I have been trying to disable my Bluetooth UART since the documentation says that it might need to be. When I run ls -l /dev/tty*, I cannot see ttyAMA0, which is what should come up for the elelabs device, according to the documentation.

Not that this helps, but am hoping that someone will see this and help us both.

Rob

An update on this: still no go! :frowning:

I installed hassbian on a brand new SD card, and plugged the Elelabs USB in…and it gets stuck on this line:

2019-03-02 03:06:00 DEBUG (MainThread) [bellows.uart] Sending: b'8160597e'

2019-03-02 03:06:00 DEBUG (MainThread) [bellows.ezsp] Application frame 25 (stackStatusHandler) received

2019-03-02 03:06:00 DEBUG (MainThread) [bellows.uart] Sending: b'015221575402629c7e'

2019-03-02 03:06:01 DEBUG (MainThread) [bellows.uart] RSTACK Version: 2 Reason: RESET_POWER_ON frame: b'c102029b7b7e'

Zero response from Elelabs. So, I’m going to give up and try and something else. Not sure what though.

I have working Elelabs RPi shield and if you want I can buy your stick and try it in my system.

I’m moving from RPi to “heavier” hardware and I would need to get Zigbee USB stick. In exchange, if your stick is working in my environment, I can send my RPi shield to you later.

I’m in EU area.

Has anyone managed to get this to work yet? Elelabs are dodging my emails and I’m really stuck.

Have it working with great stability since last update (0.86.1).

8 x sengled (light.sengled_e11_g13_)
2 x philips hue (light.philips_lwb014_)

running on a Hassbian with Elelabs zigbee shield.

First installs on Hass was very flaky, but the serial settings that came out of the box with last Hassbian version were actually fine besides disabling the bluetooth on the image before booting.

I’m going to give it another try, now that I’m on 0.89.2. But I’ve also ordered a Dresden shield that should arrive next week to try that. Might have to learn deconNZ…?

It’s almost like the universe doesn’t want me to have this up and running!

I got my Dresden Raspbee shield and have set it up in a separate Raspberry Pi with deCONZ running…and now it won’t detect my Heiman door sensor that was the whole reason for me doing this! Plus, the Yale lock that I was hoping to use over Zigbee isn’t even supported in deCONZ (as far as I can tell).

:weary:

I give up. I think I’ll just get an Aeotec Z-wave stick, and some other sensors that work with deCONZ. I do appreciate everyone’s help, but I’ve ended up at a dead end I think.

@Hepokatti - may be worth a shot, although even when I plug my USB stick into my PC, I can’t test it to see if it works because the link to the Node test app on the Elelabs site is dead!

Any way I could test it before I send it?

I was able to get the elelabs Pi Shield to work on a Pi3 Model B. I had to start with a fresh install of Hassio, then changed the config.txt file as elelabs instructed per the instructions on the Tindie website. Disabling of the Bluetooth UART is required due to a conflict.