在上一篇的blog中,我已经把android成功移植到英码公司的ema3530上了,但是还有些功能需要完善,今天解决android上不了网的问题。
1.确定您的内核主线部分的网络驱动没问题(我是用ema配的内核,并在angtrom上做了测试,所以肯定没问题)
2.重新制作文件系统,修改文件系统的init.rc文件
加入
# basic network init
setprop net.dns1 你dns的ip地址
3.把ema3530和主机相连
4.把sdk工具包下的adb调试工具加入环境变量PATH中
5.在终端下输入adb shell ,如:
[root@bogon tools]# adb shell
#
6.设置自动获取ip
#
# netcfg eth0 up
# netcfg eth0 dhcp
#
7.测试网络
# ifconfig eth0
eth0: ip 192.168.1.162 mask 255.255.255.0 flags [up broadcast running multicast]
#
#
# ping www.ema-tech.com
PING www.ema-tech.com (218.240.39.146) 56(84) bytes of data.
64 bytes from 218.240.39.146: icmp_seq=1 ttl=53 time=393 ms
64 bytes from 218.240.39.146: icmp_seq=2 ttl=53 time=228 ms
呵呵,有些慢,但是OK了