summaryrefslogtreecommitdiffstatshomepage
path: root/drivers/wiznet5k
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2014-09-01 22:48:57 +0100
committerDamien George <damien.p.george@gmail.com>2014-09-01 22:52:38 +0100
commitbcf041f1a33d20a12b1cfbfe434c0b2c69f0e5b3 (patch)
treead8f12681af5dae7dd3f2a1f41b09a9c9435a688 /drivers/wiznet5k
parentcdd40f149a5c5a628bc1cf2181d6d16382e66757 (diff)
downloadmicropython-bcf041f1a33d20a12b1cfbfe434c0b2c69f0e5b3.tar.gz
micropython-bcf041f1a33d20a12b1cfbfe434c0b2c69f0e5b3.zip
stmhal: Add wiznet5k module, to control WIZnet ethernet adaptor.
Allows to create socket objects that support TCP and UDP in server and client mode. Interface is very close to standard Python socket class, except bind and accept do not work the same (due to hardware not supporting them in the usual way). Not compiled by default. To compile this module, use: make MICROPY_PY_WIZNET5K=1
Diffstat (limited to 'drivers/wiznet5k')
-rw-r--r--drivers/wiznet5k/ethernet/wizchip_conf.c6
-rw-r--r--drivers/wiznet5k/internet/dns/dns.c2
2 files changed, 7 insertions, 1 deletions
diff --git a/drivers/wiznet5k/ethernet/wizchip_conf.c b/drivers/wiznet5k/ethernet/wizchip_conf.c
index 87b5427f26..110e284bbc 100644
--- a/drivers/wiznet5k/ethernet/wizchip_conf.c
+++ b/drivers/wiznet5k/ethernet/wizchip_conf.c
@@ -606,6 +606,12 @@ void wizchip_getnetinfo(wiz_NetInfo* pnetinfo)
getGAR(pnetinfo->gw);
getSUBR(pnetinfo->sn);
getSIPR(pnetinfo->ip);
+#if _WIZCHIP_ == 5200 // for W5200 ARP errata
+ pnetinfo->sn[0] = _SUBN_[0];
+ pnetinfo->sn[1] = _SUBN_[1];
+ pnetinfo->sn[2] = _SUBN_[2];
+ pnetinfo->sn[3] = _SUBN_[3];
+#endif
pnetinfo->dns[0]= _DNS_[0];
pnetinfo->dns[1]= _DNS_[1];
pnetinfo->dns[2]= _DNS_[2];
diff --git a/drivers/wiznet5k/internet/dns/dns.c b/drivers/wiznet5k/internet/dns/dns.c
index 8308ee9ad2..48f486e0ba 100644
--- a/drivers/wiznet5k/internet/dns/dns.c
+++ b/drivers/wiznet5k/internet/dns/dns.c
@@ -54,7 +54,7 @@
//#include "Ethernet/socket.h"
//#include "Internet/DNS/dns.h"
-#include "../../Ethernet/socket.h"
+#include "../../ethernet/socket.h"
#include "dns.h"
#ifdef _DNS_DEBUG_