Added an http port definition

pull/8/head
Hieromon Ikasamo 7 years ago
parent 26a1207e64
commit 0fad2b23ad
  1. 1
      mkdocs/api.md
  2. 2
      src/AutoConnect.cpp
  3. 4
      src/AutoConnect.h

@ -15,6 +15,7 @@
#define AUTOCONNECT_AP_GW 0x01F4A8C0 // Default SoftAP Gateway IP
#define AUTOCONNECT_AP_NM 0x00FFFFFF // Default subnet mask
#define AUTOCONNECT_DNSPORT 53 // Default DNS port at captive portal
#define AUTOCONNECT_HTTPPORT 80 // Default HTTP
#define AUTOCONNECT_MENU_TITLE "AutoConnect" // Default AutoConnect menu title
#define AUTOCONNECT_STARTUPTIME 10 // Default waiting time[s] for after reset
#define AUTOCONNECT_URI "/_ac" // Default AutoConnect root path

@ -231,7 +231,7 @@ void AutoConnect::_startWebServer() {
// Boot Web server
if (!_webServer) {
// Only when hosting WebServer internally
_webServer.reset(new ESP8266WebServer(80));
_webServer.reset(new ESP8266WebServer(AUTOCONNECT_HTTPPORT));
_webServerAlloc = AC_WEBSERVER_HOSTED;
AC_DBG("ESP8266WebServer allocated\n");
}

@ -84,6 +84,10 @@ extern "C" {
#define AUTOCONNECT_STARTUPTIME 10
#endif
#ifndef AUTOCONNECT_HTTPPORT
#define AUTOCONNECT_HTTPPORT 80
#endif
#ifndef AUTOCONNECT_DNSPORT
#define AUTOCONNECT_DNSPORT 53
#endif

Loading…
Cancel
Save