Ethernet MAC Address change on LPC1768

11 Jun 2018

Hello,

When ethernet connect make a NSAPI_ERROR_DHCP_FAILURE i do soft reset with void system_reset(void) (Mbed-os-5.8).

But with a soft reset the MAC Address on LPC1768 change.

Example :

Before soft reset, Ethernet MAC Address is . . . . : 00:02:f7:f2:04:a7

After soft reset, Ethernet MAC Address is . . . . : 00:02:f7:f0:00:00

i try on FRDM_K64F and no MAC Address change problem.

i try to get the MAC Address with eth.get_mac_address() and extern "C" void mbed_mac_address(char *s) and its the same.

Why MAC Address change and how fix this?

Thanks for your help!

11 Jun 2018

I temporary fix this bug with home made mbed_mac_address function to fix MAC Address.

MAC Address Fix

extern "C" void mbed_mac_address(char *mac)
{
    mac[0] = 0x00;
    mac[1] = 0x02;
    mac[2] = 0xf7;
    mac[3] = 0xf2;
    mac[4] = 0x04;
    mac[5] = 0xa7;
}

if you have an other idea...

Thanks for your help!

You need to log in to post a reply