1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-06-15 00:02:49 +03:00

Add function overload to config to include DNS

Disable DHCP if using static IP

With dhcp disabled, I noticed about 50% less conncection time
This commit is contained in:
chad cormier roussel
2015-06-03 15:29:25 -04:00
parent 3e04989902
commit 7daa6c6b69
2 changed files with 36 additions and 3 deletions

View File

@ -75,7 +75,6 @@ public:
*/
void softAP(const char* ssid, const char* passphrase, int channel = 1);
/* Change Ip configuration settings disabling the dhcp client
*
* param local_ip: Static ip configuration
@ -84,6 +83,15 @@ public:
*/
void config(IPAddress local_ip, IPAddress gateway, IPAddress subnet);
/* Change Ip configuration settings disabling the dhcp client
*
* param local_ip: Static ip configuration
* param gateway: Static gateway configuration
* param subnet: Static Subnet mask
* param dns: Defined DNS
*/
void config(IPAddress local_ip, IPAddress gateway, IPAddress subnet, IPAddress dns);
/* Configure access point
*
* param local_ip: access point IP
@ -310,7 +318,8 @@ protected:
bool _useApMode;
bool _useClientMode;
bool _useStaticIp;
static size_t _scanCount;
static void* _scanResult;