mirror of
https://github.com/tzapu/WiFiManager.git
synced 2026-04-28 01:25:49 +03:00
[GH-ISSUE #950] WiFi settings are not persistent after reboot on ESP32 #806
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#806
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 @garageeks on GitHub (Sep 27, 2019).
Original GitHub issue: https://github.com/tzapu/WiFiManager/issues/950
Basic Infos
Hardware
WiFimanager Branch/Release:
Esp8266/Esp32:
Hardware: ESP-12e, esp01, esp25
ESP Core
Description
WiFi settings are not persistent after reboot/power off, despite connection is successfully established and WiFi.persistent(true) is called before anything else
Sketch is the default OnDemandConfigPortal with minimal modifications.
Settings in IDE
Module: DOIT ESP32 DEVKIT V1
Additional libraries:
Sketch
Debug Messages
@garageeks commented on GitHub (Sep 27, 2019):
It seems the credentials are stored indeed but WiFi.SSID() response is empty for some reason, it used to work fine on ESP8266...
I tried the autoconnect portal and it connected straight away
@tablatronix commented on GitHub (Sep 27, 2019):
Esp32 is different, you can only get wifi if wifi is initialized
@tablatronix commented on GitHub (Sep 27, 2019):
Use the wm wrappers I made for this
Wifiissaved and wifissid

@garageeks commented on GitHub (Sep 27, 2019):
Thank you @tablatronix for the quick reply. I didn't find this in the documentation, will give it a try and let you know.
@tablatronix commented on GitHub (Sep 27, 2019):
There is no documentation for development yet
@viperk1 commented on GitHub (Oct 3, 2019):
@garageeks Have you got past this? I'm running into the same issue that the Wifi config gets lost on reboot
Edit: It was my mistake. I called wifi.disconnect() which erased the config.
@egrekov commented on GitHub (Dec 6, 2019):
If not use
wm.autoConnect(), you must manually startWiFi.begin(wm.getWiFiSSID(true).c_str(), wm.getWiFiPass(true).c_str())+ need to add function wachdog, which would restart the wifi when it falls off, can implement such a method in WiFiManager. That everything would work out of the box and it would not be necessary to fence their crutches.@egrekov commented on GitHub (Dec 6, 2019):
Wrote a small wrapper, it would be great if the similar functionality was out of the box
WiFiManagerExt.h
WiFiManagerExt.cpp
@egrekov commented on GitHub (Dec 6, 2019):
I redid the function a bit, it turned out that the configurator also uses port 80, but it cannot be changed in any way.
@tablatronix commented on GitHub (Dec 7, 2019):
What is the point of this? Esp32 has persistent credential storage, calling begin() should work fine.
It also has autoreconnect, which should also work fine, if neither does then you have bugs. If not you can always add an event handler for disconnect and start your own retry timer.
@egrekov commented on GitHub (Dec 9, 2019):
@tablatronix Thank you, I didn’t know that in esp32 login the password is stored independently, it is exactly checked, the begin() works. Yes, and check and vachdog is not needed, in version espressif 1.0.4 reconnect works independently. Sorry for disturbing.
@garageeks commented on GitHub (Dec 11, 2019):
I have been using autoconnect on ESP32 these week on Boards release 1.0.3, works fine.
If needed more control, we can use the getWiFiIsSaved wrapper as @tablatronix said
I think we can close this, one less issue to worry about :)