Fixed a 404 occurs at the captive portal #206

pull/207/head
Hieromon Ikasamo 5 years ago
parent d8c1223d6f
commit 9d43f74157
  1. 2
      examples/mqttRSSI/mqttRSSI.ino
  2. 2
      examples/mqttRSSI_FS/mqttRSSI_FS.ino
  3. 2
      examples/mqttRSSI_NA/mqttRSSI_NA.ino

@ -366,7 +366,6 @@ void setup() {
config.hostName = hostName; config.hostName = hostName;
Serial.println("hostname set to " + config.hostName); Serial.println("hostname set to " + config.hostName);
} }
config.bootUri = AC_ONBOOTURI_HOME;
config.homeUri = "/"; config.homeUri = "/";
portal.config(config); portal.config(config);
@ -378,6 +377,7 @@ void setup() {
Serial.print("WiFi "); Serial.print("WiFi ");
if (portal.begin()) { if (portal.begin()) {
config.bootUri = AC_ONBOOTURI_HOME;
Serial.println("connected:" + WiFi.SSID()); Serial.println("connected:" + WiFi.SSID());
Serial.println("IP:" + WiFi.localIP().toString()); Serial.println("IP:" + WiFi.localIP().toString());
} }

@ -243,7 +243,6 @@ void setup() {
config.hostName = hostnameElm.value; config.hostName = hostnameElm.value;
Serial.println("hostname set to " + config.hostName); Serial.println("hostname set to " + config.hostName);
} }
config.bootUri = AC_ONBOOTURI_HOME;
config.homeUri = "/"; config.homeUri = "/";
portal.config(config); portal.config(config);
@ -255,6 +254,7 @@ void setup() {
Serial.print("WiFi "); Serial.print("WiFi ");
if (portal.begin()) { if (portal.begin()) {
config.bootUri = AC_ONBOOTURI_HOME;
Serial.println("connected:" + WiFi.SSID()); Serial.println("connected:" + WiFi.SSID());
Serial.println("IP:" + WiFi.localIP().toString()); Serial.println("IP:" + WiFi.localIP().toString());
} else { } else {

@ -221,7 +221,6 @@ void setup() {
Serial.println("apid set to " + config.apid); Serial.println("apid set to " + config.apid);
} }
config.bootUri = AC_ONBOOTURI_HOME;
config.homeUri = "/"; config.homeUri = "/";
portal.config(config); portal.config(config);
@ -231,6 +230,7 @@ void setup() {
Serial.print("WiFi "); Serial.print("WiFi ");
if (portal.begin()) { if (portal.begin()) {
config.bootUri = AC_ONBOOTURI_HOME;
Serial.println("connected:" + WiFi.SSID()); Serial.println("connected:" + WiFi.SSID());
Serial.println("IP:" + WiFi.localIP().toString()); Serial.println("IP:" + WiFi.localIP().toString());
} }

Loading…
Cancel
Save