[GH-ISSUE #1021] How can I return to Ap mode when I press the reset button? #868

Closed
opened 2026-02-28 01:27:25 +03:00 by kerem · 3 comments
Owner

Originally created by @PozitronikTech on GitHub (Mar 13, 2020).
Original GitHub issue: https://github.com/tzapu/WiFiManager/issues/1021

How can I return to Ap mode when I press the reset button?

WiFimanager Branch/Release:

  • Master

Esp8266/Esp32:

  • ESP8266

Hardware: ESP-12e, esp01, esp25

  • ESP12 E/F/S (nodemcu, wemos, feather)

** Using esp version

  • 2.2.2-dev(38a443e)

Ap Mode -> STA Mode -> Web Server -> Void Loop (server->handleClient(); or button.read();)
It starts in Ap mode.
I include Esp8266 in a network and the system is rebooting.
When it restarts (in STA mode) the Web server gets up so that I can control the devices with json data.

I will put the device in a box. Outside this box, there will be a button to reset the device. When I press the button, I want to delete the SSID and password in the eeprom and start in AP mode.
I have tried many methods.
Pressing the button continues to connect to the network, starting with the information in memory each time. Do you have a solution suggestion for this? We can do without going out of the wifimanager library. Thank you

Settings in IDE

Module: NodeMcu 1.0 (ESP-12e Module)
Builtin led: 2
upload speed : 115200
cpu freq: 80mhz
flash size: 4mb(fs:2mb ota: ~1019kb)
debug port: disabled
debug level: noting
ivip varinat: v2 lover memory
vtables: flash
exceptions: legacy (new can return nullptr)
erase flash : only sketch
ssl support: all ssl ciphers (most compatible)
port: 8 com


** Home Automation

//SPI
#include <SPI.h>

// Esp8266 ana kütüphanesi
#include <ESP8266WiFi.h>          //https://github.com/esp8266/Arduino
#include <EasyButton.h>


//Dns, web server bir de Otomatik bağlanmayı sağlayan wifi manager kütüphanesi
#include <DNSServer.h>
#include <ESP8266WebServer.h>
#include "WiFiManager.h"         //https://github.com/tzapu/WiFiManager

std::unique_ptr<ESP8266WebServer> server;

#include <ArduinoJson.h>



// Bu kısımda dijital pin 4 için giriş olarak ayarlanıyor.
#define ButtonReset 2 // dijital 4 e denk geliyor.
EasyButton button(ButtonReset);


//Bu zaman aşımı kadar ağa bağlanmaya çalışır. Bağlanamadığında hotspot yayını yapan ağ ayağa kaldırır.
//int timeoutDelayTime = 30;

//Sunucu çalıştığında aldığı ip adresi üzerinden yayın yaptığı web sayfası içeriği
const String postForms = "<html>\
  <head>\
    <title>ESP8266 Web Server POST handling</title>\
    <meta Content-Type: application/json; charset=utf-8>\
    <style>\
      body { background-color: #cccccc; font-family: Arial, Helvetica, Sans-Serif; Color: #000088; }\
    </style>\
  </head>\
  <body>\
    <h1>POST plain text to /postplain/</h1><br>\
    <form method=\"post\" enctype=\"text/plain\" action=\"/postplain/\">\
      <input type=\"text\" name=\'val\'value=\'{\"token\":\"hauto\", \"message\":\"Mesaj icerigi buraya\"}\'><br>\
      <input type=\"submit\" value=\"Submit\">\
    </form>\
  </body>\
</html>";


void onPressed(){
  Serial.println("Butona basıldı.");
  Serial.println("button press but how I can :) ");
  //I can't solve this part

  Serial.println("Bağlantı başarılı");  
}


//Web sunucu başarılı ayağa kalktığında web sayfasını post ediyor.
void handleRoot() {
  server->send(200, "text/html", postForms);
}

// Post işlemini alıp geriye döndüren kısım
void handlePlain() {
  if (server->method() != HTTP_POST) {
    server->send(405, "text/plain", "Istek tarafindan verilen yontem \n istek tarafindan kaynak icin izin verilmez. \n Dogrudan hatayi bulmaniz gerekmekte");
  } else {
    server->send(200, "text/plain", server->arg("plain"));
    Serial.print("Gelen Json verisi: ");
    //Serial.println(server->arg("plain"));
    String gelenJson = server->arg("plain");
    Serial.println(gelenJson);
    int i=0;
    for(i=0; i<gelenJson.length(); i++)
    {
      Serial.print("Kod Hex: ");
      Serial.print(gelenJson[i],HEX);
      Serial.print("  Gelen: ");
      Serial.println(String(gelenJson[i]));
    }
    const size_t bufferSize = JSON_OBJECT_SIZE(4);
    DynamicJsonBuffer jsonBuffer(bufferSize);
    JsonObject& root = jsonBuffer.parseObject(gelenJson);

    const char*  Token = root["token"]; 
    const char* Message = root["message"];
    int xKordinat = root["x"];
    int yKordinat = root["y"];

    Serial.print("Token: ");
    Serial.println(Token);
    Serial.print("Mesaj: ");
    Serial.println(Message);
    

  }
}

// Hata durumunda, hata içeriği üreterek basan kısım
void handleNotFound() {
  String message = "Dosya bulunamadı\n\n";
  message += "URI: ";
  message += server->uri();
  message += "\nMethod: ";
  message += (server->method() == HTTP_GET) ? "GET" : "POST";
  message += "\nArguments: ";
  message += server->args();
  message += "\n";
  for (uint8_t i = 0; i < server->args(); i++) {
    message += " " + server->argName(i) + ": " + server->arg(i) + "\n";
  }
  server->send(404, "text/plain", message);
  Serial.println("Hata var...");
}

void setup() {
    // Reset butonu işlevi için d4 button girişi ayarlandı
    button.begin();
    button.onPressed(onPressed);
    // Buraya daha önce uygulanmasını istediğiniz kodu yerleştirin
    Serial.begin(115200);

    Serial.println("Using ESP version: ");
    Serial.println(ESP.getSdkVersion());
    // Debug mesajlarını da görmek için açıklama satırını kaldırın
    Serial.setDebugOutput(true);
  

    //Wifi manager başlıyor. Bir kez çalıştırılması yeterli
    WiFiManager wifiManager;

    //Kayıtlı ayarları sıfırlar
    //wifiManager.resetSettings();


    //Statik ip yapılandirması
    //IPAddress _ip = IPAddress(192, 168, 43, 43);  // ip adres
    //IPAddress _gw = IPAddress(192, 168, 43, 1);   // gateway
    //IPAddress _sn = IPAddress(255, 255, 255, 0);  // subnet
    //wifiManager.setSTAStaticIPConfig(_ip, _gw, _sn);


    // Esir portalı (hotspot) yayınının ip,gw,sn ini statik hale getirilmek istendiğinde buradan ayarlanacaktır.
    // wifiManager.setAPStaticIPConfig(IPAddress(10,0,1,1), IPAddress(10,0,1,1), IPAddress(255,255,255,0));


    //timeout süresi. Eğer ağa bağlanamazsa  bu süre sonunda hotspot yayını açar.
    //wifiManager.setConnectTimeout(timeoutDelayTime);
  
    // Kayıtlı ağ yoksa veya bağlanamıyorsa 
    wifiManager.autoConnect("Home Station","homestationPassword");

    //Buraya geldiğinizde ağa bağlanmış olursunuz.
    Serial.println("bağlantı başarılı.");
  

    // server resetlendikten sonra web sunucuyu 80. porttan yayın yapacak şekilde başlatıcak.
    server.reset(new ESP8266WebServer(WiFi.localIP(), 80));

    server->on("/", handleRoot);
    server->on("/postplain/", handlePlain);
  
    // bağlantı adresinin yanına /resetWifi yazarsak esp ayarlarını sıfırlarız
    /*
    server->on("/resetWifi", [](){
    server->send(200, "text/html", "WiFi resetleniyor.");
    Serial.println("Wifi resetleniyor.");
    //wifiManager.resetSettings();
    //ESP.resetSettings();
    //WiFi.disconnect(true);
    delay(1000);
  });*/
  
  
  //Örnek sayfa
  //server->on("/ornek", []() {
  //  server->send(200, "text/plain", "Deneme");
  //});

  // Hata yakaladığında hata methodunu çağırıyor.
  server->onNotFound(handleNotFound);

  // Hata yok ise server başlatılıyor.
  server->begin();
  Serial.println("HTTP sunucu başlatılıyor");
  //Serial.println(WiFi.localIP());
  Serial.print("Alınan IP adresi: ");
  String LocalIP = String()+WiFi.localIP()[0]+"."+WiFi.localIP()[1]+"."+WiFi.localIP()[2]+"."+WiFi.localIP()[3];
  Serial.println(LocalIP);
  
}


void loop() {
  // Tekrarlı çalışmasını istediğiniz kodu buraya yazın
  button.read();
  //Reset pini tetiklendiğinde tekrar hotspot yayını yapmaya çalışacak.
  /*
  if ( digitalRead(triggerPin) == LOW ) {
    //WiFiManager wifiManager;
    if (!wifiManager.startConfigPortal("Tekobel_LedPanel","easio1234")) {
      Serial.println("Bağlantı kurulamadı ve zaman aşımına uğradı");
      delay(3000);
      //reset and try again, or maybe put it to deep sleep
      ESP.reset();
      delay(5000);
    }
    Serial.println("Bağlantı başarılı");
  }
  */
  //İstemci bağlantılarını buradan takip edicek.
  
  server->handleClient();


}

Debug Messages

			Using ESP version:

09:25:20.570 -> 2.2.2-dev(38a443e)
09:25:20.570 -> *WM:
09:25:20.570 -> *WM: AutoConnect
09:25:20.570 -> bcn 0
09:25:20.570 -> del if1
09:25:20.570 -> usl
09:25:20.570 -> mode : sta(xx:xx:xx:xx:xx:x) //xx hiding mac
09:25:20.570 -> add if0
09:25:20.604 -> *WM: Connecting as wifi client...
09:25:20.638 -> *WM: Status:
09:25:20.638 -> *WM: 0
09:25:20.638 -> *WM: No saved credentials
09:25:20.638 -> *WM: Connection result:
09:25:20.638 -> *WM: 0
09:25:20.638 -> del if0
09:25:20.638 -> usl
09:25:20.638 -> mode : softAP(xx:xx:xx:xx:xx:x)
09:25:20.638 -> add if1
09:25:20.638 -> dhcp server start:(ip:192.168.4.1,mask:255.255.255.0,gw:192.168.4.1)
09:25:20.638 -> bcn 100
09:25:20.638 -> *WM:
09:25:20.638 -> *WM: Configuring access point...
09:25:20.638 -> *WM: Home Station
09:25:20.638 -> *WM: homestationPassword
09:25:22.458 -> bcn 0
09:25:22.458 -> del if1
09:25:22.458 -> usl
09:25:22.458 -> add if1
09:25:22.458 -> dhcp server start:(ip:192.168.4.1,mask:255.255.255.0,gw:192.168.4.1)
09:25:22.458 -> bcn 100
09:25:22.975 -> *WM: AP IP address:
09:25:22.975 -> *WM: 192.168.4.1
09:25:22.975 -> *WM: HTTP server started
09:26:35.392 -> add 1
09:26:35.392 -> aid 1
09:26:35.392 -> station: 14:5f:94:c1:07:61 join, AID = 1
09:26:38.729 -> *WM: Request redirected to captive portal
09:26:38.900 -> *WM: Handle root
09:26:38.900 -> *WM: Request redirected to captive portal
09:26:38.935 -> *WM: Request redirected to captive portal
09:26:39.038 -> *WM: Handle root
09:26:39.072 -> *WM: Request redirected to captive portal
09:26:51.143 -> *WM: Request redirected to captive portal
09:26:54.034 -> *WM: Handle root
09:26:54.034 -> *WM: Request redirected to captive portal
09:26:54.068 -> *WM: Handle root
09:26:54.068 -> *WM: Request redirected to captive portal
09:26:54.068 -> *WM: Handle root
09:26:54.068 -> *WM: Request redirected to captive portal
09:26:54.068 -> *WM: Handle root
09:26:54.102 -> *WM: Handle root
09:26:54.102 -> *WM: Handle root
09:26:55.718 -> *WM: Handle root
09:27:01.137 -> mode : sta(xx:xx:xx:xx:xx:x) + softAP(xx:xx:xx:xx:xx:x)
09:27:01.137 -> add if0
09:27:03.374 -> scandone
09:27:03.374 -> *WM: Scan done
09:27:03.374 -> *WM: HomeNetwork
09:27:03.374 -> *WM: -39
09:27:03.442 -> *WM: Sent config page
09:27:13.441 -> *WM: Request redirected to captive portal
09:27:25.794 -> *WM: Request redirected to captive portal
09:27:27.783 -> *WM: Request redirected to captive portal
09:27:31.737 -> *WM: WiFi save
09:27:31.737 -> *WM: Sent wifi save page
09:27:32.729 -> *WM: Connecting to new AP
09:27:32.729 -> *WM: Connecting as wifi client...
09:27:32.729 -> *WM: Status:
09:27:32.729 -> *WM: 0
09:27:32.799 -> *WM: [ERROR] WiFi.begin res:
09:27:32.799 -> *WM: 6
09:27:34.971 -> scandone
09:27:34.971 -> no HomeNetwork found, reconnect after 1s
09:27:35.073 -> reconnect
09:27:37.244 -> scandone
09:27:38.202 -> state: 0 -> 2 (b0)
09:27:38.202 -> state: 2 -> 3 (0)
09:27:38.270 -> state: 3 -> 5 (10)
09:27:38.270 -> add 0
09:27:38.270 -> aid 1
09:27:38.270 -> cnt
09:27:38.270 ->
09:27:38.270 -> connected with HomeNetwork, channel 1
09:27:38.340 -> dhcp client start...
09:27:41.368 -> ip:192.168.43.245,mask:255.255.255.0,gw:192.168.43.1
09:27:41.368 -> *WM: Connection result:
09:27:41.368 -> *WM: 3
09:27:41.368 -> station: xx:xx:xx:xx:xx:x leave, AID = 1
09:27:41.368 -> rm 1
09:27:41.368 -> bcn 0
09:27:41.368 -> del if1
09:27:41.368 -> pm open,type:2 0
09:27:41.368 -> mode : sta(xx:xx:xx:xx:xx:x)
09:27:41.402 -> bağlantı başarılı.
09:27:41.402 -> HTTP sunucu başlatılıyor
09:27:41.436 -> Alınan IP adresi: 192.168.43.245
09:27:41.436 -> *WM: freeing allocated params!
09:28:03.113 -> Butona basıldı.
09:28:03.113 -> button press but how I can :)

Originally created by @PozitronikTech on GitHub (Mar 13, 2020). Original GitHub issue: https://github.com/tzapu/WiFiManager/issues/1021 How can I return to Ap mode when I press the reset button? **WiFimanager Branch/Release:** - [x] Master **Esp8266/Esp32:** - [x] ESP8266 **Hardware: ESP-12e, esp01, esp25** - [x] ESP12 E/F/S (nodemcu, wemos, feather) ** Using esp version - 2.2.2-dev(38a443e) Ap Mode -> STA Mode -> Web Server -> Void Loop (server->handleClient(); or button.read();) It starts in Ap mode. I include Esp8266 in a network and the system is rebooting. When it restarts (in STA mode) the Web server gets up so that I can control the devices with json data. I will put the device in a box. Outside this box, there will be a button to reset the device. When I press the button, I want to delete the SSID and password in the eeprom and start in AP mode. I have tried many methods. Pressing the button continues to connect to the network, starting with the information in memory each time. Do you have a solution suggestion for this? We can do without going out of the wifimanager library. Thank you ### Settings in IDE Module: NodeMcu 1.0 (ESP-12e Module) Builtin led: 2 upload speed : 115200 cpu freq: 80mhz flash size: 4mb(fs:2mb ota: ~1019kb) debug port: disabled debug level: noting ivip varinat: v2 lover memory vtables: flash exceptions: legacy (new can return nullptr) erase flash : only sketch ssl support: all ssl ciphers (most compatible) port: 8 com ```c ** Home Automation //SPI #include <SPI.h> // Esp8266 ana kütüphanesi #include <ESP8266WiFi.h> //https://github.com/esp8266/Arduino #include <EasyButton.h> //Dns, web server bir de Otomatik bağlanmayı sağlayan wifi manager kütüphanesi #include <DNSServer.h> #include <ESP8266WebServer.h> #include "WiFiManager.h" //https://github.com/tzapu/WiFiManager std::unique_ptr<ESP8266WebServer> server; #include <ArduinoJson.h> // Bu kısımda dijital pin 4 için giriş olarak ayarlanıyor. #define ButtonReset 2 // dijital 4 e denk geliyor. EasyButton button(ButtonReset); //Bu zaman aşımı kadar ağa bağlanmaya çalışır. Bağlanamadığında hotspot yayını yapan ağ ayağa kaldırır. //int timeoutDelayTime = 30; //Sunucu çalıştığında aldığı ip adresi üzerinden yayın yaptığı web sayfası içeriği const String postForms = "<html>\ <head>\ <title>ESP8266 Web Server POST handling</title>\ <meta Content-Type: application/json; charset=utf-8>\ <style>\ body { background-color: #cccccc; font-family: Arial, Helvetica, Sans-Serif; Color: #000088; }\ </style>\ </head>\ <body>\ <h1>POST plain text to /postplain/</h1><br>\ <form method=\"post\" enctype=\"text/plain\" action=\"/postplain/\">\ <input type=\"text\" name=\'val\'value=\'{\"token\":\"hauto\", \"message\":\"Mesaj icerigi buraya\"}\'><br>\ <input type=\"submit\" value=\"Submit\">\ </form>\ </body>\ </html>"; void onPressed(){ Serial.println("Butona basıldı."); Serial.println("button press but how I can :) "); //I can't solve this part Serial.println("Bağlantı başarılı"); } //Web sunucu başarılı ayağa kalktığında web sayfasını post ediyor. void handleRoot() { server->send(200, "text/html", postForms); } // Post işlemini alıp geriye döndüren kısım void handlePlain() { if (server->method() != HTTP_POST) { server->send(405, "text/plain", "Istek tarafindan verilen yontem \n istek tarafindan kaynak icin izin verilmez. \n Dogrudan hatayi bulmaniz gerekmekte"); } else { server->send(200, "text/plain", server->arg("plain")); Serial.print("Gelen Json verisi: "); //Serial.println(server->arg("plain")); String gelenJson = server->arg("plain"); Serial.println(gelenJson); int i=0; for(i=0; i<gelenJson.length(); i++) { Serial.print("Kod Hex: "); Serial.print(gelenJson[i],HEX); Serial.print(" Gelen: "); Serial.println(String(gelenJson[i])); } const size_t bufferSize = JSON_OBJECT_SIZE(4); DynamicJsonBuffer jsonBuffer(bufferSize); JsonObject& root = jsonBuffer.parseObject(gelenJson); const char* Token = root["token"]; const char* Message = root["message"]; int xKordinat = root["x"]; int yKordinat = root["y"]; Serial.print("Token: "); Serial.println(Token); Serial.print("Mesaj: "); Serial.println(Message); } } // Hata durumunda, hata içeriği üreterek basan kısım void handleNotFound() { String message = "Dosya bulunamadı\n\n"; message += "URI: "; message += server->uri(); message += "\nMethod: "; message += (server->method() == HTTP_GET) ? "GET" : "POST"; message += "\nArguments: "; message += server->args(); message += "\n"; for (uint8_t i = 0; i < server->args(); i++) { message += " " + server->argName(i) + ": " + server->arg(i) + "\n"; } server->send(404, "text/plain", message); Serial.println("Hata var..."); } void setup() { // Reset butonu işlevi için d4 button girişi ayarlandı button.begin(); button.onPressed(onPressed); // Buraya daha önce uygulanmasını istediğiniz kodu yerleştirin Serial.begin(115200); Serial.println("Using ESP version: "); Serial.println(ESP.getSdkVersion()); // Debug mesajlarını da görmek için açıklama satırını kaldırın Serial.setDebugOutput(true); //Wifi manager başlıyor. Bir kez çalıştırılması yeterli WiFiManager wifiManager; //Kayıtlı ayarları sıfırlar //wifiManager.resetSettings(); //Statik ip yapılandirması //IPAddress _ip = IPAddress(192, 168, 43, 43); // ip adres //IPAddress _gw = IPAddress(192, 168, 43, 1); // gateway //IPAddress _sn = IPAddress(255, 255, 255, 0); // subnet //wifiManager.setSTAStaticIPConfig(_ip, _gw, _sn); // Esir portalı (hotspot) yayınının ip,gw,sn ini statik hale getirilmek istendiğinde buradan ayarlanacaktır. // wifiManager.setAPStaticIPConfig(IPAddress(10,0,1,1), IPAddress(10,0,1,1), IPAddress(255,255,255,0)); //timeout süresi. Eğer ağa bağlanamazsa bu süre sonunda hotspot yayını açar. //wifiManager.setConnectTimeout(timeoutDelayTime); // Kayıtlı ağ yoksa veya bağlanamıyorsa wifiManager.autoConnect("Home Station","homestationPassword"); //Buraya geldiğinizde ağa bağlanmış olursunuz. Serial.println("bağlantı başarılı."); // server resetlendikten sonra web sunucuyu 80. porttan yayın yapacak şekilde başlatıcak. server.reset(new ESP8266WebServer(WiFi.localIP(), 80)); server->on("/", handleRoot); server->on("/postplain/", handlePlain); // bağlantı adresinin yanına /resetWifi yazarsak esp ayarlarını sıfırlarız /* server->on("/resetWifi", [](){ server->send(200, "text/html", "WiFi resetleniyor."); Serial.println("Wifi resetleniyor."); //wifiManager.resetSettings(); //ESP.resetSettings(); //WiFi.disconnect(true); delay(1000); });*/ //Örnek sayfa //server->on("/ornek", []() { // server->send(200, "text/plain", "Deneme"); //}); // Hata yakaladığında hata methodunu çağırıyor. server->onNotFound(handleNotFound); // Hata yok ise server başlatılıyor. server->begin(); Serial.println("HTTP sunucu başlatılıyor"); //Serial.println(WiFi.localIP()); Serial.print("Alınan IP adresi: "); String LocalIP = String()+WiFi.localIP()[0]+"."+WiFi.localIP()[1]+"."+WiFi.localIP()[2]+"."+WiFi.localIP()[3]; Serial.println(LocalIP); } void loop() { // Tekrarlı çalışmasını istediğiniz kodu buraya yazın button.read(); //Reset pini tetiklendiğinde tekrar hotspot yayını yapmaya çalışacak. /* if ( digitalRead(triggerPin) == LOW ) { //WiFiManager wifiManager; if (!wifiManager.startConfigPortal("Tekobel_LedPanel","easio1234")) { Serial.println("Bağlantı kurulamadı ve zaman aşımına uğradı"); delay(3000); //reset and try again, or maybe put it to deep sleep ESP.reset(); delay(5000); } Serial.println("Bağlantı başarılı"); } */ //İstemci bağlantılarını buradan takip edicek. server->handleClient(); } ``` ### Debug Messages Using ESP version: 09:25:20.570 -> 2.2.2-dev(38a443e) 09:25:20.570 -> *WM: 09:25:20.570 -> *WM: AutoConnect 09:25:20.570 -> bcn 0 09:25:20.570 -> del if1 09:25:20.570 -> usl 09:25:20.570 -> mode : sta(xx:xx:xx:xx:xx:x) //xx hiding mac 09:25:20.570 -> add if0 09:25:20.604 -> *WM: Connecting as wifi client... 09:25:20.638 -> *WM: Status: 09:25:20.638 -> *WM: 0 09:25:20.638 -> *WM: No saved credentials 09:25:20.638 -> *WM: Connection result: 09:25:20.638 -> *WM: 0 09:25:20.638 -> del if0 09:25:20.638 -> usl 09:25:20.638 -> mode : softAP(xx:xx:xx:xx:xx:x) 09:25:20.638 -> add if1 09:25:20.638 -> dhcp server start:(ip:192.168.4.1,mask:255.255.255.0,gw:192.168.4.1) 09:25:20.638 -> bcn 100 09:25:20.638 -> *WM: 09:25:20.638 -> *WM: Configuring access point... 09:25:20.638 -> *WM: Home Station 09:25:20.638 -> *WM: homestationPassword 09:25:22.458 -> bcn 0 09:25:22.458 -> del if1 09:25:22.458 -> usl 09:25:22.458 -> add if1 09:25:22.458 -> dhcp server start:(ip:192.168.4.1,mask:255.255.255.0,gw:192.168.4.1) 09:25:22.458 -> bcn 100 09:25:22.975 -> *WM: AP IP address: 09:25:22.975 -> *WM: 192.168.4.1 09:25:22.975 -> *WM: HTTP server started 09:26:35.392 -> add 1 09:26:35.392 -> aid 1 09:26:35.392 -> station: 14:5f:94:c1:07:61 join, AID = 1 09:26:38.729 -> *WM: Request redirected to captive portal 09:26:38.900 -> *WM: Handle root 09:26:38.900 -> *WM: Request redirected to captive portal 09:26:38.935 -> *WM: Request redirected to captive portal 09:26:39.038 -> *WM: Handle root 09:26:39.072 -> *WM: Request redirected to captive portal 09:26:51.143 -> *WM: Request redirected to captive portal 09:26:54.034 -> *WM: Handle root 09:26:54.034 -> *WM: Request redirected to captive portal 09:26:54.068 -> *WM: Handle root 09:26:54.068 -> *WM: Request redirected to captive portal 09:26:54.068 -> *WM: Handle root 09:26:54.068 -> *WM: Request redirected to captive portal 09:26:54.068 -> *WM: Handle root 09:26:54.102 -> *WM: Handle root 09:26:54.102 -> *WM: Handle root 09:26:55.718 -> *WM: Handle root 09:27:01.137 -> mode : sta(xx:xx:xx:xx:xx:x) + softAP(xx:xx:xx:xx:xx:x) 09:27:01.137 -> add if0 09:27:03.374 -> scandone 09:27:03.374 -> *WM: Scan done 09:27:03.374 -> *WM: HomeNetwork 09:27:03.374 -> *WM: -39 09:27:03.442 -> *WM: Sent config page 09:27:13.441 -> *WM: Request redirected to captive portal 09:27:25.794 -> *WM: Request redirected to captive portal 09:27:27.783 -> *WM: Request redirected to captive portal 09:27:31.737 -> *WM: WiFi save 09:27:31.737 -> *WM: Sent wifi save page 09:27:32.729 -> *WM: Connecting to new AP 09:27:32.729 -> *WM: Connecting as wifi client... 09:27:32.729 -> *WM: Status: 09:27:32.729 -> *WM: 0 09:27:32.799 -> *WM: [ERROR] WiFi.begin res: 09:27:32.799 -> *WM: 6 09:27:34.971 -> scandone 09:27:34.971 -> no HomeNetwork found, reconnect after 1s 09:27:35.073 -> reconnect 09:27:37.244 -> scandone 09:27:38.202 -> state: 0 -> 2 (b0) 09:27:38.202 -> state: 2 -> 3 (0) 09:27:38.270 -> state: 3 -> 5 (10) 09:27:38.270 -> add 0 09:27:38.270 -> aid 1 09:27:38.270 -> cnt 09:27:38.270 -> 09:27:38.270 -> connected with HomeNetwork, channel 1 09:27:38.340 -> dhcp client start... 09:27:41.368 -> ip:192.168.43.245,mask:255.255.255.0,gw:192.168.43.1 09:27:41.368 -> *WM: Connection result: 09:27:41.368 -> *WM: 3 09:27:41.368 -> station: xx:xx:xx:xx:xx:x leave, AID = 1 09:27:41.368 -> rm 1 09:27:41.368 -> bcn 0 09:27:41.368 -> del if1 09:27:41.368 -> pm open,type:2 0 09:27:41.368 -> mode : sta(xx:xx:xx:xx:xx:x) 09:27:41.402 -> bağlantı başarılı. 09:27:41.402 -> HTTP sunucu başlatılıyor 09:27:41.436 -> Alınan IP adresi: 192.168.43.245 09:27:41.436 -> *WM: freeing allocated params! 09:28:03.113 -> Butona basıldı. 09:28:03.113 -> button press but how I can :)
kerem closed this issue 2026-02-28 01:27:26 +03:00
Author
Owner

@PozitronikTech commented on GitHub (Mar 13, 2020):

All information is deleted when you clear the Eeprom memory. Thus, it can be started in Ap mode.
How do we do this through wifimanager?

<!-- gh-comment-id:598670797 --> @PozitronikTech commented on GitHub (Mar 13, 2020): All information is deleted when you clear the Eeprom memory. Thus, it can be started in Ap mode. How do we do this through wifimanager?
Author
Owner

@tablatronix commented on GitHub (Mar 13, 2020):

or just startConfigPortal, its in the ondemandconfigportal examples...

<!-- gh-comment-id:598717986 --> @tablatronix commented on GitHub (Mar 13, 2020): or just startConfigPortal, its in the ondemandconfigportal examples...
Author
Owner

@PozitronikTech commented on GitHub (Mar 16, 2020):

Thank u

<!-- gh-comment-id:599522880 --> @PozitronikTech commented on GitHub (Mar 16, 2020): Thank u
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#868
No description provided.