[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lwip-users] IPV6 Porting
From: |
ffddybz |
Subject: |
Re: [lwip-users] IPV6 Porting |
Date: |
Sun, 27 Jul 2014 16:35:03 +0800 |
Thank you for your reply. I succeed in testing IPV6 via ND6 protocol. But I also want to test it using static IPV6 address, the process of doing this, I created linklocal address, then I use IP6_ADDR macro to add address to struct ip6addr, I use function netif_get_ip6_addr_match to bind struct netif and struct ip6_addr, Then you tell me using macro netif_ip6_addr_set_state. But I can't create IPV6 address, and struct netif did not contain any information about IPV6 address. Am I doing right?
------------------ Original ------------------
Date: Tuesday, Jul 22, 2014 2:20 AM
Subject: Re: [lwip-users] IPV6 Porting
This used to be in one of the LwIP Wikia pages but now it is gone ...
??
The netif has some placeholders for IPv6 addresses:
my_netif->ip6_addr[xx]. The number of addresses is configurable in
lwipopts.h, usually 3 is a good number.
Usually address [0] is reserved for the link-local address. If your
netif has a hw_addr configured you can use
netif_create_ip6_linklocal_address() to create the address. You can
manually create the rest of the adresses, or if you have adress
auto-configuration enabled you can let the ND6 protocol generate the
rest of the adresses with help from your IPv6 router. you should set
netif->ip6_autoconfig_enabled = 1; and make sure it is enabled in
lwipopts.h
Any address you manually configure, you should use the macro
netif_ip6_addr_set_state(netif, addr_index, IP6_ADDR_TENTATIVE) to let
ND6 protocol validate it.
That is all you need to get set up.
If you have any other questions just ask.
Cheers
Ivan
> Date: Sun, 20 Jul 2014 15:22:12 +0800
> From: "=?ISO-8859-1?B?ZmZkZHlieg==?=" <address@hidden.com>
> To: "=?ISO-8859-1?B?bHdpcC11c2Vycw==?=" <address@hiddenongnu.org>
> Subject: [lwip-users] IPV6 Porting
> Message-ID: <tencent_0ABEC6691C9F8641address@hiddencom>
> Content-Type: text/plain; charset="iso-8859-1"
>
> Hi,everyone. I try to port lwip-master to RT-Thread Operating
> System(An embedded Real-Time open source system form china).I succeed
> in running IPV4 application, but the main purpose for me is porting
> IPV6 to it.
> The wiki said that when you using ipv6 you can add macro LWIP_IPV6 in
> lwipopts.h
> But I don't know how to call some functions to set static IPV6
> address. Is there any documents talking about it?
_______________________________________________
lwip-users mailing list
address@hiddenongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users