Update wifi_mngt.cpp

Network availability check removed before WiFi connection to support hidden SSID connections
pull/126/head
Forfelet 2025-08-09 14:48:08 +02:00 committed by GitHub
parent db0112e9c2
commit 88be5d5597
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 14 additions and 15 deletions

View File

@ -7,6 +7,8 @@
Contact: miroslav.pivovarsky@gmail.com
@bug: no know bug
@update: Network availability check removed before WiFi connection to support hidden SSID connections
*/
#include "wifi_mngt.h"
@ -100,7 +102,6 @@ void WiFiMngt::Init() {
//WiFi.setTxPower(WIFI_POWER_18_5dBm);
if (config->CheckActifeWifiCfgFlag() == true) {
if (true == CheckAvailableWifiNetwork(WifiSsid)) {
WiFiStaConnect();
log->AddEvent(LogLevel_Warning, "Connecting to WiFi: " + WifiSsid);
@ -114,9 +115,6 @@ void WiFiMngt::Init() {
/* Print ESP32 Local IP Address */
log->AddEvent(LogLevel_Info, "WiFi network IP Address: http://" + WiFi.localIP().toString());
#endif
} else {
log->AddEvent(LogLevel_Warning, "Wifi unavailable. Skip connecting to WiFi: " + WifiSsid);
}
} else {
ScanWiFiNetwork();
}
@ -1071,4 +1069,5 @@ void WiFiMngt_WiFiEventApStaProbeReqRecved(WiFiEvent_t event, WiFiEventInfo_t in
SystemLog.AddEvent(LogLevel_Info, F("WiFi AP STA receive probe request packet in soft-AP interface"));
}
/* EOF */