1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-04-19 23:22:16 +03:00

adds getautoreconnect() (#4359)

This commit is contained in:
Shawn A 2018-03-15 23:15:30 -05:00 committed by Develo
parent 30155f2ad3
commit 836c7da8cc
3 changed files with 10 additions and 0 deletions

View File

@ -356,6 +356,14 @@ bool ESP8266WiFiSTAClass::setAutoReconnect(bool autoReconnect) {
return wifi_station_set_reconnect_policy(autoReconnect);
}
/**
* get whether reconnect or not when the ESP8266 station is disconnected from AP.
* @return autoreconnect
*/
bool ESP8266WiFiSTAClass::getAutoReconnect() {
return wifi_station_get_reconnect_policy();
}
/**
* Wait for WiFi connection to reach a result
* returns the status reached or disconnect if STA is off

View File

@ -53,6 +53,7 @@ class ESP8266WiFiSTAClass {
bool getAutoConnect();
bool setAutoReconnect(bool autoReconnect);
bool getAutoReconnect();
uint8_t waitForConnectResult();

View File

@ -297,6 +297,7 @@ uint8 wifi_station_get_auto_connect(void);
bool wifi_station_set_auto_connect(uint8 set);
bool wifi_station_set_reconnect_policy(bool set);
bool wifi_station_get_reconnect_policy();
typedef enum {
STATION_IDLE = 0,