Technically, the MAC is only stored in netif->hwaddr and only used from
the ARP, DHCP and AutoIP modules (aside from maybe your netif driver and
SNMP). So you might get what you want by stopping both DHCP and AutoIP
and then just changing netif->hwaddr.
I did not test this though! Also, care must be taken the netif->hwaddr
is not accessed (e.g. by receiving packets) while you change it.
Simon
Alexandre Malo wrote:
Thanks,
it did work :) I was wondering about the MAC address, is there a
similar set of function we could use? Know if it's possible to change
it on run time?
Thanks!
Alex
>> Date: Sat, 25 Jul 2009 16:35:38 +0400
>> From: Mike Kleshov <m.kles...@gmail.com <mailto:m.kles...@gmail.com>>
>> Subject: Re: [lwip-users] Restarting lwip/ethernet
>> To: Mailing list for lwIP users <lwip-users@nongnu.org
<mailto:lwip-users@nongnu.org>>
>> Message-ID:
>> <44608ed00907250535t2dc59c55uda3460072b476...@mail.gmail.com
<mailto:44608ed00907250535t2dc59c55uda3460072b476...@mail.gmail.com>>
>> Content-Type: text/plain; charset=ISO-8859-1
>>
>> What I do is simply call netif_set_addr(), and that's it. And it
>> works. By the way, this function automatically enumerates TCP pcb's,
>> aborts open connections and rebinds listening pcb's.
>>
>> - mike
------------------------------------------------------------------------
_______________________________________________
lwip-users mailing list
lwip-users@nongnu.org
http://lists.nongnu.org/mailman/listinfo/lwip-users
_______________________________________________
lwip-users mailing list
lwip-users@nongnu.org
http://lists.nongnu.org/mailman/listinfo/lwip-users