Raspbee II - ZHA - Couldn't start deCONZ error

Hello,

I was running a RPI3 and a Raspbee II with ZHA without any problem for months and a week ago my RPI started to freeze (need to restart it twice a day, automations were slow and many other problems).

A that time, I was working on the alarm system, and RPI was behind a UPS managed by the NUT addon for 2 weeks without any problem. A week before first freeze I was trying to add a E3531 usb stick with a 2g sim to have SMS if network is down and alarm fired, but without any luck for now.

I wasn’t doing any thing for days when it start crashing. I didn’t succeed in fixing it so I decided to restore a backup from “before the UPS installation”. It failed. I then decided to get a brand new (good) MicroSD card and did a fresh install, go to UI, restored the backup and look like it succeed, but no more UI.

I spent few days in understanding why. I saw errors with zigppy / deconz in core logs so I was investigating in it, but in the end I saw that docker didn’t map the 8123 port and investigate in network. My RPI3 was wifi connected before the crash, and when I reinstall it it did it with ethernet. This was the problem, configuration in snapshot was linked to wifi. After restoring wifi, everything was up again, but I still have the bug with my zigbee network.

I have between 40 and 50 devices and they are all offline.

In logs I can see this :

2021-03-10 14:43:02 WARNING (MainThread) [zigpy_deconz.api] No response to 'Command.read_parameter' command with seq id '0x02'
2021-03-10 14:43:02 ERROR (MainThread) [zigpy.application] Couldn't start application
2021-03-10 14:43:02 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start deCONZ = dresden elektronik deCONZ protocol: ConBee I/II, RaspBee I/II coordinator
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 157, in async_initialize
    self.application_controller = await app_controller_cls.new(
  File "/usr/local/lib/python3.8/site-packages/zigpy/application.py", line 69, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.8/site-packages/zigpy_deconz/zigbee/application.py", line 66, in startup
    self.version = await self._api.version()
  File "/usr/local/lib/python3.8/site-packages/zigpy_deconz/api.py", line 444, in version
    (self._proto_ver,) = await self[NetworkParameter.protocol_version]
  File "/usr/local/lib/python3.8/site-packages/zigpy_deconz/api.py", line 409, in read_parameter
    r = await self._command(Command.read_parameter, 1 + len(data), param, data)
  File "/usr/local/lib/python3.8/site-packages/zigpy_deconz/api.py", line 305, in _command
    return await asyncio.wait_for(fut, timeout=COMMAND_TIMEOUT)
  File "/usr/local/lib/python3.8/asyncio/tasks.py", line 501, in wait_for
    raise exceptions.TimeoutError()
asyncio.exceptions.TimeoutError

Some topic here suggest to remove the conbee stick, restart HA and replug, but it’s not a conbee, but a Raspbee one.

I have no idea what to try now to restore my zigbee nework !

Thank you for your help.

Solved.

Added to /boot/config.txt :

enable_uart=1
dtoverlay=pi3-miniuart-bt

And change path to device in ZHA from /dev/ttyAMA0 to /dev/ttyS0 in /config/.storage/core.config_entries

Thx for this! I had the same issue and just adding enable_uart=1 fixed it for me. I have these dtoverlays active anyways:

dtoverlay=disable-wifi
dtoverlay=disable-bt

I had the issue popping up in the past already couple of times, but reboot fixed it… Let’s see if it stays fixed with this!
Thx again!

1 Like

Hi, how do you go to /boot. I’ve removed my sd card and load it into USB card reader on another linux machine but I’m not able to find that /boot.
Is it accessible in HA ?
My conbee II just stop working after upgrade to 2021.7.1 I have the same timeout error. It was working fine for many month.

Hi, it’s not (really) accessible in HA.

The easiest way is to remove the SD and place it in an other linux system. You will have to mount it manually, it won’t automount, this is why you don’t see it.

Thanks @wouf I’ll try this next weekend

similar problem, I’m running pi4, I’ll be greatfull for some help this is what I get:

Logger: homeassistant.components.zha.core.gateway
Source: components/zha/core/gateway.py:152
Integration: Zigbee Home Automation (documentation, issues)
First occurred: 12:05:16 AM (4 occurrences)
Last logged: 12:09:46 AM

Couldn't start deCONZ = dresden elektronik deCONZ protocol: ConBee I/II, RaspBee I/II coordinator
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/asyncio/tasks.py", line 492, in wait_for
    fut.result()
asyncio.exceptions.CancelledError

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 152, in async_initialize
    self.application_controller = await app_controller_cls.new(
  File "/usr/local/lib/python3.9/site-packages/zigpy/application.py", line 69, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.9/site-packages/zigpy_deconz/zigbee/application.py", line 67, in startup
    self.version = await self._api.version()
  File "/usr/local/lib/python3.9/site-packages/zigpy_deconz/api.py", line 463, in version
    (self._proto_ver,) = await self[NetworkParameter.protocol_version]
  File "/usr/local/lib/python3.9/site-packages/zigpy_deconz/api.py", line 428, in read_parameter
    r = await self._command(Command.read_parameter, 1 + len(data), param, data)
  File "/usr/local/lib/python3.9/site-packages/zigpy_deconz/api.py", line 313, in _command
    return await asyncio.wait_for(fut, timeout=COMMAND_TIMEOUT)
  File "/usr/local/lib/python3.9/asyncio/tasks.py", line 494, in wait_for
    raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError

added this line:

enable_uart=1

and I can’t find any line: ZHA from /dev/ttyAMA0 in core.config_entries

and getting this on deCONS page: