mirror of
https://github.com/tzapu/WiFiManager.git
synced 2026-04-27 00:55:52 +03:00
[GH-ISSUE #1065] Won't join stored WiFi until hard reset #907
Labels
No labels
📶 WiFi
🕸️ HTTP
Branch
DEV Help Wanted
Discussion
Documentation
ESP32
Example
Good First Issue
Hotfix
In Progress
Incomplete
Needs Feeback
Priority
QA
Question
Task
Upstream/Dependancy
bug
duplicate
enhancement
invalid
pull-request
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/WiFiManager#907
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @alfo on GitHub (May 25, 2020).
Original GitHub issue: https://github.com/tzapu/WiFiManager/issues/1065
Basic Infos
Hardware
WiFimanager Branch/Release:
Esp8266/Esp32:
Hardware: ESP-12e, esp01, esp25
ESP Core Version: 2.4.0, staging
Description
After a successful storing of WiFi details, the first time the ESP8266 boots up (from no power, or new sketch upload), it will fail to join the new WiFi with the stored details (and therefore will switch to AP mode).
Pressing the hard reset button to reboot and/or using
ESP.restart(), the next time the ESP boots it will work fine.See debug messages at the bottom of the issue:
Settings in IDE
Module: Wemos D1 v2
Module: Wemos D1 32
(tried both)
Sketch
Debug Messages
Then I press the hard reset button/or call
ESP.restart();@alfo commented on GitHub (May 25, 2020):
I should also mention that if I change the WiFiManager version to 0.1.5, everything works as expected, so it's a problem specific to ~v2.x.x
@tablatronix commented on GitHub (May 25, 2020):
There has been alot of talk of this and wifi working everyother restart.
I think this is an esp bug, did you do a full erase?
*WM: [3] lastconxresult: WL_STATION_WRONG_PASSWORD@tablatronix commented on GitHub (May 25, 2020):
Try to full erase memory from esptool or arduino, corrupt flash can cause this, or sdk changes etc.
also enable all debugging in esp, to see what its wifi is doing
You can try this and see if it changes, some esps hang mid connect, we do not know why, might be related to routers
@tablatronix commented on GitHub (May 25, 2020):
#1067
@alfo commented on GitHub (May 25, 2020):
Ah, I think clearing the flash completely has fixed it, my bad. Must be because I've switched between 0.15 and 2.0.1 in the same project while developing.
@alfo commented on GitHub (May 25, 2020):
Actually, I'm an idiot, sorry. This only fixed it once, which it seems is the same as the "every other problem".
@tablatronix commented on GitHub (May 25, 2020):
Thanks , yeah I have no idea what causes this.
I was never able to reproduce it, there are a few issues on it, I will try to reference them all and see what could be the common cause..
@mhama commented on GitHub (Jan 17, 2021):
My workaround is that disabling config portal and calling autoConnect() again until wifi connects. (tested on M5Paper, using 2.0.3-alpha from Arduino Board Manager)
On the second or third try, autoConnect() outputs failure log like first attempt (WL_STATION_WRONG_PASSWORD) , but the connection is actually established. I don't know why but it's working now.
To show config portal, I added checking of button press on launch and call startConfigPortal() if the button has pressed.
@costyn commented on GitHub (Feb 9, 2021):
I have the same thing on my project. Except it's when I've just uploaded the firmware (platformio + VSCode) through USB. If I use OTA the issue doesn't happen. If I hit the reset button on the ESP it comes back straight away.
I have noticed the same behavior before I was using WifiManager, and just the regular ESP Wifi.h. I thought it was a bug in my router perhaps, not allowing a client to join so quickly after leaving. A throttling function perhaps? Which could explain the different behaviors people are seeing?
@Patronics commented on GitHub (May 3, 2021):
I'm also running into the same issue, the connection is failing with every other restart, and every time the program is reuploaded. Is there any news regarding a potential fix for this issue?
@Patronics commented on GitHub (May 3, 2021):
Nevermind, the setConnectRetries() function worked around this issue for me, as described here: https://github.com/tzapu/WiFiManager/issues/979#issuecomment-831057723