The driver for the ESP8266 WiFi module
Fork of esp8266-driver by
Diff: ESP8266Interface.h
- Revision:
- 2:77a1e2188ed9
- Parent:
- 0:6946b0b9e323
--- a/ESP8266Interface.h Wed Jul 26 12:01:42 2017 +0000 +++ b/ESP8266Interface.h Thu Jul 27 03:25:51 2017 +0000 @@ -36,12 +36,17 @@ */ ESP8266Interface(PinName tx, PinName rx, bool debug = false); + + + int testWifi(); + /** Start the interface * * Attempts to connect to a WiFi network. Requires ssid and passphrase to be set. * If passphrase is invalid, NSAPI_ERROR_AUTH_ERROR is returned. * * @return 0 on success, negative error code on failure + */ virtual int connect(); @@ -254,11 +259,11 @@ { return this; } - + private: - ESP8266 _esp; bool _ids[ESP8266_SOCKET_COUNT]; + ESP8266 _esp; char ap_ssid[33]; /* 32 is what 802.11 defines as longest possible name; +1 for the \0 */ nsapi_security_t ap_sec; uint8_t ap_ch;