lwip-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lwip-users] Gateway problem with LwIP


From: sb80
Subject: Re: [lwip-users] Gateway problem with LwIP
Date: Fri, 21 Dec 2012 04:30:59 -0800 (PST)

have you an example code for me to realize this routing function?

should I define in the the opt.h something like this

original:
/**
 * LWIP_HOOK_IP4_ROUTE(dest):
 * - called from ip_route() (IPv4)
 * - dest: destination IPv4 address
 * Returns the destination netif or NULL if no destination netif is found.
In
 * that case, ip_route() continues as normal.
 */

/*
modificated:
#define LWIP_HOOK_IP4_ROUTE(dest) routingToNetif(ip_addr_t *dest)

and in ip.c

struct netif * routingToNetif(ip_addr_t *dest)
{
...
??what should the code make here? select the interface which have the rigth
gateway?
...
return netif;
}

Am I right? that if i include this function, the ARP, ping and others take
the right interface to find the gateway (MAC) and other destinitaions?

Is it enough that only this routing function is included in the old version
from me with out to upgrade the whole lwip code?

Can you advise a documentation where i can learn more about the functions
from the lwip stack? Because sometimes I don't understand the application
flow from the stack (because it's a new world for me :-) )

thanks
stefan




-----
Thanks
Stefan
(Germany)
--
View this message in context: 
http://lwip.100.n7.nabble.com/Gateway-problem-with-LwIP-tp20771p20825.html
Sent from the lwip-users mailing list archive at Nabble.com.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]