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.
Dependents: HelloWizFi250Interface
Fork of NetworkSocketAPI by
Diff: NetworkInterface.h
- Branch:
- api-changes
- Revision:
- 42:49893d13c432
- Parent:
- 41:3ec1c97e9bbf
- Child:
- 43:09ea32f2eb54
diff -r 3ec1c97e9bbf -r 49893d13c432 NetworkInterface.h
--- a/NetworkInterface.h Tue Feb 23 04:01:38 2016 -0600
+++ b/NetworkInterface.h Tue Feb 23 05:07:02 2016 -0600
@@ -17,10 +17,14 @@
#ifndef NETWORK_INTERFACE_H
#define NETWORK_INTERFACE_H
+#include "SocketInterface.h"
#include "stdint.h"
-#include "SocketInterface.h"
+
-#define SOCK_IP_SIZE 16
+/** Maximum storage needed for IP address and MAC addresses
+ */
+#define NS_IP_SIZE 16
+#define NS_MAC_SIZE 18
/** NetworkInterface class
@@ -85,7 +89,7 @@
/** Get the current status of the interface
* @return true if connected
*/
- virtual bool isConnected(void);
+ virtual bool isConnected();
/** Looks up the specified host's IP address
* @param name URL of host
@@ -112,9 +116,9 @@
virtual void destroySocket(SocketInterface *socket) = 0;
private:
- char _ip_address[SOCK_IP_SIZE];
- char _network_mask[SOCK_IP_SIZE];
- char _gateway[SOCK_IP_SIZE];
+ char _ip_address[NS_IP_SIZE];
+ char _network_mask[NS_IP_SIZE];
+ char _gateway[NS_IP_SIZE];
uint32_t _timeout;
};
