home-assistant / core

:house_with_garden: Open source home automation that puts local control and privacy first.
https://www.home-assistant.io
Apache License 2.0
73.23k stars 30.58k forks source link

Unable to setup Sky Connect #86638

Closed DarthGaymer closed 1 year ago

DarthGaymer commented 1 year ago

The problem

Recently received Sky Connect. When trying to set up with included USB extention, Home Assistant errors out and is unable to start/set it up. This continues with all USB ports, and two other USB extention cords (both work with Zwave stick). This issue also persists through hardware restarts. Error log attached.

What version of Home Assistant Core has the issue?

2023.1.7

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant OS

Integration causing the issue

ZHA

Link to integration documentation on our website

No response

Diagnostics information

home-assistant_zha_2023-01-25T19-01-30.354Z.log

Example YAML snippet

No response

Anything in the logs that might be useful for us?

2023-01-25 02:15:23.085 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration keymaster 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
2023-01-25 02:15:23.088 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration 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
2023-01-25 02:15:46.378 ERROR (MainThread) [zigpy.application] Couldn't start application
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 456, in wait_for
    return fut.result()
asyncio.exceptions.CancelledError

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

Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/zigpy/application.py", line 145, in startup
    await self.connect()
  File "/usr/local/lib/python3.10/site-packages/bellows/zigbee/application.py", line 124, in connect
    self._ezsp = await bellows.ezsp.EZSP.initialize(self.config)
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 104, in initialize
    await ezsp._startup_reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 95, in _startup_reset
    await self.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 124, in reset
    await self._gw.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/uart.py", line 251, in reset
    return await asyncio.wait_for(self._reset_future, timeout=RESET_TIMEOUT)
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 458, in wait_for
    raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError
2023-01-25 02:15:46.399 WARNING (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start EZSP = Silicon Labs EmberZNet protocol: Elelabs, HUSBZB-1, Telegesis coordinator (attempt 1 of 3)
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 456, in wait_for
    return 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 174, in async_initialize
    self.application_controller = await app_controller_cls.new(
  File "/usr/local/lib/python3.10/site-packages/zigpy/application.py", line 169, in new
    await app.startup(auto_form=auto_form)
  File "/usr/local/lib/python3.10/site-packages/zigpy/application.py", line 145, in startup
    await self.connect()
  File "/usr/local/lib/python3.10/site-packages/bellows/zigbee/application.py", line 124, in connect
    self._ezsp = await bellows.ezsp.EZSP.initialize(self.config)
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 104, in initialize
    await ezsp._startup_reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 95, in _startup_reset
    await self.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 124, in reset
    await self._gw.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/uart.py", line 251, in reset
    return await asyncio.wait_for(self._reset_future, timeout=RESET_TIMEOUT)
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 458, in wait_for
    raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError
2023-01-25 02:15:54.471 ERROR (MainThread) [zigpy.application] Couldn't start application
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 456, in wait_for
    return fut.result()
asyncio.exceptions.CancelledError

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

Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/zigpy/application.py", line 145, in startup
    await self.connect()
  File "/usr/local/lib/python3.10/site-packages/bellows/zigbee/application.py", line 124, in connect
    self._ezsp = await bellows.ezsp.EZSP.initialize(self.config)
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 104, in initialize
    await ezsp._startup_reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 95, in _startup_reset
    await self.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 124, in reset
    await self._gw.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/uart.py", line 251, in reset
    return await asyncio.wait_for(self._reset_future, timeout=RESET_TIMEOUT)
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 458, in wait_for
    raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError
2023-01-25 02:15:54.486 WARNING (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start EZSP = Silicon Labs EmberZNet protocol: Elelabs, HUSBZB-1, Telegesis coordinator (attempt 2 of 3)
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 456, in wait_for
    return 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 174, in async_initialize
    self.application_controller = await app_controller_cls.new(
  File "/usr/local/lib/python3.10/site-packages/zigpy/application.py", line 169, in new
    await app.startup(auto_form=auto_form)
  File "/usr/local/lib/python3.10/site-packages/zigpy/application.py", line 145, in startup
    await self.connect()
  File "/usr/local/lib/python3.10/site-packages/bellows/zigbee/application.py", line 124, in connect
    self._ezsp = await bellows.ezsp.EZSP.initialize(self.config)
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 104, in initialize
    await ezsp._startup_reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 95, in _startup_reset
    await self.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 124, in reset
    await self._gw.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/uart.py", line 251, in reset
    return await asyncio.wait_for(self._reset_future, timeout=RESET_TIMEOUT)
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 458, in wait_for
    raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError
2023-01-25 02:16:02.559 ERROR (MainThread) [zigpy.application] Couldn't start application
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 456, in wait_for
    return fut.result()
asyncio.exceptions.CancelledError

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

Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/zigpy/application.py", line 145, in startup
    await self.connect()
  File "/usr/local/lib/python3.10/site-packages/bellows/zigbee/application.py", line 124, in connect
    self._ezsp = await bellows.ezsp.EZSP.initialize(self.config)
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 104, in initialize
    await ezsp._startup_reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 95, in _startup_reset
    await self.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 124, in reset
    await self._gw.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/uart.py", line 251, in reset
    return await asyncio.wait_for(self._reset_future, timeout=RESET_TIMEOUT)
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 458, in wait_for
    raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError
2023-01-25 02:16:02.576 WARNING (MainThread) [homeassistant.components.zha.core.gateway] Couldn't start EZSP = Silicon Labs EmberZNet protocol: Elelabs, HUSBZB-1, Telegesis coordinator (attempt 3 of 3)
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 456, in wait_for
    return 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 174, in async_initialize
    self.application_controller = await app_controller_cls.new(
  File "/usr/local/lib/python3.10/site-packages/zigpy/application.py", line 169, in new
    await app.startup(auto_form=auto_form)
  File "/usr/local/lib/python3.10/site-packages/zigpy/application.py", line 145, in startup
    await self.connect()
  File "/usr/local/lib/python3.10/site-packages/bellows/zigbee/application.py", line 124, in connect
    self._ezsp = await bellows.ezsp.EZSP.initialize(self.config)
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 104, in initialize
    await ezsp._startup_reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 95, in _startup_reset
    await self.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 124, in reset
    await self._gw.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/uart.py", line 251, in reset
    return await asyncio.wait_for(self._reset_future, timeout=RESET_TIMEOUT)
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 458, in wait_for
    raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError
2023-01-25 02:16:02.581 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry SkyConnect v1.0 for zha
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 456, in wait_for
    return 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/config_entries.py", line 382, in async_setup
    result = await component.async_setup_entry(hass, self)
  File "/usr/src/homeassistant/homeassistant/components/zha/__init__.py", line 111, in async_setup_entry
    await zha_gateway.async_initialize()
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 189, in async_initialize
    raise exc
  File "/usr/src/homeassistant/homeassistant/components/zha/core/gateway.py", line 174, in async_initialize
    self.application_controller = await app_controller_cls.new(
  File "/usr/local/lib/python3.10/site-packages/zigpy/application.py", line 169, in new
    await app.startup(auto_form=auto_form)
  File "/usr/local/lib/python3.10/site-packages/zigpy/application.py", line 145, in startup
    await self.connect()
  File "/usr/local/lib/python3.10/site-packages/bellows/zigbee/application.py", line 124, in connect
    self._ezsp = await bellows.ezsp.EZSP.initialize(self.config)
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 104, in initialize
    await ezsp._startup_reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 95, in _startup_reset
    await self.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/ezsp/__init__.py", line 124, in reset
    await self._gw.reset()
  File "/usr/local/lib/python3.10/site-packages/bellows/uart.py", line 251, in reset
    return await asyncio.wait_for(self._reset_future, timeout=RESET_TIMEOUT)
  File "/usr/local/lib/python3.10/asyncio/tasks.py", line 458, in wait_for
    raise exceptions.TimeoutError() from exc
asyncio.exceptions.TimeoutError
2023-01-25 02:16:03.094 WARNING (MainThread) [homeassistant.config_entries] Config entry 'Home Assistant Sky Connect' for homeassistant_sky_connect integration not ready yet: None; Retrying in background
2023-01-25 02:16:29.246 WARNING (MainThread) [homeassistant.bootstrap] Waiting on integrations to complete setup: myq
2023-01-25 02:17:29.337 WARNING (MainThread) [homeassistant.bootstrap] Waiting on integrations to complete setup: myq
2023-01-25 02:18:29.424 WARNING (MainThread) [homeassistant.bootstrap] Waiting on integrations to complete setup: myq
2023-01-25 02:19:17.268 ERROR (MainThread) [homeassistant.config_entries] Cannot find integration otbr
2023-01-25 02:19:17.277 ERROR (MainThread) [homeassistant] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 841, in async_create_flow
    integration = await loader.async_get_integration(self.hass, handler_key)
  File "/usr/src/homeassistant/homeassistant/loader.py", line 790, in async_get_integration
    raise int_or_exc
homeassistant.loader.IntegrationNotFound: Integration 'otbr' not found.

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

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 229, in async_init
    flow, result = await task
  File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 247, in _async_init
    flow = await self.async_create_flow(handler, context=context, data=data)
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 844, in async_create_flow
    raise data_entry_flow.UnknownHandler from err
homeassistant.data_entry_flow.UnknownHandler
2023-01-25 06:57:12.590 WARNING (MainThread) [homeassistant.helpers.service] Unable to find referenced entities lock.kitchen_lock or it is/they are currently not available
2023-01-25 11:01:13.232 WARNING (MainThread) [homeassistant.helpers.service] Unable to find referenced entities lock.kitchen_lock or it is/they are currently not available

Additional information

No response

home-assistant[bot] commented 1 year ago

Hey there @dmulcahey, @adminiuga, @puddly, mind taking a look at this issue as it has been labeled with an integration (zha) you are listed as a code owner for? Thanks!

Code owner commands Code owners of `zha` can trigger bot actions by commenting: - `@home-assistant close` Closes the issue. - `@home-assistant rename Awesome new title` Change the title of the issue. - `@home-assistant reopen` Reopen the issue. - `@home-assistant unassign zha` Removes the current integration label and assignees on the issue, add the integration domain after the command.

(message by CodeOwnersMention)


zha documentation zha source (message by IssueLinks)

puddly commented 1 year ago

What hardware are you running Home Assistant OS on?

Were you ever able to add the ZHA integration, or is this happening during the initial setup?

DarthGaymer commented 1 year ago

Raspberry Pi 4 (4G RAM currently maxing out around 1.2G used) running on an SSD.

This happened during initial setup of the Sky Connect and have never been able to get ZHA to work, even after uninstalling & reinstalling the add on

puddly commented 1 year ago

Can you take a screenshot of the specific addon you're installing?

DarthGaymer commented 1 year ago

image

puddly commented 1 year ago

Ah, I see. The SkyConnect ships with Zigbee firmware but since you've installed the multi-protocol addon, you've flashed it with the multi-protocol firmware.

The Multiprotocol addon is a little experimental at the moment and the user-friendly setup flow is going to be re-enabled in the upcoming beta release. For now, you will have to manually set up ZHA to connect to the addon:

DarthGaymer commented 1 year ago

Following the above still results in an error image

puddly commented 1 year ago

Do you have any other addons running that could be accessing the radio (i.e. Zigbee2MQTT)?

Physically unplug the SkyConnect, plug it back in, and try clicking the "Submit" button again in 30s. If that doesn't work, can you post the addon debug log?

DarthGaymer commented 1 year ago

I do not believe I have any other addons or integrations that are attempting to access the radio, all are listed below. AdGuard Home AsusWRT Cloudflared Home Assistant Google Drive Backup HACS Homekit Controller (Ecobee) Keymaster (HACS smart lock manager) MyQ TP-Link Kasa (wifi plugs) Z-Wave JS Z-Wave JS UI Silicon Labs Multiprotocol (error persists with add on uninstalled, not running, and running)

I am unable to find an addon debug log as Zigbee Home Automation does not show up in Add Ons and can only be found by the Add Integration button, but fails on setup

puddly commented 1 year ago

Installing the multiprotocol addon flashes special firmware to your SkyConnect. Without the addon running, ZHA cannot talk to the SkyConnect.

The addon debug log is in the same area as where you took the screenshot of the addon configuration, just in a different tab:

image

Can you take a screenshot of your Silicon Labs Multiprotocol addon configuration as well?

DarthGaymer commented 1 year ago

Below is the Log info

s6-rc: info: service mdns: starting s6-rc: info: service s6rc-oneshot-runner: starting s6-rc: info: service mdns successfully started s6-rc: info: service s6rc-oneshot-runner successfully started s6-rc: info: service fix-attrs: starting s6-rc: info: service fix-attrs successfully started s6-rc: info: service legacy-cont-init: starting cont-init: info: running /etc/cont-init.d/check-cpcd-shm.sh [12:50:39] INFO: Starting mDNS Responder... Default: mDNSResponder (Engineering Build) (Jan 23 2023 22:49:33) starting Default: mDNS_AddDNSServer: Lock not held! mDNS_busy (0) mDNS_reentrancy (0) cont-init: info: /etc/cont-init.d/check-cpcd-shm.sh exited 0 cont-init: info: running /etc/cont-init.d/config.sh [12:50:40] INFO: Generating cpcd configuration. cont-init: info: /etc/cont-init.d/config.sh exited 0 s6-rc: info: service legacy-cont-init successfully started s6-rc: info: service banner: starting

Add-on: Silicon Labs Multiprotocol Zigbee and OpenThread multiprotocol add-on

Add-on version: 0.12.0 You are running the latest version of this add-on. System: Home Assistant OS 9.4 (aarch64 / raspberrypi4-64) Home Assistant Core: 2023.1.7 Home Assistant Supervisor: 2023.01.1

Please, share the above information when looking for help or support in, e.g., GitHub, forums or the Discord chat.

s6-rc: info: service banner successfully started s6-rc: info: service universal-silabs-flasher: starting [12:50:42] INFO: Checking /dev/ttyUSB1 identifying SkyConnect v1.0 from Nabu Casa [12:50:42] INFO: Starting universal-silabs-flasher with /dev/ttyUSB1 (baudrate 57600) 2023-01-26 12:50:43 core-silabs-multiprotocol universal_silabs_flasher.flash[218] INFO Extracted GBL metadata: NabuCasaMetadata(metadata_version=1, sdk_version=<AwesomeVersion SemVer '4.1.4'>, ezsp_version=None, fw_type=<FirmwareImageType.RCP_UART_802154: 'rcp-uart-802154'>) 2023-01-26 12:50:43 core-silabs-multiprotocol universal_silabs_flasher.flasher[218] INFO Probing ApplicationType.GECKO_BOOTLOADER 2023-01-26 12:50:45 core-silabs-multiprotocol universal_silabs_flasher.flasher[218] INFO Probing ApplicationType.CPC 2023-01-26 12:50:49 core-silabs-multiprotocol universal_silabs_flasher.flasher[218] INFO Probing ApplicationType.EZSP Error: Failed to probe running application type 2023-01-26 12:50:54 core-silabs-multiprotocol concurrent.futures[218] ERROR exception calling callback for <Future at 0x7f8cd7aa30 state=finished returned NoneType> Traceback (most recent call last): File "/usr/lib/python3.9/concurrent/futures/_base.py", line 329, in _invoke_callbacks callback(self) File "/usr/lib/python3.9/asyncio/futures.py", line 398, in _call_set_state dest_loop.call_soon_threadsafe(_set_state, destination, source) File "/usr/lib/python3.9/asyncio/base_events.py", line 791, in call_soon_threadsafe self._check_closed() File "/usr/lib/python3.9/asyncio/base_events.py", line 510, in _check_closed raise RuntimeError('Event loop is closed') RuntimeError: Event loop is closed s6-rc: warning: unable to start service universal-silabs-flasher: command exited 1 /run/s6/basedir/scripts/rc.init: warning: s6-rc failed to properly bring all the services up! Check your logs (in /run/uncaught-logs/current if you have in-container logging) for more information. prog: fatal: stopping the container. s6-rc: info: service mdns: stopping s6-rc: info: service banner: stopping Default: mDNSResponder (Engineering Build) (Jan 23 2023 22:49:33) stopping s6-rc: info: service banner successfully stopped s6-rc: info: service legacy-cont-init: stopping s6-rc: info: service legacy-cont-init successfully stopped s6-rc: info: service fix-attrs: stopping s6-rc: info: service fix-attrs successfully stopped s6-rc: info: service s6rc-oneshot-runner: stopping s6-rc: info: service s6rc-oneshot-runner successfully stopped [12:50:55] INFO: mDNS ended with exit code 4 (signal 0)... s6-rc: info: service mdns successfully stopped

DarthGaymer commented 1 year ago

And here is the Configuration. All items not shown are default values

image

MattWestb commented 1 year ago

Set the barbiturate to 115200 and (re)start the addon and look in the log.

DarthGaymer commented 1 year ago

Thank you, everything now appears to be working correctly.

When I first attempted to set up the Sky Connect, I tried searching for what the baudrate should be set at but was unable to find anything.

schoenwaldnils commented 1 year ago

Had the same problem with having Multiprotocol installed and unknowingly flashing the skyconnect. Got errors like Error: spawn udevadm ENOENT and the timeout Error: Failed to connect to the adapter (Error: SRSP - SYS - ping after 6000ms)

But reverting the firmware to the original did the trick for me. https://skyconnect.home-assistant.io/firmware-update/