diff --git a/libraries/Ethernet/src/Ethernet.cpp b/libraries/Ethernet/src/Ethernet.cpp index 4d8205058..3151cdcc4 100644 --- a/libraries/Ethernet/src/Ethernet.cpp +++ b/libraries/Ethernet/src/Ethernet.cpp @@ -174,6 +174,10 @@ uint8_t *CEthernet::MACAddress(void) { return mac_address; } +void CEthernet::MACAddress(uint8_t *mac) { + CLwipIf::getInstance().getMacAddress(NI_ETHERNET, mac); +} + IPAddress CEthernet::localIP() { if(ni != nullptr) { return IPAddress(ni->getIpAdd()); diff --git a/libraries/Ethernet/src/EthernetC33.h b/libraries/Ethernet/src/EthernetC33.h index 109a19775..23f8202d1 100644 --- a/libraries/Ethernet/src/EthernetC33.h +++ b/libraries/Ethernet/src/EthernetC33.h @@ -62,6 +62,7 @@ class CEthernet { uint8_t *MACAddress(void); + void MACAddress(uint8_t *mac); IPAddress localIP(); IPAddress subnetMask(); IPAddress gatewayIP();