CC2531 - Error while starting zigbee-herdsman

Hi all,
I finally got my CC2531 (with antenna and flashed as coordinator) up and running yesterday. Everything seemed to be fine, my Tuya switch (standard firmware, never connected to Smart Life or Tuya cloud) joined the Zigbee network and I could control it through Hassio, but later I lost control of them and started to receive errors every 15-20 seconds in the Zigbee2MQTT log stating:

Error while starting zigbee-herdsman

I’ve tried to google it but I’m at a loss. Rebooting my RPi multiple times doesn’t bring it back but if I reboot and pull the CC2531 it will come back, but only for about an hour before it started to error out again, with the same thing.

My initial log this morning, after I’d pulled the USB, looked like this:

[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] done.
[services.d] starting services
[services.d] done.
./run.sh: line 17: [Info] Configuration backup found in /share/zigbee2mqtt/.configuration.yaml.bk. Skipping config backup.: No such file or directory
[Info] Socat is DISABLED and not started
2020-06-07T08:28:51: PM2 log: Launching in no daemon mode
2020-06-07T08:28:52: PM2 log: App [npm:0] starting in -fork mode-
2020-06-07T08:28:52: PM2 log: App [npm:0] online
> [email protected] start /zigbee2mqtt-1.13.1
> node index.js
zigbee2mqtt:info  2020-06-07 08:28:57: Logging to console and directory: '/share/zigbee2mqtt/log/2020-06-07.08-28-57' filename: log.txt
zigbee2mqtt:info  2020-06-07 08:28:58: Starting zigbee2mqtt version 1.13.1 (commit #unknown)
zigbee2mqtt:info  2020-06-07 08:28:58: Starting zigbee-herdsman...
zigbee2mqtt:info  2020-06-07 08:29:01: zigbee-herdsman started
zigbee2mqtt:info  2020-06-07 08:29:01: Coordinator firmware version: '{"type":"zStack12","meta":{"transportrev":2,"product":0,"majorrel":2,"minorrel":6,"maintrel":3,"revision":20190608}}'
zigbee2mqtt:info  2020-06-07 08:29:01: Currently 1 devices are joined:
zigbee2mqtt:info  2020-06-07 08:29:01: 0xec1bbdfffe66f366 (0xec1bbdfffe66f366): GDKES-03TZXD - TUYATEC Smart light switch - 3 gang without neutral wire (EndDevice)
zigbee2mqtt:info  2020-06-07 08:29:01: Zigbee: disabling joining new devices.
zigbee2mqtt:info  2020-06-07 08:29:01: Connecting to MQTT server at mqtt://core-mosquitto
zigbee2mqtt:info  2020-06-07 08:29:02: Connected to MQTT server
zigbee2mqtt:info  2020-06-07 08:29:02: MQTT publish: topic 'zigbee2mqtt/bridge/state', payload 'online'
zigbee2mqtt:info  2020-06-07 08:29:02: MQTT publish: topic 'zigbee2mqtt/0xec1bbdfffe66f366', payload '{"state_left":"OFF","linkquality":84,"state_center":"OFF","state_right":"ON"}'
zigbee2mqtt:info  2020-06-07 08:29:02: MQTT publish: topic 'zigbee2mqtt/bridge/config', payload '{"version":"1.13.1","commit":"unknown","coordinator":{"type":"zStack12","meta":{"transportrev":2,"product":0,"majorrel":2,"minorrel":6,"maintrel":3,"revision":20190608}},"log_level":"info","permit_join":false}'
zigbee2mqtt:info  2020-06-07 08:29:02: MQTT publish: topic 'homeassistant/switch/0xec1bbdfffe66f366/switch_left/config', payload '{"payload_off":"OFF","payload_on":"ON","value_template":"{{ value_json.state_left }}","command_topic":"zigbee2mqtt/0xec1bbdfffe66f366/left/set","state_topic":"zigbee2mqtt/0xec1bbdfffe66f366","json_attributes_topic":"zigbee2mqtt/0xec1bbdfffe66f366","name":"0xec1bbdfffe66f366_switch_left","unique_id":"0xec1bbdfffe66f366_switch_left_zigbee2mqtt","device":{"identifiers":["zigbee2mqtt_0xec1bbdfffe66f366"],"name":"0xec1bbdfffe66f366","sw_version":"Zigbee2mqtt 1.13.1","model":"Smart light switch - 3 gang without neutral wire (GDKES-03TZXD)","manufacturer":"TUYATEC"},"availability_topic":"zigbee2mqtt/bridge/state"}'
zigbee2mqtt:info  2020-06-07 08:29:02: MQTT publish: topic 'homeassistant/switch/0xec1bbdfffe66f366/switch_center/config', payload '{"payload_off":"OFF","payload_on":"ON","value_template":"{{ value_json.state_center }}","command_topic":"zigbee2mqtt/0xec1bbdfffe66f366/center/set","state_topic":"zigbee2mqtt/0xec1bbdfffe66f366","json_attributes_topic":"zigbee2mqtt/0xec1bbdfffe66f366","name":"0xec1bbdfffe66f366_switch_center","unique_id":"0xec1bbdfffe66f366_switch_center_zigbee2mqtt","device":{"identifiers":["zigbee2mqtt_0xec1bbdfffe66f366"],"name":"0xec1bbdfffe66f366","sw_version":"Zigbee2mqtt 1.13.1","model":"Smart light switch - 3 gang without neutral wire (GDKES-03TZXD)","manufacturer":"TUYATEC"},"availability_topic":"zigbee2mqtt/bridge/state"}'
zigbee2mqtt:info  2020-06-07 08:29:02: MQTT publish: topic 'homeassistant/switch/0xec1bbdfffe66f366/switch_right/config', payload '{"payload_off":"OFF","payload_on":"ON","value_template":"{{ value_json.state_right }}","command_topic":"zigbee2mqtt/0xec1bbdfffe66f366/right/set","state_topic":"zigbee2mqtt/0xec1bbdfffe66f366","json_attributes_topic":"zigbee2mqtt/0xec1bbdfffe66f366","name":"0xec1bbdfffe66f366_switch_right","unique_id":"0xec1bbdfffe66f366_switch_right_zigbee2mqtt","device":{"identifiers":["zigbee2mqtt_0xec1bbdfffe66f366"],"name":"0xec1bbdfffe66f366","sw_version":"Zigbee2mqtt 1.13.1","model":"Smart light switch - 3 gang without neutral wire (GDKES-03TZXD)","manufacturer":"TUYATEC"},"availability_topic":"zigbee2mqtt/bridge/state"}'
zigbee2mqtt:info  2020-06-07 08:29:02: MQTT publish: topic 'homeassistant/sensor/0xec1bbdfffe66f366/linkquality/config', payload '{"icon":"mdi:signal","unit_of_measurement":"lqi","value_template":"{{ value_json.linkquality }}","state_topic":"zigbee2mqtt/0xec1bbdfffe66f366","json_attributes_topic":"zigbee2mqtt/0xec1bbdfffe66f366","name":"0xec1bbdfffe66f366_linkquality","unique_id":"0xec1bbdfffe66f366_linkquality_zigbee2mqtt","device":{"identifiers":["zigbee2mqtt_0xec1bbdfffe66f366"],"name":"0xec1bbdfffe66f366","sw_version":"Zigbee2mqtt 1.13.1","model":"Smart light switch - 3 gang without neutral wire (GDKES-03TZXD)","manufacturer":"TUYATEC"},"availability_topic":"zigbee2mqtt/bridge/state"}'
zigbee2mqtt:info  2020-06-07 08:29:03: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"type":"device_announced","message":"announce","meta":{"friendly_name":"0xec1bbdfffe66f366"}}'
zigbee2mqtt:info  2020-06-07 08:29:18: MQTT publish: topic 'zigbee2mqtt/0xec1bbdfffe66f366', payload '{"state_left":"OFF","linkquality":99,"state_center":"OFF","state_right":"ON"}'

And an hour later, whilst I can’t control anything via HA:

zigbee2mqtt:info  2020-06-07 09:28:25: Logging to console and directory: '/share/zigbee2mqtt/log/2020-06-07.09-28-25' filename: log.txt
zigbee2mqtt:info  2020-06-07 09:28:26: Starting zigbee2mqtt version 1.13.1 (commit #unknown)
zigbee2mqtt:info  2020-06-07 09:28:26: Starting zigbee-herdsman...
zigbee2mqtt:error 2020-06-07 09:28:33: Error while starting zigbee-herdsman
zigbee2mqtt:error 2020-06-07 09:28:33: Failed to start zigbee
zigbee2mqtt:error 2020-06-07 09:28:33: Exiting...
zigbee2mqtt:error 2020-06-07 09:28:33: Error: Failed to connect to the adapter (Error: SRSP - SYS - ping after 6000ms)
    at ZStackAdapter.<anonymous> (/zigbee2mqtt-1.13.1/node_modules/zigbee-herdsman/dist/adapter/z-stack/adapter/zStackAdapter.js:71:23)
    at Generator.throw (<anonymous>)
    at rejected (/zigbee2mqtt-1.13.1/node_modules/zigbee-herdsman/dist/adapter/z-stack/adapter/zStackAdapter.js:6:65)
npm
 ERR! code
 ELIFECYCLE
npm 
ERR! errno 1
npm 
ERR! [email protected] start: `node index.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2020-06-07T08_28_33_391Z-debug.log
2020-06-07T09:28:35: PM2 log: App [npm:0] exited with code [1] via signal [SIGINT]
2020-06-07T09:28:35: PM2 log: App [npm:0] starting in -fork mode-
2020-06-07T09:28:35: PM2 log: App [npm:0] online
> [email protected] start /zigbee2mqtt-1.13.1
> node index.js

TBC, hit the character limit…

The Hassio log shows:

2020-06-07 08:29:01 WARNING (MainThread) [homeassistant.loader] You are using a custom integration for garbage_collection which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant.
2020-06-07 08:29:01 WARNING (MainThread) [homeassistant.loader] You are using a custom integration for hacs which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant.
2020-06-07 08:29:01 WARNING (MainThread) [homeassistant.loader] You are using a custom integration for badnest which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant.
2020-06-07 08:29:03 WARNING (Recorder) [homeassistant.components.recorder] Ended unfinished session (id=110 from 2020-06-07 04:26:47.197642)
2020-06-07 08:29:17 WARNING (MainThread) [homeassistant.setup] Setup of badnest is taking over 10 seconds.
2020-06-07 08:29:18 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-06-07 08:29:18 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start TI_CC: CC2531, CC2530, CC2652R, CC1352 etc, Texas Instruments ZNP protocol coordinator
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 141, in async_initialize
    app_config, auto_form=True, start_radio=True
  File "/usr/local/lib/python3.7/site-packages/zigpy/application.py", line 65, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 92, in startup
    self.version = await self._api.version()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 241, in version
    version = await self._command(Subsystem.SYS, "version", {})
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 103, in _command
    return await self.request(subsystem, command, payload)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 107, in request
    return await self.request_raw(obj, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 129, in request_raw
    result = await waiter.wait()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 39, in wait
    return await asyncio.wait_for(self.future, self.timeout / 1000)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 449, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError
2020-06-07 08:29:18 WARNING (MainThread) [homeassistant.config_entries] Config entry for zha not ready yet. Retrying in 5 seconds.
2020-06-07 08:29:18 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.SYS command=version payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:29:24 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up coronavirus platform for sensor
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 186, in _async_setup_platform
    await asyncio.gather(*pending)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 295, in async_add_entities
    await asyncio.gather(*tasks)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 446, in _async_add_entity
    entity.async_write_ha_state()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 297, in async_write_ha_state
    self._async_write_ha_state()  # type: ignore
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 320, in _async_write_ha_state
    state = self.state
  File "/usr/src/homeassistant/homeassistant/components/coronavirus/sensor.py", line 55, in state
    getattr(case, self.info_type) for case in self.coordinator.data.values()
  File "/usr/src/homeassistant/homeassistant/components/coronavirus/sensor.py", line 55, in <genexpr>
    getattr(case, self.info_type) for case in self.coordinator.data.values()
  File "/usr/local/lib/python3.7/site-packages/coronavirus/__init__.py", line 25, in current
    return self.confirmed - self.deaths - self.recovered
TypeError: unsupported operand type(s) for -: 'int' and 'NoneType'
2020-06-07 08:29:37 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-06-07 08:29:37 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start TI_CC: CC2531, CC2530, CC2652R, CC1352 etc, Texas Instruments ZNP protocol coordinator
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 141, in async_initialize
    app_config, auto_form=True, start_radio=True
  File "/usr/local/lib/python3.7/site-packages/zigpy/application.py", line 65, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 92, in startup
    self.version = await self._api.version()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 241, in version
    version = await self._command(Subsystem.SYS, "version", {})
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 103, in _command
    return await self.request(subsystem, command, payload)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 107, in request
    return await self.request_raw(obj, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 129, in request_raw
    result = await waiter.wait()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 39, in wait
    return await asyncio.wait_for(self.future, self.timeout / 1000)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 449, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError
2020-06-07 08:29:37 WARNING (MainThread) [homeassistant.config_entries] Config entry for zha not ready yet. Retrying in 10 seconds.
2020-06-07 08:29:37 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.SYS command=version payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:29:58 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-06-07 08:29:58 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start TI_CC: CC2531, CC2530, CC2652R, CC1352 etc, Texas Instruments ZNP protocol coordinator
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 141, in async_initialize
    app_config, auto_form=True, start_radio=True
  File "/usr/local/lib/python3.7/site-packages/zigpy/application.py", line 65, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 92, in startup
    self.version = await self._api.version()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 241, in version
    version = await self._command(Subsystem.SYS, "version", {})
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 103, in _command
    return await self.request(subsystem, command, payload)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 107, in request
    return await self.request_raw(obj, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 129, in request_raw
    result = await waiter.wait()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 39, in wait
    return await asyncio.wait_for(self.future, self.timeout / 1000)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 449, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError
2020-06-07 08:29:58 WARNING (MainThread) [homeassistant.config_entries] Config entry for zha not ready yet. Retrying in 20 seconds.
2020-06-07 08:29:58 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.SYS command=version payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:30:25 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-06-07 08:30:25 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start TI_CC: CC2531, CC2530, CC2652R, CC1352 etc, Texas Instruments ZNP protocol coordinator
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 141, in async_initialize
    app_config, auto_form=True, start_radio=True
  File "/usr/local/lib/python3.7/site-packages/zigpy/application.py", line 65, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 92, in startup
    self.version = await self._api.version()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 241, in version
    version = await self._command(Subsystem.SYS, "version", {})
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 103, in _command
    return await self.request(subsystem, command, payload)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 107, in request
    return await self.request_raw(obj, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 129, in request_raw
    result = await waiter.wait()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 39, in wait
    return await asyncio.wait_for(self.future, self.timeout / 1000)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 449, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError
2020-06-07 08:30:25 WARNING (MainThread) [homeassistant.config_entries] Config entry for zha not ready yet. Retrying in 40 seconds.
2020-06-07 08:30:26 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.SYS command=version payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:31:13 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-06-07 08:31:13 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start TI_CC: CC2531, CC2530, CC2652R, CC1352 etc, Texas Instruments ZNP protocol coordinator
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 141, in async_initialize
    app_config, auto_form=True, start_radio=True
  File "/usr/local/lib/python3.7/site-packages/zigpy/application.py", line 65, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 92, in startup
    self.version = await self._api.version()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 241, in version
    version = await self._command(Subsystem.SYS, "version", {})
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 103, in _command
    return await self.request(subsystem, command, payload)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 107, in request
    return await self.request_raw(obj, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 129, in request_raw
    result = await waiter.wait()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 39, in wait
    return await asyncio.wait_for(self.future, self.timeout / 1000)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 449, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError
2020-06-07 08:31:13 WARNING (MainThread) [homeassistant.config_entries] Config entry for zha not ready yet. Retrying in 80 seconds.
2020-06-07 08:31:13 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.SYS command=version payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:32:41 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-06-07 08:32:41 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start TI_CC: CC2531, CC2530, CC2652R, CC1352 etc, Texas Instruments ZNP protocol coordinator
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 141, in async_initialize
    app_config, auto_form=True, start_radio=True
  File "/usr/local/lib/python3.7/site-packages/zigpy/application.py", line 65, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 92, in startup
    self.version = await self._api.version()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 241, in version
    version = await self._command(Subsystem.SYS, "version", {})
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 103, in _command
    return await self.request(subsystem, command, payload)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 107, in request
    return await self.request_raw(obj, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 129, in request_raw
    result = await waiter.wait()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 39, in wait
    return await asyncio.wait_for(self.future, self.timeout / 1000)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 449, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError
2020-06-07 08:32:41 WARNING (MainThread) [homeassistant.config_entries] Config entry for zha not ready yet. Retrying in 80 seconds.
2020-06-07 08:32:41 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.SYS command=version payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:34:09 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-06-07 08:34:09 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start TI_CC: CC2531, CC2530, CC2652R, CC1352 etc, Texas Instruments ZNP protocol coordinator
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 141, in async_initialize
    app_config, auto_form=True, start_radio=True
  File "/usr/local/lib/python3.7/site-packages/zigpy/application.py", line 65, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 92, in startup
    self.version = await self._api.version()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 241, in version
    version = await self._command(Subsystem.SYS, "version", {})
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 103, in _command
    return await self.request(subsystem, command, payload)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 107, in request
    return await self.request_raw(obj, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 129, in request_raw
    result = await waiter.wait()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 39, in wait
    return await asyncio.wait_for(self.future, self.timeout / 1000)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 449, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError
2020-06-07 08:34:09 WARNING (MainThread) [homeassistant.config_entries] Config entry for zha not ready yet. Retrying in 80 seconds.
2020-06-07 08:34:09 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.SYS command=version payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:35:37 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-06-07 08:35:37 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start TI_CC: CC2531, CC2530, CC2652R, CC1352 etc, Texas Instruments ZNP protocol coordinator
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 141, in async_initialize
    app_config, auto_form=True, start_radio=True
  File "/usr/local/lib/python3.7/site-packages/zigpy/application.py", line 65, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 92, in startup
    self.version = await self._api.version()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 241, in version
    version = await self._command(Subsystem.SYS, "version", {})
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 103, in _command
    return await self.request(subsystem, command, payload)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 107, in request
    return await self.request_raw(obj, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 129, in request_raw
    result = await waiter.wait()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 39, in wait
    return await asyncio.wait_for(self.future, self.timeout / 1000)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 449, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError
2020-06-07 08:35:37 WARNING (MainThread) [homeassistant.config_entries] Config entry for zha not ready yet. Retrying in 80 seconds.
2020-06-07 08:35:37 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.SYS command=version payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:37:05 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-06-07 08:37:05 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start TI_CC: CC2531, CC2530, CC2652R, CC1352 etc, Texas Instruments ZNP protocol coordinator
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 141, in async_initialize
    app_config, auto_form=True, start_radio=True
  File "/usr/local/lib/python3.7/site-packages/zigpy/application.py", line 65, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 97, in startup
    await self.form_network()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 118, in form_network
    self._api, self.version["product"], options, 0x0B84, backupPath
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/start_znp.py", line 262, in start_znp
    expected_status=[0, 2],
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/start_znp.py", line 73, in validate_item
    result = await znp.request(subsystem, command, item, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 107, in request
    return await self.request_raw(obj, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 129, in request_raw
    result = await waiter.wait()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 39, in wait
    return await asyncio.wait_for(self.future, self.timeout / 1000)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 449, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError
2020-06-07 08:37:05 WARNING (MainThread) [homeassistant.config_entries] Config entry for zha not ready yet. Retrying in 80 seconds.
2020-06-07 08:37:05 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.SYS command=osalNvRead payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:38:33 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-06-07 08:38:33 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start TI_CC: CC2531, CC2530, CC2652R, CC1352 etc, Texas Instruments ZNP protocol coordinator
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 141, in async_initialize
    app_config, auto_form=True, start_radio=True
  File "/usr/local/lib/python3.7/site-packages/zigpy/application.py", line 65, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 92, in startup
    self.version = await self._api.version()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 241, in version
    version = await self._command(Subsystem.SYS, "version", {})
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 103, in _command
    return await self.request(subsystem, command, payload)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 107, in request
    return await self.request_raw(obj, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 129, in request_raw
    result = await waiter.wait()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 39, in wait
    return await asyncio.wait_for(self.future, self.timeout / 1000)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 449, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError
2020-06-07 08:38:33 WARNING (MainThread) [homeassistant.config_entries] Config entry for zha not ready yet. Retrying in 80 seconds.
2020-06-07 08:38:33 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.SYS command=version payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:40:01 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-06-07 08:40:01 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start TI_CC: CC2531, CC2530, CC2652R, CC1352 etc, Texas Instruments ZNP protocol coordinator
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 141, in async_initialize
    app_config, auto_form=True, start_radio=True
  File "/usr/local/lib/python3.7/site-packages/zigpy/application.py", line 65, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 97, in startup
    await self.form_network()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 118, in form_network
    self._api, self.version["product"], options, 0x0B84, backupPath
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/start_znp.py", line 262, in start_znp
    expected_status=[0, 2],
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/start_znp.py", line 73, in validate_item
    result = await znp.request(subsystem, command, item, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 107, in request
    return await self.request_raw(obj, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 129, in request_raw
    result = await waiter.wait()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 39, in wait
    return await asyncio.wait_for(self.future, self.timeout / 1000)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 449, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError
2020-06-07 08:40:01 WARNING (MainThread) [homeassistant.config_entries] Config entry for zha not ready yet. Retrying in 80 seconds.
2020-06-07 08:40:01 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.SYS command=osalNvRead payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:41:29 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-06-07 08:41:29 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start TI_CC: CC2531, CC2530, CC2652R, CC1352 etc, Texas Instruments ZNP protocol coordinator
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 141, in async_initialize
    app_config, auto_form=True, start_radio=True
  File "/usr/local/lib/python3.7/site-packages/zigpy/application.py", line 65, in new
    await app.startup(auto_form)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/zigbee/application.py", line 92, in startup
    self.version = await self._api.version()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 241, in version
    version = await self._command(Subsystem.SYS, "version", {})
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 103, in _command
    return await self.request(subsystem, command, payload)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 107, in request
    return await self.request_raw(obj, expected_status)
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 129, in request_raw
    result = await waiter.wait()
  File "/usr/local/lib/python3.7/site-packages/zigpy_cc/api.py", line 39, in wait
    return await asyncio.wait_for(self.future, self.timeout / 1000)
  File "/usr/local/lib/python3.7/asyncio/tasks.py", line 449, in wait_for
    raise futures.TimeoutError()
concurrent.futures._base.TimeoutError
2020-06-07 08:41:29 WARNING (MainThread) [homeassistant.config_entries] Config entry for zha not ready yet. Retrying in 80 seconds.
2020-06-07 08:41:29 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.SYS command=version payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:44:15 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.AREQ subsystem=Subsystem.AF command=dataConfirm payload={'endpoint': 1, 'transid': 8}> future=<Future cancelled> timeout=10000 sequence=None>
2020-06-07 08:44:39 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.AF command=dataRequest payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:44:40 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.AF command=dataRequest payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:46:15 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection.2807399792] Error handling message: Timeout
2020-06-07 08:46:15 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.ZDO command=mgmtPermitJoinReq payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:48:49 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.AF command=dataRequest payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:48:55 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.AF command=dataRequest payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:49:01 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.AF command=dataRequest payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:49:04 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.AF command=dataRequest payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:49:10 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.AF command=dataRequest payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:49:15 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.AF command=dataRequest payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:49:20 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.AF command=dataRequest payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:49:25 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.AF command=dataRequest payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 09:29:24 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 111, in _handle_refresh_interval
    await self.async_refresh()
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 177, in async_refresh
    update_callback()
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 297, in async_write_ha_state
    self._async_write_ha_state()  # type: ignore
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 320, in _async_write_ha_state
    state = self.state
  File "/usr/src/homeassistant/homeassistant/components/coronavirus/sensor.py", line 55, in state
    getattr(case, self.info_type) for case in self.coordinator.data.values()
  File "/usr/src/homeassistant/homeassistant/components/coronavirus/sensor.py", line 55, in <genexpr>
    getattr(case, self.info_type) for case in self.coordinator.data.values()
  File "/usr/local/lib/python3.7/site-packages/coronavirus/__init__.py", line 25, in current
    return self.confirmed - self.deaths - self.recovered
TypeError: unsupported operand type(s) for -: 'int' and 'NoneType'

Hit the character limit, with a vengeance, final reply below.

My zigbee2mqtt config is the default, only changes being the username and password for the MQTT user setup in Hassio.

data_path: /share/zigbee2mqtt
devices: devices.yaml
groups: groups.yaml
homeassistant: true
permit_join: false
mqtt:
  base_topic: zigbee2mqtt
  server: 'mqtt://core-mosquitto'
  user: <REDACTED>
  password: '<REDACTED>'
serial:
  port: /dev/ttyACM0
advanced:
  pan_id: 6754
  channel: 11
  network_key:
    - 1
    - 3
    - 5
    - 7
    - 9
    - 11
    - 13
    - 15
    - 0
    - 2
    - 4
    - 6
    - 8
    - 10
    - 12
    - 13
  availability_blacklist: []
ban: []
whitelist: []
queue: {}
socat:
  enabled: false
  master: 'pty,raw,echo=0,link=/dev/ttyZ2M,mode=777'
  slave: 'tcp-listen:8485,keepalive,nodelay,reuseaddr,keepidle=1,keepintvl=1,keepcnt=5'
  restartdelay: 1
  initialdelay: 1
  options: '-d -d'
  log: false

And with debug logging enabled:

[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] done.
[services.d] starting services
[services.d] done.
./run.sh: line 17: [Info] Configuration backup found in /share/zigbee2mqtt/.configuration.yaml.bk. Skipping config backup.: No such file or directory
[Info] Socat is DISABLED and not started
2020-06-07T10:03:59: PM2 log: Launching in no daemon mode
2020-06-07T10:03:59: PM2 log: App [npm:0] starting in -fork mode-
2020-06-07T10:03:59: PM2 log: App [npm:0] online
> [email protected] start /zigbee2mqtt-1.13.1
> node index.js
zigbee2mqtt:info  2020-06-07 10:04:02: Logging to console and directory: '/share/zigbee2mqtt/log/2020-06-07.10-04-02' filename: log.txt
zigbee2mqtt:debug 2020-06-07 10:04:02: Removing old log directory '/share/zigbee2mqtt/log/2020-06-07.10-01-51'
zigbee2mqtt:debug 2020-06-07 10:04:02: Loaded state from file /share/zigbee2mqtt/state.json
zigbee2mqtt:info  2020-06-07 10:04:02: Starting zigbee2mqtt version 1.13.1 (commit #unknown)
zigbee2mqtt:info  2020-06-07 10:04:02: Starting zigbee-herdsman...
zigbee2mqtt:debug 2020-06-07 10:04:02: Using zigbee-herdsman with settings: '{"network":{"panID":6754,"extendedPanID":[221,221,221,221,221,221,221,221],"channelList":[11],"networkKey":"HIDDEN"},"databasePath":"/share/zigbee2mqtt/database.db","databaseBackupPath":"/share/zigbee2mqtt/database.db.backup","backupPath":"/share/zigbee2mqtt/coordinator_backup.json","serialPort":{"baudRate":115200,"rtscts":true,"path":"/dev/ttyACM0"},"adapter":{"concurrent":null}}'
zigbee2mqtt:error 2020-06-07 10:04:10: Error while starting zigbee-herdsman
zigbee2mqtt:error 2020-06-07 10:04:10: Failed to start zigbee
zigbee2mqtt:error 2020-06-07 10:04:10: Exiting...
zigbee2mqtt:error 2020-06-07 10:04:10: Error: Failed to connect to the adapter (Error: SRSP - SYS - ping after 6000ms)
    at ZStackAdapter.<anonymous> (/zigbee2mqtt-1.13.1/node_modules/zigbee-herdsman/dist/adapter/z-stack/adapter/zStackAdapter.js:71:23)
    at Generator.throw (<anonymous>)
    at rejected (/zigbee2mqtt-1.13.1/node_modules/zigbee-herdsman/dist/adapter/z-stack/adapter/zStackAdapter.js:6:65)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm
 ERR! [email protected] start: `node index.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2020-06-07T09_04_10_143Z-debug.log
2020-06-07T10:04:11: PM2 log: App [npm:0] exited with code [1] via signal [SIGINT]
2020-06-07T10:04:11: PM2 log: App [npm:0] starting in -fork mode-
2020-06-07T10:04:11: PM2 log: App [npm:0] online
> [email protected] start /zigbee2mqtt-1.13.1
> node index.js

I’ve no other USB devices connected to my RPi 4 and changing USB port results in the same problem.

Hopefully I’ve covered everything but if not please ask and I’ll post it or try it ASAP.

Thanks,

Sy

Don’t understand what you are doing :

This hassio log shows you try to use your CC2531 with ZHA

2020-06-07 08:32:41 WARNING (MainThread) [zigpy_cc.api] Waiter timeout: <Waiter matcher=<Matcher type=CommandType.SRSP subsystem=Subsystem.SYS command=version payload={}> future=<Future cancelled> timeout=6000 sequence=None>
2020-06-07 08:34:09 ERROR (MainThread) [zigpy.application] Couldn't start application
2020-06-07 08:34:09 ERROR (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start TI_CC: CC2531, CC2530, CC2652R, CC1352 etc, Texas Instruments ZNP protocol coordinator

But you complain zigbee2mqtt loses connection after one hour :

zigbee2mqtt:error 2020-06-07 09:28:33: Error: Failed to connect to the adapter (Error: SRSP - SYS - ping after 6000ms)
    at ZStackAdapter.<anonymous> (/zigbee2mqtt-1.13.1/node_modules/zigbee-herdsman/dist/adapter/z-stack/adapter/zStackAdapter.js:71:23)
    at Generator.throw (<anonymous>)
    at rejected (/zigbee2mqtt-1.13.1/node_modules/zigbee-herdsman/dist/adapter/z-stack/adapter/zStackAdapter.js:6:65)
npm

It seems you try to use the same adapter with both ZHA and Zigbee2MQTT. That does not work. Use your CC2531 with either ZHA or Zigbee2MQTT.

3 Likes

Ah, now that makes sense, I thought I’d need to have the Zigbee integration installed also because…well Zigbee and that’s answered another question I had.

I’ll uninstall it now, reboot, pull the USB and give it another test. Trust me, I don’t understand what I’m doing either! :joy:

Thanks, I’ll report back.

Yup, looks like that and, more so, user error were to blame. Thanks for the help, @francisp!

I cant start Zigbee2mqtt. Here is log file

Zigbee2MQTT:debug 2021-03-12 12:53:29: Loaded state from file /config/zigbee2mqtt/state.json
Zigbee2MQTT:info  2021-03-12 12:53:29: Logging to console and directory: '/config/zigbee2mqtt/log/2021-03-12.12-53-28' filename: log.txt
Zigbee2MQTT:debug 2021-03-12 12:53:29: Removing old log directory '/config/zigbee2mqtt/log/2021-03-12.12-52-41'
Zigbee2MQTT:info  2021-03-12 12:53:30: Starting Zigbee2MQTT version 1.18.1 (commit #1.18.1)
Zigbee2MQTT:info  2021-03-12 12:53:30: Starting zigbee-herdsman (0.13.71)
Zigbee2MQTT:debug 2021-03-12 12:53:30: Using zigbee-herdsman with settings: '{"adapter":{"concurrent":null,"delay":null},"backupPath":"/config/zigbee2mqtt/coordinator_backup.json","databaseBackupPath":"/config/zigbee2mqtt/database.db.backup","databasePath":"/config/zigbee2mqtt/database.db","network":{"channelList":[11],"extendedPanID":[221,221,221,221,221,221,221,221],"networkKey":"HIDDEN","panID":6754},"serialPort":{"path":"/dev/serial/by-id/usb-Texas_Instruments_TI_CC2531_USB_CDC___0X00124B0018E33078-if00"}}'
Zigbee2MQTT:error 2021-03-12 12:53:30: Error while starting zigbee-herdsman
Zigbee2MQTT:error 2021-03-12 12:53:30: Failed to start zigbee
Zigbee2MQTT:error 2021-03-12 12:53:30: Exiting...
Zigbee2MQTT:error 2021-03-12 12:53:30: Error: Error while opening serialport 'Error: Error: No such file or directory, cannot open /dev/serial/by-id/usb-Texas_Instruments_TI_CC2531_USB_CDC___0X00124B0018E33078-if00'
    at Znp.<anonymous> (/app/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:136:32)
    at Generator.next (<anonymous>)
    at /app/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:27:71
    at new Promise (<anonymous>)
    at __awaiter (/app/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:23:12)
    at SerialPort.<anonymous> (/app/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:134:49)
    at SerialPort._error (/app/node_modules/zigbee-herdsman/node_modules/@serialport/stream/lib/index.js:198:14)
    at /app/node_modules/zigbee-herdsman/node_modules/@serialport/stream/lib/index.js:242:12
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] start: `node index.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2021-03-12T10_53_30_352Z-debug.log
[12:53:30] INFO: Handing over control to Zigbee2mqtt Core ...
> [email protected] start /app
> node index.js
Zigbee2MQTT:debug 2021-03-12 12:53:34: Loaded state from file /config/zigbee2mqtt/state.json
Zigbee2MQTT:info  2021-03-12 12:53:34: Logging to console and directory: '/config/zigbee2mqtt/log/2021-03-12.12-53-33' filename: log.txt
Zigbee2MQTT:debug 2021-03-12 12:53:34: Removing old log directory '/config/zigbee2mqtt/log/2021-03-12.12-52-45'
Zigbee2MQTT:info  2021-03-12 12:53:34: Starting Zigbee2MQTT version 1.18.1 (commit #1.18.1)
Zigbee2MQTT:info  2021-03-12 12:53:34: Starting zigbee-herdsman (0.13.71)
Zigbee2MQTT:debug 2021-03-12 12:53:34: Using zigbee-herdsman with settings: '{"adapter":{"concurrent":null,"delay":null},"backupPath":"/config/zigbee2mqtt/coordinator_backup.json","databaseBackupPath":"/config/zigbee2mqtt/database.db.backup","databasePath":"/config/zigbee2mqtt/database.db","network":{"channelList":[11],"extendedPanID":[221,221,221,221,221,221,221,221],"networkKey":"HIDDEN","panID":6754},"serialPort":{"path":"/dev/serial/by-id/usb-Texas_Instruments_TI_CC2531_USB_CDC___0X00124B0018E33078-if00"}}'
Zigbee2MQTT:error 2021-03-12 12:53:34: Error while starting zigbee-herdsman
Zigbee2MQTT:error 2021-03-12 12:53:34: Failed to start zigbee
Zigbee2MQTT:error 2021-03-12 12:53:34: Exiting...
Zigbee2MQTT:error 2021-03-12 12:53:34: Error: Error while opening serialport 'Error: Error: No such file or directory, cannot open /dev/serial/by-id/usb-Texas_Instruments_TI_CC2531_USB_CDC___0X00124B0018E33078-if00'
    at Znp.<anonymous> (/app/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:136:32)
    at Generator.next (<anonymous>)
    at /app/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:27:71
    at new Promise (<anonymous>)
    at __awaiter (/app/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:23:12)
    at SerialPort.<anonymous> (/app/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:134:49)
    at SerialPort._error (/app/node_modules/zigbee-herdsman/node_modules/@serialport/stream/lib/index.js:198:14)
    at /app/node_modules/zigbee-herdsman/node_modules/@serialport/stream/lib/index.js:242:12
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] start: `node index.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2021-03-12T10_53_35_026Z-debug.log
[12:53:35] INFO: Handing over control to Zigbee2mqtt Core ...
> [email protected] start /app
> node index.js
Zigbee2MQTT:debug 2021-03-12 12:53:39: Loaded state from file /config/zigbee2mqtt/state.json
Zigbee2MQTT:info  2021-03-12 12:53:39: Logging to console and directory: '/config/zigbee2mqtt/log/2021-03-12.12-53-37' filename: log.txt
Zigbee2MQTT:debug 2021-03-12 12:53:39: Removing old log directory '/config/zigbee2mqtt/log/2021-03-12.12-52-50'
Zigbee2MQTT:info  2021-03-12 12:53:39: Starting Zigbee2MQTT version 1.18.1 (commit #1.18.1)
Zigbee2MQTT:info  2021-03-12 12:53:39: Starting zigbee-herdsman (0.13.71)
Zigbee2MQTT:debug 2021-03-12 12:53:39: Using zigbee-herdsman with settings: '{"adapter":{"concurrent":null,"delay":null},"backupPath":"/config/zigbee2mqtt/coordinator_backup.json","databaseBackupPath":"/config/zigbee2mqtt/database.db.backup","databasePath":"/config/zigbee2mqtt/database.db","network":{"channelList":[11],"extendedPanID":[221,221,221,221,221,221,221,221],"networkKey":"HIDDEN","panID":6754},"serialPort":{"path":"/dev/serial/by-id/usb-Texas_Instruments_TI_CC2531_USB_CDC___0X00124B0018E33078-if00"}}'
Zigbee2MQTT:error 2021-03-12 12:53:39: Error while starting zigbee-herdsman
Zigbee2MQTT:error 2021-03-12 12:53:39: Failed to start zigbee
Zigbee2MQTT:error 2021-03-12 12:53:39: Exiting...
Zigbee2MQTT:error 2021-03-12 12:53:39: Error: Error while opening serialport 'Error: Error: No such file or directory, cannot open /dev/serial/by-id/usb-Texas_Instruments_TI_CC2531_USB_CDC___0X00124B0018E33078-if00'
    at Znp.<anonymous> (/app/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:136:32)
    at Generator.next (<anonymous>)
    at /app/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:27:71
    at new Promise (<anonymous>)
    at __awaiter (/app/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:23:12)
    at SerialPort.<anonymous> (/app/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:134:49)
    at SerialPort._error (/app/node_modules/zigbee-herdsman/node_modules/@serialport/stream/lib/index.js:198:14)
    at /app/node_modules/zigbee-herdsman/node_modules/@serialport/stream/lib/index.js:242:12
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] start: `node index.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2021-03-12T10_53_39_629Z-debug.log
[12:53:39] INFO: Handing over control to Zigbee2mqtt Core ...
> [email protected] start /app
> node index.js

here is configuration

data_path: /config/zigbee2mqtt
external_converters: []
devices: devices.yaml
groups: groups.yaml
homeassistant: true
permit_join: true
mqtt:
  base_topic: zigbee2mqtt
  server: 'mqtt://192.168.10.230:1883'
  user: mqtt
  password: '********'
serial:
  port: >-
    /dev/serial/by-id/usb-Texas_Instruments_TI_CC2531_USB_CDC___0X00124B0018E33078-if00
advanced:
  log_level: debug
  pan_id: 6754
  channel: 11
  network_key:
    - 1
    - 3
    - 5
    - 7
    - 9
    - 11
    - 13
    - 15
    - 0
    - 2
    - 4
    - 6
    - 8
    - 10
    - 12
    - 13
  availability_blocklist: []
  availability_passlist: []
device_options: {}
blocklist: []
passlist: []
queue: {}
frontend:
  port: 8099
experimental: {}
socat:
  enabled: false
  master: 'pty,raw,echo=0,link=/tmp/ttyZ2M,mode=777'
  slave: 'tcp-listen:8485,keepalive,nodelay,reuseaddr,keepidle=1,keepintvl=1,keepcnt=5'
  options: '-d -d'
  log: false

I had this error, one time I solved it by reflashing the sniffer.

Just happened to me.
I have two CC2531 with antenna, and both refused to work (i use only one - one is for backup).
I reflashed them like they say here and now everything is back to normal.

The same here: Error while starting zigbee-herdsman :frowning:
Does anyone know how to fix it, please?

Same for me! I can’t find any solutions!