Share PC Internet Connection with Android Phone via USB Cable

People often have some questions like, “How to do Android 2.2 USB Reverse Tethering” or “How to Share the PC Internet Connection with android phone via the USB cable” etc.

Well, I have up-graded my Nexus-1 to Android version 2.2 recently.

Android version 2.2 includes USB Tethering by which a Computer System can share the Internet connection of the phone.

This is great for those who just want to access internet via their mobile phone, but what, if you want to use your Computer’s Internet Connection onto your Mobile Phone?

This is really ridiculous, as the phone accesses internet for lot of events, and there is no option of using internet from the Computer by default.

So what to do, if you have an unlimited and high speed internet broadband connection at home but you won’t be able to use it on your android phone. Ultimately you will have to spend a few extra dollars to get a separate mobile internet connection.

But here is a way to access the Computer’s internet connection from your android mobile phone.

I think it will take a little time to me, to create an app to do this automatically!

Well, till then you can follow the below method, for which the Requirements are:

  • A rooted version 2.2 Android, with root mode terminal or an Android SDK ADB
  • and, an Android 2.2 (or an older version with enabled/installed root tethering application in it)

Now follow the below steps,

1:

For Linux Users: Nothing to do in this step,
For Windows Users: Install the USB drivers by the Android SDK

2:

Onto the Nexus-1: Start USB Tethering after connecting the USB wire with your Computer. You will probably get the latest interface of the network.

3:

Now, setting-up a bridge on Linux Operating System:

# usb0 is the latest network intreface
# eth0 is the main interface (or a gateway) connected to internet
sudo ifconfig eth0 0.0.0.0
sudo ifconfig usb0 0.0.0.0
sudo brctl addbr br0
sudo brctl addif br0 eth0
sudo brctl addif br0 usb0
sudo ifconfig br0 up
sudo dhclient br0

Visit here for setting-up the bridges

And, if you are on windows you will need to Bridge two interfaces of network.

4:

Now setup your phone’s usb0 interface. You have 2 choices:

1. Either execute the following command,

./adb shell netcfg usb0 dhcp

2. Otherwise, type this in your phone’s root terminal :

su
netcfg usb0 dhcp

Now you can connect and access the Computer’s Internet broadband connection on your mobile phone.

Confirm it by opening www.tipsring.com

5:

To stop the usb reverse tethering, first-of-all, unbridge the your computer’s interfaces,

sudo ifconfig eth0 down
sudo ifconfig usb0 down
sudo ifconfig br0 down
sudo brctl delbr br0
sudo ifconfig eth0 up
sudo dhclient eth0

Then unselect the USB-Tethering onto your phone.

You must have Windows XP SP3, as the driver will not work on Windows XP – Service Pack-2 (You will get this error while installing, Code-10 – Cannot Start Driver).

Enjoy!

2 thoughts on “Share PC Internet Connection with Android Phone via USB Cable

  1. Ankit

    Wooooohh…!!!
    Its too techy bro. I’ll wait until you create an application.

    By what date we should expect it to release in android market?

    Regards
    Ankit

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>