[GH-ISSUE #725] Time to Connect #605

Closed
opened 2026-02-28 01:26:11 +03:00 by kerem · 2 comments
Owner

Originally created by @josemariaaraujo on GitHub (Sep 11, 2018).
Original GitHub issue: https://github.com/tzapu/WiFiManager/issues/725

(ESP Core Version: 2.4.1)
Hi,
I've trying to get my power consumption down in a battery powered sensor, and after some profiling I've found that most of my awake time was spent in WiFiManager autoConnect (with a static IP) , spending always more than 3 seconds to establish a connection, much longer than if done directly with WiFi.config(..); WiFi.begin(); while ( WiFi.status() != WL_CONNECTED ) delay(1); which only took 0.2-0.3s.

After going deeper in your code, I've found the culprit: in int WiFiManager::connectWifi if I comment ETS_UART_INTR_DISABLE(); wifi_station_disconnect(); ETS_UART_INTR_ENABLE(); I get the same connection times as using the code above.

I don't know enough of the ESP8266 to understand if what I have commented is still relevant and should be left alone. But maybe someone is also trying to get the lowest consumption while still using WiFiManager for it's benefits, and this issue/solution will help them.

Thank you for your great work!

Originally created by @josemariaaraujo on GitHub (Sep 11, 2018). Original GitHub issue: https://github.com/tzapu/WiFiManager/issues/725 (ESP Core Version: 2.4.1) Hi, I've trying to get my power consumption down in a battery powered sensor, and after some profiling I've found that most of my awake time was spent in WiFiManager autoConnect (with a static IP) , spending always more than 3 seconds to establish a connection, much longer than if done directly with `WiFi.config(..); WiFi.begin(); while ( WiFi.status() != WL_CONNECTED ) delay(1);` which only took 0.2-0.3s. After going deeper in your code, I've found the culprit: in `int WiFiManager::connectWifi` if I comment ` ETS_UART_INTR_DISABLE(); wifi_station_disconnect(); ETS_UART_INTR_ENABLE();` I get the same connection times as using the code above. I don't know enough of the ESP8266 to understand if what I have commented is still relevant and should be left alone. But maybe someone is also trying to get the lowest consumption while still using WiFiManager for it's benefits, and this issue/solution will help them. Thank you for your great work!
kerem closed this issue 2026-02-28 01:26:11 +03:00
Author
Owner

@tablatronix commented on GitHub (Sep 12, 2018):

Yeah its already detailed in development branch

<!-- gh-comment-id:420476182 --> @tablatronix commented on GitHub (Sep 12, 2018): Yeah its already detailed in development branch
Author
Owner

@tablatronix commented on GitHub (Sep 12, 2018):

#598

<!-- gh-comment-id:420476629 --> @tablatronix commented on GitHub (Sep 12, 2018): #598
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/WiFiManager#605
No description provided.