mirror of
https://github.com/tzapu/WiFiManager.git
synced 2026-04-27 00:55:52 +03:00
[GH-ISSUE #1283] How to get saved SSID and Password #1099
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#1099
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 @rickyanwar on GitHub (Aug 25, 2021).
Original GitHub issue: https://github.com/tzapu/WiFiManager/issues/1283
i make like this to get wifi ssid and password, but when reboot i got blank, any solution for this ?
@Sudesha228 commented on GitHub (Aug 28, 2021):
We can do it with ESP8266.
#include <EEPROM.h> //The EEPROM libray
String string_Value;
float float_Value=111.2222;
void setup() {
string_Value=String(float_Value,4);
string_Value=string_Value+";";
EEPROM.begin(512);
for(int n=0; n< string_Value.length();n++){
EEPROM.write(n,string_Value[n]);
}
/* Configuration Variables for the AP name and IP. */
const char *ssid = "Test";
const char *password = "Password";
IPAddress ap_local_IP(192,168,1,1);
IPAddress ap_gateway(192,168,1,254);
IPAddress ap_subnet(255,255,255,0);EEPROM.commit();
}
void loop() {
// put your main code here, to run repeatedly:
}
WiFi.softAPConfig(ap_local_IP, ap_gateway, ap_subnet)
WiFi.softAP(ssid, password);
ESP8266WebServer server(80);
server.on("/", handleRoot);
server.onNotFound(handleNotFound);
server.begin();
server.send(200, "text/html", "
You are connected
");"
You are connected
"