This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
How to run lwip on 2 network interfaces?
- From: Bahadir Balban <bbbalb at essex dot ac dot uk>
- To: ecos-discuss at sources dot redhat dot com
- Date: Fri, 24 Jan 2003 21:38:16 +0000
- Subject: [ECOS] How to run lwip on 2 network interfaces?
Hi there,
I've got eCos ARM E7T template + LWIP + network drivers (IO_ETH_DRIVERS) +
KS32C5000 ethernet driver compiled into libtarget.a
1st Question: How to register a network interface as the networkif for TCP/IP.
2nd: Question:
I would like to run LWIP both on the serial port with SLIP and on the ethernet
interface. I know that LWIP can be SLIP enabled but perhaps this wouldn't be
enough as the serial device is not registered as the network device in eCos.
On my linux host, I can easily add my /dev/ttyS0 serial device as a network
interface and as well enable SLIP by typing:
% slattach -p slip -s 38400 /dev/ttyS0 &
% ifconfig sl0 192.68.1.221 pointopoint 192.68.1.222 netmask 255.255.255.0
and the routing table configured just as I wanted - sl0 and eth0 work together
safely:
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.68.1.0 * 255.255.255.0 U 0 0 0 sl0
155.245.112.0 * 255.255.240.0 U 0 0 0 eth0
127.0.0.0 * 255.0.0.0 U 0 0 0 lo
default safw0.essex.ac. 0.0.0.0 UG 0 0
I don't know the way to achieve the same thing on my ARM target with eCos,
Could you help me with this please? I have seen posts about 2 ethernet ports
being enabled simultaneously. How is this achieved? Do I need to write a
program with kernel calls?
Thank you very much,
Bahadir
--
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss