Open vtolenti89 opened 4 years ago
did you connect the WiFi of your computer to the SSID of the esp8266 SoftAP?
Yes, they are in the same network. I also tried with my phone, to no avail.
I just tried the example WebServerLed.ino
and it seems to work fine. I did not go through the source code, but I assume there is a difference between Wifi.beginAP()
and Wifi.begin()
, where the latter is used in WebServerLed.ino
.
Do you know whether it is also possible to set a fixed ip address for the Wifi.begin()
method?
For the Wifi.beginAp()
it is done via:
IPAddress localIp(192, 168, 111, 111);
WiFi.configAP(localIp);
Finally I figured out what was "wrong". I just failed to understand the difference between both methods. For the AP one, I thought that the ssid to be inserted was the my Wifi's one, which makes no sense. Now everything works perfectly.
WiFi.config(ip);
and take a look at https://github.com/jandrassy/WiFiEspAT#Why-a-new-wifiesp-library
Thanks for the reply @jandrassy. Is it necessary though, to disable DCHP in my modem and make sure that the given static ip address matches the one from the modem?
WiFi.config is AT+CIPSTA. this command disables the DHCP client
Hello,
I've just uploaded the
WebServerAp.ino
to an arduino connected to a ESP8266. The connection to my network seems to work alright, and the server starts and provides me with an Ip. However, whenever I try to access this ip in the browser, it times out.Here is the code I am using:
And this is what the serial console shows:
Whenever I try to navigate to
http://192.168.4.1
, the page cannot be found. Any ideas what went wrong?Thanks in advance.