mirror of
https://github.com/arendst/Tasmota.git
synced 2025-07-24 19:26:37 +00:00
Fix intermittent wifi AP starts
This commit is contained in:
parent
0674f9b0b6
commit
69f903618d
@ -217,12 +217,17 @@ void WifiBegin(uint8_t flag, uint8_t channel)
|
|||||||
delay(200);
|
delay(200);
|
||||||
WifiSetMode(WIFI_STA); // Disable AP mode
|
WifiSetMode(WIFI_STA); // Disable AP mode
|
||||||
*/
|
*/
|
||||||
|
#ifdef USE_WIFI_RANGE_EXTENDER
|
||||||
if (WiFi.getMode() != WIFI_AP_STA) { // Preserve range extender connections (#17103)
|
if (WiFi.getMode() != WIFI_AP_STA) { // Preserve range extender connections (#17103)
|
||||||
WiFi.disconnect(true); // Delete SDK wifi config
|
WiFi.disconnect(true); // Delete SDK wifi config
|
||||||
delay(200);
|
delay(200);
|
||||||
|
|
||||||
WifiSetMode(WIFI_STA); // Disable AP mode
|
WifiSetMode(WIFI_STA); // Disable AP mode
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
WiFi.disconnect(true); // Delete SDK wifi config
|
||||||
|
delay(200);
|
||||||
|
WifiSetMode(WIFI_STA); // Disable AP mode
|
||||||
|
#endif
|
||||||
|
|
||||||
WiFiSetSleepMode();
|
WiFiSetSleepMode();
|
||||||
// if (WiFi.getPhyMode() != WIFI_PHY_MODE_11N) { WiFi.setPhyMode(WIFI_PHY_MODE_11N); } // B/G/N
|
// if (WiFi.getPhyMode() != WIFI_PHY_MODE_11N) { WiFi.setPhyMode(WIFI_PHY_MODE_11N); } // B/G/N
|
||||||
|
Loading…
x
Reference in New Issue
Block a user