project-chip / connectedhomeip

Matter (formerly Project CHIP) creates more connections between more objects, simplifying development for manufacturers and increasing compatibility for consumers, guided by the Connectivity Standards Alliance.
https://buildwithmatter.com
Apache License 2.0
7.31k stars 1.96k forks source link

[BUG] Light Switch App Setup is taking longer than expected #26047

Open mishadesh opened 1 year ago

mishadesh commented 1 year ago

Reproduction steps

  1. Build the Light Switch App for Nordic or Telink platform.
  2. Flash the board.
  3. Try to add device in Google Home. (used latest version - 3.1.1.1-dogfood)
  4. On the latest step after choosing the device name the Setup is taking longer than expected will occur. The device will be commissioned to Thread network, but will not be paired and will not be accessible until factory reset. Screenshot_20230410-164001

Bug prevalence

Every time

GitHub hash of the SDK that was being used

03cb5e3d388ec242f06760734ce021a0ab20b4b8

Platform

nrf, other

Platform Version(s)

No response

Anything else?

No response

bzbarsky-apple commented 1 year ago

@mishadesh Shouldn't this be reported to Google Home? This does not sound like a core SDK issue....

skoegugelfuss commented 1 year ago

Same problem here.

@bzbarsky-apple I'm not sure this is on Google side... this >could< be an issue with the matter core SDK. I've found a reddit post about this. Here they say Google Home is waiting for a response for a short amount of time. If the response came to late, the Google Home app will give you that "Something went wrong" error... Maybe there something went wrong in the matter core while setting up the device? :-D

Here is what I've tried until now:

bzbarsky-apple commented 1 year ago

this >could< be an issue with the matter core SDK

It could, but chances are the issue is that the timeout Google is using is just too low. They need to debug what's actually going on here.

skoegugelfuss commented 1 year ago

There is an issue open on Google side.

Follow up here: https://issuetracker.google.com/issues/262773689?pli=1

Darshanr5051 commented 1 year ago

@bzbarsky-apple @skoegugelfuss

Anyone got any clue in this issue ?

Cause, I am facing the same issue.

I am using esp32-Wroom-32 board.

Generated Google console VID and PID as well and the Test it too ! But still issue is remain same.

zod6 commented 11 months ago

My experiences with GH and matter commissioning. Tried with idf 5.1.1 and example/lighting-app from project-chip/connectedhomeip and espressif/esp-matter master branches, with two different phones, different google accounts and in different wifi networks.

steps to reproduce on ESP32-DevKitC and android 13 (latest updates installed): A:

  1. flash "light" from launchpad
  2. create new project and add matter device with vid=0xfff1 and pid=0x8000 on developer console (otherwise it will show error "Not a Matter-certified device")
  3. in same wifi network and under same google account, set up Google Nest Mini (without it there will be one extra warning page during commissioning step)
  4. add wifi network using chip-tool: pairing code-wifi 0x5164 myssid mypasswd 34970112332; pairing unpair 0x5164 (or in esp32 console matter esp wifi connect myssid mypasswd)
  5. open Google Home app add matter device with pairing code QR
  6. device gets commissioned but after entering device name HA shows error 'Something went wrong'

B (wifi not configured): steps 1-3 are same.

  1. open Google Home app add matter device with pairing code QR
  2. device doesn't get wifi credentials and GH app gets stuck for 5+ minutes. logs from esp32:
    I (13042) chip[NP]: ESP NetworkCommissioningDelegate: SSID: <ssid> // unaltered copy-paste
    ...
    I (78932) chip[FS]: Fail-safe timer expired
    ...
    E (78952) chip[SVR]: Commissioning failed (attempt 1): 32

I can commission and control ESP32 matter device with Home Assistant and google home sample app when wifi is configured