ESP8266 not listening on specified port
Posted: Mon Mar 14, 2016 1:37 am
My goal is to exchange information between my ESP8266 and another device.
When I try to connect my device to the ESP8266 on 192.168.4.1 (port 80), my connection is being refused because the ESP8266 is not listening on this port.
I'm new to the ESP8266 so it's probably something minor. Any links or help would be appreciated. Here is my code:
When I try to connect my device to the ESP8266 on 192.168.4.1 (port 80), my connection is being refused because the ESP8266 is not listening on this port.
I'm new to the ESP8266 so it's probably something minor. Any links or help would be appreciated. Here is my code:
Code: Select all
#include <ESP8266WiFi.h>
#include <WiFiClient.h>
#include <ESP8266WebServer.h>
const char *ssid = "Test SSID";
const char *password = "thereisnospoon";
ESP8266WebServer server(80);
void setup() {
delay(1000);
Serial.begin(115200);
Serial.print("Configuring access point...");
WiFi.softAP(ssid, password);
IPAddress myIP = WiFi.softAPIP();
Serial.print("AP IP address: ");
Serial.println(myIP);
server.begin();
Serial.println("HTTP server started");
}
void loop() {
server.handleClient();
}