W5500 driver for mbed OS 5

Dependents:   http-webserver-example mbed-os-example-sockets

Fork of W5500Interface by Sergei G

Revision:
6:e2ab76b2be07
Parent:
4:80e302a610fd
Child:
8:c71c66d43703
--- a/WIZnet/W5500.h	Thu Jul 06 05:46:17 2017 +0000
+++ b/WIZnet/W5500.h	Thu Aug 09 08:10:27 2018 +0000
@@ -1,3 +1,4 @@
+// modified 08/08/2018 by Bongjun Hur
 
 #pragma once
 
@@ -125,6 +126,13 @@
     bool setProtocol(int socket, Protocol p);
 
     /*
+    * Set local port number
+    *
+    * @return true if connected, false otherwise
+    */ 
+	bool setLocalPort(int socket, uint16_t port);
+
+    /*
     * Reset the W5500
     */
     void reset();
@@ -249,7 +257,6 @@
         reg_wr_ip(addr, (0x0C + (socket << 5)), ip);
     }
 
-protected:
     uint8_t mac[6];
     uint32_t ip;
     uint32_t netmask;
@@ -257,6 +264,7 @@
     uint32_t dnsaddr;
     bool dhcp;
 
+protected:
     static WIZnet_Chip* inst;
 
     void reg_wr_mac(uint16_t addr, uint8_t* data) {