Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: ESP8266
Fork of ESP8266Interface by
Diff: ESP8266Interface.cpp
- Revision:
- 50:2d7f6b97234e
- Parent:
- 49:750ed1b67483
- Child:
- 51:eb8c3577e22d
diff -r 750ed1b67483 -r 2d7f6b97234e ESP8266Interface.cpp
--- a/ESP8266Interface.cpp Fri Feb 26 17:33:55 2016 +0000
+++ b/ESP8266Interface.cpp Mon Feb 29 23:05:00 2016 +0000
@@ -32,7 +32,7 @@
// ESP8266 specific methods
ESP8266Socket(
ESP8266 *esp,
- socket_protocol_t proto,
+ ns_protocol_t proto,
int id);
virtual ~ESP8266Socket();
@@ -48,7 +48,7 @@
private:
ESP8266 *_esp;
- socket_protocol_t _proto;
+ ns_protocol_t _proto;
int _id;
};
@@ -67,7 +67,7 @@
int32_t ESP8266Interface::connect(
const char *ap,
const char *pass_phrase,
- wifi_security_t)
+ ns_security_t)
{
_esp.setTimeout(ESP8266_CONNECT_TIMEOUT);
@@ -111,7 +111,7 @@
return _esp.getMACAddress();
}
-SocketInterface *ESP8266Interface::createSocket(socket_protocol_t proto)
+SocketInterface *ESP8266Interface::createSocket(ns_protocol_t proto)
{
// Look for an unused socket
int id = -1;
@@ -142,7 +142,7 @@
// ESP8266Socket implementation
ESP8266Socket::ESP8266Socket(
ESP8266 *esp,
- socket_protocol_t proto,
+ ns_protocol_t proto,
int id)
: _esp(esp)
, _proto(proto)
@@ -158,7 +158,7 @@
{
_esp->setTimeout(ESP8266_MISC_TIMEOUT);
- const char *proto = (_proto == SOCK_UDP) ? "UDP" : "TCP";
+ const char *proto = (_proto == NS_UDP) ? "UDP" : "TCP";
if (!_esp->open(proto, _id, ip, port)) {
return NS_ERROR_TIMEOUT;
