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: DnsQuery
Fork of NetworkSocketAPI by
Diff: WiFiInterface.h
- Revision:
- 16:6cfd38609828
- Parent:
- 6:0914f9b9b24b
diff -r 94e2cf3a06be -r 6cfd38609828 WiFiInterface.h
--- a/WiFiInterface.h Tue Apr 05 23:47:04 2016 +0000
+++ b/WiFiInterface.h Wed Apr 06 13:50:19 2016 +0000
@@ -19,33 +19,33 @@
#include "NetworkInterface.h"
+/** Enum for WiFi encryption types
+*/
+enum nsapi_security_t {
+ NSAPI_SECURITY_NONE = 0, /*!< open access point */
+ NSAPI_SECURITY_WEP, /*!< phrase conforms to WEP */
+ NSAPI_SECURITY_WPA, /*!< phrase conforms to WPA */
+ NSAPI_SECURITY_WPA2, /*!< phrase conforms to WPA2 */
+};
+
/** WiFiInterface class
* Common interface that is shared between WiFi devices
*/
class WiFiInterface : public NetworkInterface
{
public:
- /** Enum for WiFi encryption types
- */
- enum security_t {
- SECURITY_NONE = 0, /*!< open access point */
- SECURITY_WEP, /*!< phrase conforms to WEP */
- SECURITY_WPA, /*!< phrase conforms to WPA */
- SECURITY_WPA2, /*!< phrase conforms to WPA2 */
- };
-
/** Start the interface
/param ssid Name of the network to connect to
/param pass Security passphrase to connect to the network
/param security Type of encryption for connection
/return 0 on success, negative on failure
*/
- virtual int connect(const char *ssid, const char *pass, security_t security = SECURITY_NONE) = 0;
+ virtual int connect(const char *ssid, const char *pass, nsapi_security_t security = NSAPI_SECURITY_NONE) = 0;
/** Stop the interface
/return 0 on success, negative on failure
*/
- virtual int32_t disconnect() = 0;
+ virtual int disconnect() = 0;
};
#endif
