diff --git a/config/nxp/chip-module/Kconfig b/config/nxp/chip-module/Kconfig index 88918a67450ad3..7ee0917ebec555 100644 --- a/config/nxp/chip-module/Kconfig +++ b/config/nxp/chip-module/Kconfig @@ -208,7 +208,7 @@ endif #CHIP_FACTORY_DATA_BUILD # See config/zephyr/Kconfig for full definition config CHIP_FACTORY_RESET_ERASE_NVS bool - default y if CHIP_FACTORY_DATA || CHIP_FACTORY_DATA_CUSTOM_BACKEND + default y endif diff --git a/config/nxp/chip-module/Kconfig.defaults b/config/nxp/chip-module/Kconfig.defaults index 56c82e3752900c..531a3f38245aad 100644 --- a/config/nxp/chip-module/Kconfig.defaults +++ b/config/nxp/chip-module/Kconfig.defaults @@ -87,7 +87,7 @@ config PTHREAD_IPC config POSIX_MAX_FDS int - default 16 + default 8 # Application stack size config MAIN_STACK_SIZE @@ -99,12 +99,21 @@ config INIT_STACKS config NET_MGMT_EVENT_STACK_SIZE default 2048 +config NET_MGMT_EVENT_QUEUE_SIZE + default 20 + config NET_IPV6_MLD default y config NET_IF_MCAST_IPV6_ADDR_COUNT default 14 +config NET_IF_MAX_IPV4_COUNT + default 2 + +config NET_IF_MAX_IPV6_COUNT + default 2 + config NET_TC_TX_COUNT default 1 @@ -129,10 +138,10 @@ config NET_TC_RX_THREAD_BASE_PRIO # Network buffers config NET_PKT_RX_COUNT - default 16 + default 60 config NET_PKT_TX_COUNT - default 16 + default 40 config NET_BUF_RX_COUNT default 60 @@ -141,7 +150,7 @@ config NET_BUF_TX_COUNT default 80 config NET_BUF_DATA_SIZE - default 1700 + default 1744 # Bluetooth Low Energy configs @@ -233,11 +242,14 @@ choice WPA_SUPP_LOG_LEVEL_CHOICE endchoice config WPA_SUPP_THREAD_STACK_SIZE - default 6144 + default 12288 config SYSTEM_WORKQUEUE_STACK_SIZE default 2048 +config NET_TCP_WORKQ_STACK_SIZE + default 2048 + # align these numbers to match the OpenThread config config NET_IF_UNICAST_IPV6_ADDR_COUNT default 6 @@ -246,7 +258,25 @@ config NET_IF_MCAST_IPV6_ADDR_COUNT default 8 config NET_SOCKETS_POLL_MAX - default 4 + default 8 + +config NET_IPV4_FRAGMENT_MAX_COUNT + default 3 + +config NET_IPV4_FRAGMENT_MAX_PKT + default 7 + +config NET_IPV4_FRAGMENT_TIMEOUT + default 3 + +config NET_IPV6_FRAGMENT_MAX_COUNT + default 3 + +config NET_IPV6_FRAGMENT_MAX_PKT + default 7 + +config NET_IPV6_FRAGMENT_TIMEOUT + default 3 # options managed by IP4/IP6 simultaneous support # aligned here to match OpenThread config @@ -260,7 +290,7 @@ config SHELL_STACK_SIZE default 2616 config HEAP_MEM_POOL_SIZE - default 65536 + default 122880 config CHIP_MALLOC_SYS_HEAP_SIZE default 28672 # 28 kB diff --git a/src/platform/nxp/zephyr/CHIPDevicePlatformConfig.h b/src/platform/nxp/zephyr/CHIPDevicePlatformConfig.h index f8c72dd043902f..7a80a39a3f77b2 100644 --- a/src/platform/nxp/zephyr/CHIPDevicePlatformConfig.h +++ b/src/platform/nxp/zephyr/CHIPDevicePlatformConfig.h @@ -27,65 +27,22 @@ // ==================== Platform Adaptations ==================== -#ifndef CHIP_DEVICE_CONFIG_TEST_SERIAL_NUMBER -#define CHIP_DEVICE_CONFIG_TEST_SERIAL_NUMBER CONFIG_CHIP_DEVICE_SERIAL_NUMBER -#endif - -#ifndef CHIP_DEVICE_CONFIG_TEST_MANUFACTURING_DATE -#define CHIP_DEVICE_CONFIG_TEST_MANUFACTURING_DATE CONFIG_CHIP_DEVICE_MANUFACTURING_DATE -#endif - -#ifndef CHIP_DEVICE_CONFIG_DEFAULT_DEVICE_HARDWARE_VERSION -#define CHIP_DEVICE_CONFIG_DEFAULT_DEVICE_HARDWARE_VERSION CONFIG_CHIP_DEVICE_HARDWARE_VERSION -#endif - -#ifndef CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE -#define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE CONFIG_CHIP_DEVICE_SPAKE2_PASSCODE -#endif - -#ifndef CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR -#define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR CONFIG_CHIP_DEVICE_DISCRIMINATOR -#endif - -#ifndef CHIP_DEVICE_CONFIG_DEFAULT_DEVICE_HARDWARE_VERSION_STRING -#define CHIP_DEVICE_CONFIG_DEFAULT_DEVICE_HARDWARE_VERSION_STRING CONFIG_CHIP_DEVICE_HARDWARE_VERSION_STRING -#endif - -#ifndef CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_ITERATION_COUNT -#define CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_ITERATION_COUNT CONFIG_CHIP_DEVICE_SPAKE2_IT -#endif - -#ifndef CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_SALT -#define CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_SALT CONFIG_CHIP_DEVICE_SPAKE2_SALT -#endif - -#ifndef CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_VERIFIER -#define CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_VERIFIER CONFIG_CHIP_DEVICE_SPAKE2_TEST_VERIFIER -#endif - -#ifndef CHIP_DEVICE_CONFIG_DEVICE_VENDOR_ID #define CHIP_DEVICE_CONFIG_DEVICE_VENDOR_ID CONFIG_CHIP_DEVICE_VENDOR_ID -#endif - -#ifndef CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_ID -#define CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_ID CONFIG_CHIP_DEVICE_PRODUCT_ID -#endif - -#ifndef CHIP_DEVICE_CONFIG_DEVICE_VENDOR_NAME #define CHIP_DEVICE_CONFIG_DEVICE_VENDOR_NAME CONFIG_CHIP_DEVICE_VENDOR_NAME -#endif - -#ifndef CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_NAME +#define CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_ID CONFIG_CHIP_DEVICE_PRODUCT_ID #define CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_NAME CONFIG_CHIP_DEVICE_PRODUCT_NAME -#endif - -#ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION +#define CHIP_DEVICE_CONFIG_DEFAULT_DEVICE_HARDWARE_VERSION CONFIG_CHIP_DEVICE_HARDWARE_VERSION +#define CHIP_DEVICE_CONFIG_DEFAULT_DEVICE_HARDWARE_VERSION_STRING CONFIG_CHIP_DEVICE_HARDWARE_VERSION_STRING #define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION CONFIG_CHIP_DEVICE_SOFTWARE_VERSION -#endif - -#ifndef CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING #define CHIP_DEVICE_CONFIG_DEVICE_SOFTWARE_VERSION_STRING CONFIG_CHIP_DEVICE_SOFTWARE_VERSION_STRING -#endif +#define CHIP_DEVICE_CONFIG_TEST_MANUFACTURING_DATE CONFIG_CHIP_DEVICE_MANUFACTURING_DATE +#define CHIP_DEVICE_CONFIG_TEST_SERIAL_NUMBER CONFIG_CHIP_DEVICE_SERIAL_NUMBER +#define CHIP_DEVICE_CONFIG_DEVICE_TYPE CONFIG_CHIP_DEVICE_TYPE +#define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR CONFIG_CHIP_DEVICE_DISCRIMINATOR +#define CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE CONFIG_CHIP_DEVICE_SPAKE2_PASSCODE +#define CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_ITERATION_COUNT CONFIG_CHIP_DEVICE_SPAKE2_IT +#define CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_SALT CONFIG_CHIP_DEVICE_SPAKE2_SALT +#define CHIP_DEVICE_CONFIG_USE_TEST_SPAKE2P_VERIFIER CONFIG_CHIP_DEVICE_SPAKE2_TEST_VERIFIER #ifdef CONFIG_NET_L2_OPENTHREAD #define CHIP_DEVICE_CONFIG_ENABLE_THREAD CONFIG_NET_L2_OPENTHREAD @@ -93,8 +50,8 @@ #define CHIP_DEVICE_CONFIG_ENABLE_THREAD 0 #endif -#ifdef CONFIG_WIFI_NXP -#define CHIP_DEVICE_CONFIG_ENABLE_WIFI CONFIG_WIFI_NXP +#ifdef CONFIG_CHIP_WIFI +#define CHIP_DEVICE_CONFIG_ENABLE_WIFI CONFIG_CHIP_WIFI #define CHIP_DEVICE_CONFIG_ENABLE_WIFI_STATION 1 #define CHIP_DEVICE_CONFIG_ENABLE_WIFI_AP 0 #else @@ -155,6 +112,8 @@ #define CHIP_DEVICE_CONFIG_CHIP_TASK_STACK_SIZE 8192 #endif // CHIP_DEVICE_CONFIG_CHIP_TASK_STACK_SIZE +#define CHIP_DEVICE_CONFIG_MAX_EVENT_QUEUE_SIZE 64 + #define CHIP_DEVICE_CONFIG_ENABLE_WIFI_TELEMETRY 0 #define CHIP_DEVICE_CONFIG_ENABLE_THREAD_TELEMETRY 0 #define CHIP_DEVICE_CONFIG_ENABLE_THREAD_TELEMETRY_FULL 0 @@ -197,10 +156,6 @@ #define CHIP_DEVICE_CONFIG_ENABLE_COMMISSIONABLE_DEVICE_TYPE 1 #endif // CONFIG_CHIP_COMMISSIONABLE_DEVICE_TYPE -#ifdef CONFIG_CHIP_DEVICE_TYPE -#define CHIP_DEVICE_CONFIG_DEVICE_TYPE CONFIG_CHIP_DEVICE_TYPE -#endif // CONFIG_CHIP_DEVICE_TYPE - #ifdef CONFIG_CHIP_EXTENDED_DISCOVERY #define CHIP_DEVICE_CONFIG_ENABLE_EXTENDED_DISCOVERY 1 #endif // CONFIG_CHIP_EXTENDED_DISCOVERY diff --git a/src/platform/nxp/zephyr/SystemPlatformConfig.h b/src/platform/nxp/zephyr/SystemPlatformConfig.h index 24f8c4d229e235..1757071f42a751 100644 --- a/src/platform/nxp/zephyr/SystemPlatformConfig.h +++ b/src/platform/nxp/zephyr/SystemPlatformConfig.h @@ -25,3 +25,5 @@ #pragma once #include + +#define CHIP_SYSTEM_CONFIG_USE_ZEPHYR_SOCKET_EXTENSIONS 0 diff --git a/src/platform/nxp/zephyr/wifi/NxpWifiDriver.cpp b/src/platform/nxp/zephyr/wifi/NxpWifiDriver.cpp index 06a0b48f1e8c77..f3969a583221e6 100644 --- a/src/platform/nxp/zephyr/wifi/NxpWifiDriver.cpp +++ b/src/platform/nxp/zephyr/wifi/NxpWifiDriver.cpp @@ -147,10 +147,6 @@ CHIP_ERROR NxpWifiDriver::CommitConfiguration() CHIP_ERROR NxpWifiDriver::RevertConfiguration() { - // Abort Connection Recovery if it is in progress during reverting configuration. - // This is needed to stop recovery process after failsafe timer expiring. - WiFiManager::Instance().AbortConnectionRecovery(); - LoadFromStorage(); if (WiFiManager::StationStatus::CONNECTING <= WiFiManager::Instance().GetStationStatus()) diff --git a/src/platform/nxp/zephyr/wifi/WiFiManager.cpp b/src/platform/nxp/zephyr/wifi/WiFiManager.cpp index 946546288761b4..8b6fdf64bbe8d9 100644 --- a/src/platform/nxp/zephyr/wifi/WiFiManager.cpp +++ b/src/platform/nxp/zephyr/wifi/WiFiManager.cpp @@ -142,8 +142,8 @@ const Map WiFiManager::sEventHandlerMap({ { NET_EVENT_WIFI_SCAN_RESULT, WiFiManager::ScanResultHandler }, { NET_EVENT_WIFI_SCAN_DONE, WiFiManager::ScanDoneHandler }, { NET_EVENT_WIFI_CONNECT_RESULT, WiFiManager::ConnectHandler }, - { NET_EVENT_WIFI_DISCONNECT_RESULT, WiFiManager::NetworkDrivenDisconnectHandler }, - { NET_EVENT_WIFI_DISCONNECT_COMPLETE, WiFiManager::ApplicationDrivenDisconnectHandler } }); + { NET_EVENT_WIFI_DISCONNECT_RESULT, WiFiManager::DisconnectHandler }, + { NET_EVENT_WIFI_DISCONNECT_COMPLETE, WiFiManager::DisconnectHandler } }); void WiFiManager::WifiMgmtEventHandler(net_mgmt_event_callback * cb, uint32_t mgmtEvent, net_if * iface) { @@ -206,9 +206,6 @@ CHIP_ERROR WiFiManager::Scan(const ByteSpan & ssid, ScanResultCallback resultCal mCachedWiFiState = mWiFiState; mWiFiState = WIFI_STATE_SCANNING; mSsidFound = false; - mRecoveryArmed = true; - // TODO Workaround for recovery mechanism to wait before the next scan request until the WiFi supplicant is not busy. - static bool workaroundDone; /* If the ssid is not null, it means the scan must target a specific SSID, and only include this one in the scan * result. To do so, we save the requested ssid and we will filter the scan results accordingly in the scan done @@ -220,28 +217,9 @@ CHIP_ERROR WiFiManager::Scan(const ByteSpan & ssid, ScanResultCallback resultCal mNetworkToScan.ssidLen = ssid.size(); } - int ret = net_mgmt(NET_REQUEST_WIFI_SCAN, iface, NULL, 0); - - if (ret) + if (0 != net_mgmt(NET_REQUEST_WIFI_SCAN, iface, NULL, 0)) { - ChipLogError(DeviceLayer, "Scan request failed %d", ret); - if (ret == -EBUSY && !workaroundDone) - { - // TODO Wi-Fi driver returned an error during recovery. - // As a workaround schedule the recovery timer one more time in WifiSupplicantWorkaroundTime time. - // This allows the device to run the Scan method without - // rebooting when the "Device or resource busy" error occurs. - DeviceLayer::SystemLayer().StartTimer(System::Clock::Milliseconds32(kWifiSupplicantWorkaroundTime), Recover, nullptr); - workaroundDone = true; - return CHIP_NO_ERROR; - } - else - { - // TODO The workaround has not worked, so reboot the device - ChipLogError(DeviceLayer, "WiFi driver does not respond, resetting the device..."); - workaroundDone = false; - PlatformMgr().Shutdown(); - } + ChipLogError(DeviceLayer, "Scan request failed"); return CHIP_ERROR_INTERNAL; } @@ -437,21 +415,14 @@ void WiFiManager::ScanDoneHandler(Platform::UniquePtr data) // Internal scan is supposed to be followed by a connection request if the SSID has been found if (Instance().mInternalScan) { - if (Instance().mRecoveryArmed) + if (!Instance().mSsidFound) { - if (!Instance().mSsidFound) - { - ChipLogProgress(DeviceLayer, "No requested SSID found"); - auto currentTimeout = Instance().CalculateNextRecoveryTime(); - ChipLogProgress(DeviceLayer, "Starting connection recover: re-scanning... (next attempt in %d ms)", - currentTimeout.count()); - DeviceLayer::SystemLayer().StartTimer(currentTimeout, Recover, nullptr); - return; - } - else - { - Instance().AbortConnectionRecovery(); - } + ChipLogProgress(DeviceLayer, "No requested SSID found"); + auto currentTimeout = Instance().CalculateNextRecoveryTime(); + ChipLogProgress(DeviceLayer, "Starting connection recover: re-scanning... (next attempt in %d ms)", + currentTimeout.count()); + DeviceLayer::SystemLayer().StartTimer(currentTimeout, Recover, nullptr); + return; } Instance().mWiFiState = WIFI_STATE_ASSOCIATING; @@ -542,8 +513,6 @@ void WiFiManager::ConnectHandler(Platform::UniquePtr data) ChipLogError(DeviceLayer, "Cannot post event [error: %s]", ErrorStr(error)); } } - // Ensure fresh recovery for future connection requests. - Instance().ResetRecoveryTime(); // cleanup the provisioning data as it is configured per each connect request Instance().ClearStationProvisioningData(); }); @@ -555,16 +524,8 @@ void WiFiManager::ConnectHandler(Platform::UniquePtr data) } } -void WiFiManager::NetworkDrivenDisconnectHandler(Platform::UniquePtr) +void WiFiManager::DisconnectHandler(Platform::UniquePtr) { - // Workaround: schedule the application level connection recovery in kSupplicantReconnectionTimeoutMs to give WPA supplicant - // some time to restore it. - if (!Instance().mRecoveryArmed) - { - Instance().mRecoveryArmed = true; - DeviceLayer::SystemLayer().StartTimer(System::Clock::Milliseconds32(kSupplicantReconnectionTimeoutMs), Recover, nullptr); - } - SystemLayer().ScheduleLambda([] { ChipLogProgress(DeviceLayer, "WiFi station disconnected"); Instance().mWiFiState = WIFI_STATE_DISCONNECTED; @@ -572,24 +533,6 @@ void WiFiManager::NetworkDrivenDisconnectHandler(Platform::UniquePtr) }); } -void WiFiManager::ApplicationDrivenDisconnectHandler(Platform::UniquePtr) -{ - if (!Instance().mRecoveryArmed) - { - return; - } - - if (!Instance().mApplicationDisconnectRequested) - { - Instance().AbortConnectionRecovery(); - } - else - { - Instance().mApplicationDisconnectRequested = false; - SystemLayer().ScheduleLambda([] { Recover(nullptr, nullptr); }); - } -} - WiFiManager::StationStatus WiFiManager::GetStationStatus() const { return WiFiManager::sStatusMap[mWiFiState]; @@ -603,23 +546,6 @@ void WiFiManager::PostConnectivityStatusChange(ConnectivityChange changeType) PlatformMgr().PostEventOrDie(&networkEvent); } -System::Clock::Milliseconds32 WiFiManager::CalculateNextRecoveryTime() -{ - if (mConnectionRecoveryTimeMs > kConnectionRecoveryMaxIntervalMs) - { - // Find the new random jitter value in range [-jitter, +jitter]. - int32_t jitter = chip::Crypto::GetRandU32() % (2 * jitter + 1) - jitter; - mConnectionRecoveryTimeMs = kConnectionRecoveryMaxIntervalMs + jitter; - return System::Clock::Milliseconds32(mConnectionRecoveryTimeMs); - } - else - { - uint32_t currentRecoveryTimeout = mConnectionRecoveryTimeMs; - mConnectionRecoveryTimeMs = mConnectionRecoveryTimeMs * 2; - return System::Clock::Milliseconds32(currentRecoveryTimeout); - } -} - void WiFiManager::Recover(System::Layer *, void *) { // Prevent scheduling recovery if we are already connected to the network. @@ -649,7 +575,23 @@ void WiFiManager::AbortConnectionRecovery() { DeviceLayer::SystemLayer().CancelTimer(Recover, nullptr); Instance().ResetRecoveryTime(); - Instance().mRecoveryArmed = false; +} + +System::Clock::Milliseconds32 WiFiManager::CalculateNextRecoveryTime() +{ + if (mConnectionRecoveryTimeMs > kConnectionRecoveryMaxIntervalMs) + { + // Find the new random jitter value in range [-jitter, +jitter]. + int32_t jitter = chip::Crypto::GetRandU32() % (2 * jitter + 1) - jitter; + mConnectionRecoveryTimeMs = kConnectionRecoveryMaxIntervalMs + jitter; + return System::Clock::Milliseconds32(mConnectionRecoveryTimeMs); + } + else + { + uint32_t currentRecoveryTimeout = mConnectionRecoveryTimeMs; + mConnectionRecoveryTimeMs = mConnectionRecoveryTimeMs * 2; + return System::Clock::Milliseconds32(currentRecoveryTimeout); + } } CHIP_ERROR WiFiManager::SetLowPowerMode(bool onoff) diff --git a/src/platform/nxp/zephyr/wifi/WiFiManager.h b/src/platform/nxp/zephyr/wifi/WiFiManager.h index 29f2ef299af1aa..d48536fb3d0da3 100644 --- a/src/platform/nxp/zephyr/wifi/WiFiManager.h +++ b/src/platform/nxp/zephyr/wifi/WiFiManager.h @@ -173,10 +173,6 @@ class WiFiManager static constexpr uint32_t kConnectionRecoveryMaxIntervalMs = CONFIG_CHIP_WIFI_CONNECTION_RECOVERY_MAXIMUM_INTERVAL; static constexpr uint32_t kConnectionRecoveryJitterMs = CONFIG_CHIP_WIFI_CONNECTION_RECOVERY_JITTER; static constexpr uint32_t kConnectionRecoveryMaxRetries = CONFIG_CHIP_WIFI_CONNECTION_RECOVERY_MAX_RETRIES_NUMBER; - static constexpr uint32_t kSupplicantReconnectionTimeoutMs = 60000; - - static_assert(kConnectionRecoveryMinIntervalMs < kConnectionRecoveryMaxIntervalMs); - static_assert(kConnectionRecoveryJitterMs <= kConnectionRecoveryMaxIntervalMs); CHIP_ERROR Init(); CHIP_ERROR Scan(const ByteSpan & ssid, ScanResultCallback resultCallback, ScanDoneCallback doneCallback, @@ -200,16 +196,14 @@ class WiFiManager }; constexpr static uint32_t kWifiManagementEvents = NET_EVENT_WIFI_SCAN_RESULT | NET_EVENT_WIFI_SCAN_DONE | - NET_EVENT_WIFI_CONNECT_RESULT | NET_EVENT_WIFI_DISCONNECT_RESULT | NET_EVENT_WIFI_DISCONNECT_COMPLETE | - NET_EVENT_WIFI_IFACE_STATUS; + NET_EVENT_WIFI_CONNECT_RESULT | NET_EVENT_WIFI_DISCONNECT_RESULT | NET_EVENT_WIFI_IFACE_STATUS; // Event handling static void WifiMgmtEventHandler(net_mgmt_event_callback * cb, uint32_t mgmtEvent, net_if * iface); static void ScanResultHandler(Platform::UniquePtr data); static void ScanDoneHandler(Platform::UniquePtr data); static void ConnectHandler(Platform::UniquePtr data); - static void NetworkDrivenDisconnectHandler(Platform::UniquePtr data); - static void ApplicationDrivenDisconnectHandler(Platform::UniquePtr data); + static void DisconnectHandler(Platform::UniquePtr data); static void PostConnectivityStatusChange(ConnectivityChange changeType); static void SendRouterSolicitation(System::Layer * layer, void * param); @@ -240,10 +234,7 @@ class WiFiManager bool mSsidFound{ false }; uint32_t mConnectionRecoveryCounter{ 0 }; uint32_t mConnectionRecoveryTimeMs{ kConnectionRecoveryMinIntervalMs }; - bool mRecoveryArmed{ false }; bool mApplicationDisconnectRequested{ false }; - // TODO Workaround for recovery mechanism to wait before the next scan request until the WiFi supplicant is not busy. - static constexpr uint32_t kWifiSupplicantWorkaroundTime = 8000; static const Map sStatusMap; static const Map sEventHandlerMap;