lwip-users
[Top][All Lists]
Advanced

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

Re: [lwip-users] Support of two Ethernet connections


From: Simon Goldschmidt
Subject: Re: [lwip-users] Support of two Ethernet connections
Date: Thu, 8 Mar 2018 15:30:53 +0100

address@hidden wrote:
> Now I need to understand how the LWIP is designed to be used in case
> of two (or more) Ethernet adapters. It is clear that I need to use
> two separated netif structure for each adapter. What I’m wandering
> now is how to connect to it the initialized udp_pcb and tcp_pcb (they
> are different for both interfaces). How I can connect the pcbs to the
> netif-structures?

That depends on the network configuration. In a standard setup, the
two netifs are connected to different subnets and by binding the pcb
to the netif's IP address, you talk to the correct subnet.

However, you can also bind to device (SO_BINDTODEVICE for socket API
or udp_bind_netif/tcp_bind_netif for callback API). But that needs
a git master version newer than 2.0.3.

Simon



reply via email to

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