-->
Page 1 of 1

Slow Connection to Access Point

PostPosted: Sun Jul 02, 2017 9:48 am
by Guus
Hi,

I am currently working on a project where i make my ESP8266 create an access point which users can connect to using their phone.
Theres one problem however, when trying to connect to the Access Point it will take up to 60 seconds or more to fully connect. And sometimes (on iOS at least) it will not connect at all and give an error about being unable to connect.
Code: Select all  WiFi.disconnect();
  WiFi.mode(WIFI_AP);
  Serial.print("Autoconnect status: ");
  Serial.println(WiFi.getAutoConnect());
  WiFi.setAutoReconnect(false);
  WiFi.setAutoConnect(false);
  WiFi.softAPConfig(ip, gateway, subnet);
  if(WiFi.softAP(accessPointSSID, accessPointPassword, 6)) {
    Serial.print("Succesfully setup Access Point with:");
    Serial.print(accessPointSSID);
    Serial.print(", ");
    Serial.println(accessPointPassword);
  } else {
    Serial.print("Failed to setup Acces Point with:");
    Serial.print(accessPointSSID);
    Serial.print(", ");
    Serial.println(accessPointPassword);
  }


My loop function only has a call to handle the webserver (for api calls and such)
Code: Select allvoid loop(void) {
  server.handleClient();
}


This is how i setup the access point in setup function


Does anybody know how to resolve this issue?

Thanks for reading!

Re: Slow Connection to Access Point

PostPosted: Sun Jul 02, 2017 5:46 pm
by QuickFix
Normally a full connect should only take a couple of seconds.

Does this also occur with the first device that wants to connect or after a couple of devices are already connected?
I can imagine there's a limit of the number of devices that can connect to the ESP in AP mode simultaneously.

Re: Slow Connection to Access Point

PostPosted: Mon Jul 03, 2017 9:53 am
by Guus
QuickFix wrote:Normally a full connect should only take a couple of seconds.

Does this also occur with the first device that wants to connect or after a couple of devices are already connected?
I can imagine there's a limit of the number of devices that can connect to the ESP in AP mode simultaneously.

The problem occurs on the very first device that connects and every other that connects afterwards aswell.