Your new topic does not fit any of the above??? Check first. Then post here. Thanks.

Moderator: igrr

User avatar
By esp8266_dude
#96308 Hello,
I made several projects using one ESP8266 as AP (access point), and another as STAs (stations). Sometimes I also use PC as another STA.
As PC are used rarely here, so I missed some strange issue.
"Slave" ESPs connects to ESP AP without problems. And, for example, exchange UDP packets successfully.
My main PC also connects to this WiFi network without problems:
But I recently discovered, that some another PCs, have issue with connection:

I have to go to network setting, an manually attach IP address:

Then connection works fine.
But this is very inconvenient in use, because when I want to back to main internet WiFi connection, I have to restore this settings to previous state (automatic IP setup).
This PCs never have issues with connects to "normal" access points (routers).
I can connect them to any network without problems.
Only connection to ESP8266 AP give my that issue.
I know that some sources of this issue may be correlated to these PCs, but also it must be something on ESP settings, due to fact that these PCs connects successfully to normal WiFi networks (from TP-Link, etc.).
ESP8266 code is very simple:
Code: Select all#include <ESP8266WiFi.h>
#include <WiFiUdp.h>

const char* ssid = "ESP8266_WiFi_0";
const char* password = "1234ABCD";
const int AP_Channel = 4;
const int AP_Max_Connection = 4;

IPAddress local_IP(192,168,1,1);
IPAddress gateway(192,168,1,200);
IPAddress subnet(255,255,255,0);

uint8_t UDP_RX[2048];

void setup()

  Serial.println("Setting AP");

  Serial.println(WiFi.softAPConfig(local_IP, gateway, subnet) ? "Ready" : "Failed");

  Serial.println("Setting AP");

  Serial.println(WiFi.softAP(ssid, password, AP_Channel, false, AP_Max_Connection) ? "Ready" :


  Serial.print("AP address: ");


void loop()
  uint8_t i;

  UDP_RX_packet_size = UDP1.parsePacket();
  if (UDP_RX_packet_size > 0)
      {*)UDP_RX, UDP_RX_packet_size);

      for (i = 0; i < DP_RX_packet_size; i++)

I also tried another IP settings on ESP.
For example, classic ESP8266 IP:
Unfortunately without success.
So my question is, if somebody has similar issue and have any solution?
Or any hints what I have to check to find out what exactly triggers this error?
Best regards
You do not have the required permissions to view the files attached to this post.
User avatar
By rooppoorali
#96343 It sounds like the issue you are experiencing may be related to the DHCP (Dynamic Host Configuration Protocol) settings on your ESP8266 AP. When a device connects to a network, it requests an IP address from a DHCP server, which assigns it a unique address on the network.

It's possible that the PCs that are having trouble connecting to your ESP8266 AP are not able to obtain an IP address automatically, which is why you have to manually assign an IP address to them. This could be due to a number of factors, such as conflicting IP addresses or incompatible DHCP settings.
Make sure that DHCP is enabled and that the IP address range is set correctly.
User avatar
By esp8266_dude
#96349 How Can I check DHCP settings?
Almost none of tutorials configure DHCP at all. ... ess-point/ ... class.html
Also I found this:
WereCatf wrote:@NarinLab Take a look at ... ftapconfig -- if you specify the ESP8266's IP-address as e.g., the function softAPConfig() sets the DHCP-range as -

So I thought that DHCP are configured automatically.
User avatar
By esp8266_dude
#96547 I would like to conquer the topic, because the number of ESP8266 to which it is impossible to connect, increase.
The same situation: another ESP connects without problems, PCs not.
Could someone tell me how to configure DHCP in ESP8266 Acces Point?