Ping host using uclinux_rtl8019 in testsuite 2.0 for skyeye1.0 on gentoo-2.6.12-R6
After installing gentoo,skyeye1.0 and testsuite2.0 on the host, the uclinux_rtl8019 folder can be found in the at91 folder. There are all files including Linux, romfs.img and skyeye.conf which have been compiled and configed for skyeye1.0. Moreover, TUN device driver support should be available for ping host. The ?lsmod? command can check it. If not, the following is the steps on the host to install it:
1
# cd /usr/src/linux
# make menuconfig
Device Drivers ?> Networking support ?> [M] Universal TUN/TAP device driver support
Notice: use ?M? to compile the module, do not use ?*? to compile the kenel again.
2
After that, you can find tun.ko in /usr/src/linux/drivers/net, which has been compiled.
3
# cp /usr/src/linux/drivers/net/tun.ko /lib/modules/gentoo-2.6.12-R6/kernel/drivers/net
4
Rebuilt the dependency between modules
5 Load TUN
# modprobe tun
# lsmod |grep tun
The lsmod command verifies that tun is indeed loaded.
If you want to load TUN module automatically, just only add a line ?tun? in the file /etc/modules.autoload on the host.
OK! TUN module is available now. Let's run skyeye and uclinux on the host:
# cd /usr/scr/testsuite/2.0/at91/uclinux_rtl8019
# skyeye -e uclinux
Use -e because the kernel file is ELF format.
If everything is fine, uclinux will start on the skyeye and a command line prompt can be seen, like this:
Welcome to
____ _ _
/ __| ||_|
_ _| | | | _ ____ _ _ _ _
| | | | | | || | _ \| | | |\ \/ /
| |_| | |__| || | | | | |_| |/ \
| ___\____|_||_|_| |_|\____|\_/\_/
| |
|_|
GDB/ARMulator support by <davidm@snapgear.com>
For further information check:
http://www.uclinux.org/
Command: /bin/ifconfig eth0 up 10.0.0.2
Execution Finished, Exiting
Sash command shell (version 1.1.1)
/>
It shows that on the ucLinux side, the IP address is configured automatically by the ucLinux start up script to be 10.0.0.2. Also, at this point, a network device called 'tap0' is started on the host. tap0 is used to by the host to communicate with ucLinux. You need to manually configure the IP address of tap0 on the host. Note that you need to do this every time after you restart skyeye.
# /sbin/ifconfig tap0 10.0.0.1
Now it is time to type the 'ping' command on uclinux:
or, on the host, you can ping ucLinux by
# /sbin/ifconfig tap0 10.0.0.2
There are still some overtime transmitting packages which will be counted as lost packages.
More information about TUN can be found
here∞