Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

App assumes Wi-Fi is not commissioned because wpa_supplicant DBUS proxy setup takes a while #8834

Closed
tewarid opened this issue Aug 6, 2021 · 1 comment

Comments

@tewarid
Copy link
Contributor

tewarid commented Aug 6, 2021

chip::DeviceLayer::ConnectivityMgrImpl().StartWiFiManagement();

StartWiFiManagement called in AppMain asynchronously initializes wpa_supplicant DBUS proxy which takes a while. In the meantime app proceeds to query Wi-Fi commissioning status and assumes it is not provisioned. This causes app to reset fabric configuration and continue in BLE pairing mode when restarted.

Section of log with the scenario playing out is reproduced below

[1628247641.706501][8928:8928] CHIP:DL: wpa_supplicant: _IsWiFiStationProvisioned: interface not connected (state=0)
[1628247641.706802][8928:8928] CHIP:SC: Assigned local session key ID 0
[1628247641.706902][8928:8928] CHIP:SC: Waiting for PBKDF param request
[1628247641.706996][8928:8928] CHIP:DIS: Start dns-sd server
[1628247641.716802][8928:8928] CHIP:DIS: CHIP minimal mDNS started advertising.
[1628247641.730670][8928:8928] CHIP:DIS: Replying to DNS-SD service listing request
[1628247641.730812][8928:8928] CHIP:DIS: Replying to DNS-SD service listing request
[1628247641.730894][8928:8928] CHIP:DIS: Replying to DNS-SD service listing request
[1628247641.731204][8928:8928] CHIP:DIS: Replying to DNS-SD service listing request
[1628247641.731321][8928:8928] CHIP:DIS: Replying to DNS-SD service listing request
[1628247641.731401][8928:8928] CHIP:DIS: Replying to DNS-SD service listing request
[1628247641.731502][8928:8928] CHIP:DL: wpa_supplicant: _IsWiFiStationProvisioned: interface not connected
[1628247641.731591][8928:8928] CHIP:DL: wpa_supplicant: _IsWiFiStationProvisioned: interface not connected
[1628247641.732533][8928:8928] CHIP:DIS: Using wifi MAC for hostname
[1628247641.732723][8928:8928] CHIP:DL: rotatingDeviceId: 00007C5F6E176CD40F68685D100A1CF8A98B
[1628247641.732817][8928:8928] CHIP:DIS: Advertise commission parameter vendorID=9050 productID=65279 discriminator=3840/00
[1628247641.733053][8928:8928] CHIP:DIS: CHIP minimal mDNS configured as 'Commissionable node device'.
[1628247641.733145][8928:8928] CHIP:IN: CASE Server enabling CASE session setups
[1628247641.733228][8928:8928] CHIP:SVR: Server Listening...
[1628247641.734846][8928:8931] CHIP:DL: wpa_supplicant: connected to wpa_supplicant proxy
@tewarid tewarid changed the title App assumes Wi-Fi is not commissioned due to delay in StartWiFiManagement App assumes Wi-Fi is not commissioned when wpa_supplicant DBUS proxy creation is delayed Aug 9, 2021
@tewarid tewarid changed the title App assumes Wi-Fi is not commissioned when wpa_supplicant DBUS proxy creation is delayed App assumes Wi-Fi is not commissioned because wpa_supplicant DBUS proxy creation takes a while Aug 19, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 23, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 23, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 23, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 23, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 23, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 23, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 23, 2021
@tewarid tewarid changed the title App assumes Wi-Fi is not commissioned because wpa_supplicant DBUS proxy creation takes a while App assumes Wi-Fi is not commissioned because wpa_supplicant DBUS proxy init takes a while Aug 23, 2021
@tewarid tewarid changed the title App assumes Wi-Fi is not commissioned because wpa_supplicant DBUS proxy init takes a while App assumes Wi-Fi is not commissioned because wpa_supplicant DBUS proxy setup takes a while Aug 23, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 23, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 23, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 23, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 24, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 27, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 30, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 30, 2021
tewarid added a commit to tewarid/connectedhomeip that referenced this issue Aug 31, 2021
woody-apple pushed a commit that referenced this issue Aug 31, 2021
* Wait for Wi-Fi management to start up (#8834)

* Restyled by clang-format

* Extract code in function EnsureWifiIsStarted

* Restyled by whitespace

* Fix unused variable warning/error

Co-authored-by: Restyled.io <commits@restyled.io>
@tewarid
Copy link
Contributor Author

tewarid commented Sep 16, 2021

Closing this issue as PR #9322 has been merged.

@tewarid tewarid closed this as completed Sep 16, 2021
mkardous-silabs pushed a commit to mkardous-silabs/connectedhomeip that referenced this issue Sep 24, 2021
…ip#9322)

* Wait for Wi-Fi management to start up (project-chip#8834)

* Restyled by clang-format

* Extract code in function EnsureWifiIsStarted

* Restyled by whitespace

* Fix unused variable warning/error

Co-authored-by: Restyled.io <commits@restyled.io>
jamesharrow added a commit to jamesharrow/connectedhomeip that referenced this issue Feb 13, 2024
…al Energy Measurement clusters from EVSE device type. Per spec PR project-chip#8834
andy31415 pushed a commit that referenced this issue Feb 13, 2024
…al Energy Measurement clusters from EVSE device type. Per spec PR #8834 (#32111)
raul-marquez-csa pushed a commit to raul-marquez-csa/connectedhomeip that referenced this issue Feb 16, 2024
…al Energy Measurement clusters from EVSE device type. Per spec PR project-chip#8834 (project-chip#32111)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant