-->
Page 1 of 2

WebServer remoteIP()

PostPosted: Thu Apr 21, 2016 5:01 pm
by Darkeligos
So I've been looking around the source for a way to get the remote IP of a connected client with ESP8266WebServer, but found that it may only be possible with the WifiClient library. I noticed that the WebServer calls on WifiClient with:
Code: Select allserver.handleClient();


but I'm not sure that is helpful. Is there any way to get the remote IP with ESP8266WebServer?

Re: WebServer remoteIP()

PostPosted: Thu Apr 21, 2016 5:49 pm
by martinayotte
I'm not sure I understand your question...
If you don't do regular calls to server.handleClient() in the loop(), your ESP8266WebServer will simply not work !

Re: WebServer remoteIP()

PostPosted: Thu Apr 21, 2016 6:33 pm
by Darkeligos
martinayotte wrote:I'm not sure I understand your question...
If you don't do regular calls to server.handleClient() in the loop(), your ESP8266WebServer will simply not work !


Sorry for the confusion, I just need to find the IP of the clients that connect to my ESP8266WebServer. I'm using the HelloServer example.

Re: WebServer remoteIP()

PostPosted: Thu Apr 21, 2016 9:22 pm
by martinayotte
Code: Select allwebserver.client().remoteIP();

Still, your question or problem isn't clear if you didn't find the above by yourself... :ugeek: