Networking on Android

I have a Rev C BeagleBoard, and we finally figured out how to get the
keyboard working (refer to other posting).

The new challenge is getting the network up.

So from the Android Porting Guide:

It says to execute the following commands through serial:

$netcfg eth0 up
$netcfg eth0 dhcp

Problem is, eth0 does not exist.

It also says:
NOTE:- Enable appropriate driver for your "ethernet to usb converter"
in kernel. Driver can be found at :-
│ -> DeviceDrivers │ │ -> Network device support (NETDEVICES[=y]) │ │ -

USB Network Adapters

Where or how do you do this? I have no idea where it's referring to...

If anyone has any pointers, that would be much appreciated.


I am having the same problem. Has anyone solved it? I do not have
eth0 configured. I tried configuring it with 'ifconfig eth0 dhcp',
which does not work. How can the physical interface on the beagleboard
be found out? Does a bridge have to be created between usb and eth0? I
had the ethernet to USB converter connected to a USB hub at first. I
tried connecting it directly to the beagleboard which crashed the
system on the SD-card. I am using the pre-built binaries available on website. I did not compile the code myself. Can that be a


Try "netcfg eth0 dhcp" and then "setprop net.dns1 <your.dns.ip>'



   Thanks for the quick reply. netcfg also doesn't seem to work. I am
getting the following error.
# netcfg eth0
action 'dhcp' failed (No such device)

I ran /system/bin/logcat. It shows -

D/DHCP ( 928): failed to set ip addr for eth0 to No such

I am guessing that the driver itself is not present in the kernel and
I will have to download it. Am I right?


Yes, I think you need to compile it yourself so that the driver for
the USB to Ethernet device is included in the kernel.

So try to follow the steps here:

But in the "Compile Kernel" sections, instead of following step #2,
instead do the following:

cd beagledroid/kernel
make menuconfig

Navigate to: Device Drivers -> Network Device Support -> USB Network
Adapters -> Multi-purpose USB Networking Framework -> ASIX AX88xxx
Based USB 2.0 Ethernet Adapters

Make sure you mark it with * to have it built into the kernel, instead
of "m" to have it built as a module.

After you have the new kernel, after booting up with it, do the

netcfg eth0 up
netcfg eth0 dhcp
setprop net.dns1 <dns server IP>

You will have to include the appropriate adapter driver in your
kernel, like Stan mentioned in a message yesterday.



Did you ever resolve this? I have built the kernel with the driver for
my device, and it seems to recognize it just fine. I am using a USB to
Ethernet adaptor, and I can see both during boot and by unplugging and
plugging the device back in to the HUB (I am operating in OTG mode
with a DC powered hub connected to the board and the Ethernet adapter
plugged in to the hub) that Android sees the device, and picks up the
proper vendor ID etc. The device gets link, and I can put debugging in
the driver that seems to indicate it is included in the build (and not
as a module).

I changed my config to include some of these settings:


Despite that, I still get "No such device" when I try and execute
netcfg on eth0. Any advice? Would you mind posting your config so that
I could compare my settings?

Yes, I did manage to get the USB Ethernet adapter working.

How are you building the kernel? Are you running the the Embinux script or are you running "make uImage" after
doing the "make menuconfig"? You need to do "make uImage" to ensure
the build is using the configuration from "make menuconfig", because uses a predefined config file.

Other than that, I can't think of what else may be preventing it from
working for you...

I tried first just doing a "make menuconfig" then "make uImage", then
I thought maybe there is something I was missing that is in .../arch/
arm/configs/omap3_beagle_defconfig, so I edited this config manually
then used the script. The results were
identical. I get link, but I can not bring up the interface.

What do you mean exactly when you say you get link?

At the beginning when I had problems, even without configuring the
kernel to have the drivers built in, it still already did recognize
the type of device that was connected.

The difference with after adding the driver to the kernel was that
after it recognized the device, a line followed that enumerated it as

So even without the driver, the kernel seems to be able to detect what
device it is, but it was only after adding the driver that it was able
to use it properly.

Are you using this device or another?

The Linux kernel can enumerate USB devices, and will display certain
information about the device based on the device descriptors. Some of
these descriptors contain strings that are printed. This allows the
kernel to know what USB devices are present, but unless the
appropriate device driver is compiled into the kernel or loaded as a
module, the kernel will not know how to use the device.


Hi All,

While building u-boot, Code sorcery is throwing following error .

["make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- omap3530_beagle_per_uart_defconfig" is executed successfully]
shankar @ Pothigai 08:04 AM ~/Beagle/u-boot-v2 $ make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi-

scripts/kconfig/conf -s arch/arm/Kconfig
  SYMLINK include/asm-arm/arch -> include/asm-arm/arch-omap
  SYMLINK include/asm-arm/proc -> include/asm-arm/proc-armv
  CHK include/linux/version.h
  UPD include/linux/version.h
  CHK include/linux/utsrelease.h
  UPD include/linux/utsrelease.h
  SYMLINK include/asm -> include/asm-arm
  SYMLINK include/config.h -> board/omap/config.h
  CC scripts/mod/empty.o
scripts/mod/empty.c:1: error: bad value (armv7a) for -march= switch
make[2]: *** [scripts/mod/empty.o] Error 1
make[1]: *** [scripts/mod] Error 2
make: *** [scripts] Error 2

Could you please help me out to resolve this issue ?

I think the -march flag what you have passed should be armv7-a.

By link I meant Ethernet link - link light on the device and switch it
was connected to. I was thrown by the fact that the kernel appeared to
be recognising the device, and that the link light illuminated
apparently at about that time in the boot cycle (as opposed to when
power was applied). So I was thinking that the chipset in the adapter
was being initialized properly and the driver, which I put some
debugging in, was functioning properly.

But Howard and Stan, as you pointed out, that thinking was based on
false assumptions, so your help there was much appreciated. Given
that, I instrumented the driver code further, and looked more
carefully at the device IDs, and found that the chipset identified by
the datasheet I had for my adapter was incorrect. The place I bought
the StarTech adaptor from said it used the AX88xxx chipset, but
another posted reported it was actually the RTL8150, but in reality,
it is the MosChip MCS7830. So to be clear to anyone else searching: I
used the StarTech USB2106S with the MosChip MCS7830 driver and it
works perfectly. When I plug it in, I see:

usb 1-1.5: new high speed USB device using musb_hdrc and address
usb 1-1.5: device v9710 p7830 is not
usb 1-1.5: New USB device found, idVendor=9710,
usb 1-1.5: New USB device strings: Mfr=1, Product=2,
usb 1-1.5: Product: USB-MAC
usb 1-1.5: Manufacturer: Moschip
usb 1-1.5: SerialNumber:
usb 1-1.5: configuration #1 chosen from 1
usb 1-1.5: applying rev.C
usb 1-1.5: applying rev.C
eth0 (MOSCHIP usb-ethernet driver): not using net_device_ops
eth0: register 'MOSCHIP usb-ethernet driver' at usb-musb_hdrc-1.5,

And now I can easily configure eth0.

Thank you, gentlemen!

JUst restart your pc and try again with a fresh build