I finally connected my Touch Pro2 to my netbook running Kubuntu 9.10 via Bluetooth for Internet access and thought I would share. (for the two other guys running a Windows phone with a Linux machine, right?) There is a lot of stuff on the net, tried half of it, and eventually just figured it out on my own. Maybe I am just crap with Google. I don't see any reason why this wouldn't work with any other phone with the same Bluetooth stack as the TP2. (HD, etc?)
LAPTOP
Get KBluetooth running if it's not already (bluetooth tray icon)
Right click KBluetooth for the menu, you want Settings -> Bluetooth Adapters
Set the mode to discoverable. If you want to change the name, do so, but then exit and restart KBluetooth. (otherwise the settings don't seem to take effect)
PHONE
Turn Bluetooth on if it's not already, then go into the Bluetooth menus via Comm Manager.
Tap "Add a device" and add the laptop. Enter a PIN.
LAPTOP
Enter the PIN when the box pops up.
Set the discovery mode back to hidden.
Now go into the KBluetooth device manager and set the phone to trusted. (this probably isn't necessary but I did it)
(this part onwards you need to do every time you connect)
PHONE
Go to the 2nd tab in the Bluetooth menus (the list of devices) and tap the laptop. You should now see Bluetooth Networking. Give this a tap.
After a few seconds you will get a drop down box. Set this to "Share Internet connection" then press Continue at the bottom left.
Now you select the GPRS connection you want to use. Again press Continue when done.
You should get a yellow notification at the bottom of the screen saying connecting, then after a few seconds a screen with the laptop's name and MAC address.
LAPTOP
Now open a Konsole and run this command:
Code:
sudo dhclient bnep0
If it worked you will see something like this at the end:
Code:
bound to 192.168.0.102 -- renewal in 120808 seconds.
You should now be connected to the Internet
you can also use wi-fi router to connect.
Code:
iwconfig wlan0 mode ad-hoc essid wificonnection key 1234567890
ifconfig wlan0 up
dhcpcd wlan0
wlan0 is your computers wifi interface your might be different
mode ad-hoc turns the connection into ad-hoc mode
essid wificonnection - is the network name in this example wificonnection
key is whatever 10 digit wep key you assign the connection 1234567890 in this example
*the dhcpcd wlan0 line in the scrip assumes you are using dhcpcd change it to dhclient if you are using dhclient instead.
the above script should work with most distros of linux. make sure wifi-router is running before you run the script on your computer.
to connect using usb tethering you can use
Code:
modprobe cdc_ether
modprobe rndis_host
ifconfig eth1 up
dhcpcd eth1
make sure rndis_host cdc_ether and all required packages and dependencies are installed. i had it set up a long time ago dont remember the the exact packages needed to make this work. again your network interface might differ (eth1,eth2,ethX) and dhclient if your using dhclient instead of dhcpcd.
These are the two scripts i use to tether to my netbook running Arch Linux and Gentoo but should work for most linux distros.
Related
Hi all,
I used to use my Diamond connected via USB and the 'Internet Sharing' function to provide Internet access to my laptop running Vista without any problems whatsoever...
However I have recently upgraded to Vista and don't seem to be getting anywhere... or rather getting somewhere but not far enough!
Specifically, I can connect the Diamond to the laptop via USB and run 'Internet Sharing' on the device. Having hit Connect and connected to the Internet (confirmed my running a browser on the Diamond) the laptop detects a 'Remote NDIS Internet Sharing Device' in the Device Manager. It then adds a connection in Network Connections but seemingly-fails to get any further. It looks like the DHCP requests are falling on deaf ears and without an IP address it's not going to get far beyond that...
Anyone with any ideas? Or, at the very least, could someone confirm that they have got Internet Sharing working with Windows 7, even if they didn't necessarilly have to do anything special?
Regards,
Mathew
Typical... you think you've tried everything, you've exhausted Google and posted a forum post as a last resort plea for help.... Five minutes later you sort it! Mustn't moan I suppose... and in case anyone else hits this problem here's how to sort it:
The problem was calling out to me really - DHCP. I had Layer 2 connectivity but without establishing anything at Layer 3 it simply wasn't going to work so if statically asign the IP address then I could at least rule DHCP out of the equation to see what additional hurdle, if any, had to be then tackled.
The problem was that without knowing the address at the other end (i.e. the Diamond) then I wouldn't know what subnet to put my laptop in. However, this all worked fine on Vista so I fired it up and ran Wireshark (network packet sniffer) and could see that the laptop was being given an IP address from the 192.168.0.0/24 subnet and that the other end (whether that be the Diamond or some virtual device that at least representa it) was sat on 192.168.0.1. Strangely, the other end had a MAC address of 82:00:60:0F:E8:00 and the laptop 80:00:60:0F:E8:00 - whilst they're not globally assigned this must be what Microsoft use on the local link for these types of connections.
So, back to Windows 7, I fired up Internet Sharing and connected to my ISP. I now had a LAN connection listed on the laptop under Network Connections so I forced a static address assignment by right-clicking it and selecting Properties > Internet Protocol Version 4 (TCP/IP) > Properties and assigning the following:
IP Address: 192.168.0.80 (choose anything within 192.168.0.2-254 but stay away from anything you might already have assigned to other connection e.g. wireless/wired Ethernet etc)
Subnet Mask: 255.255.255.0
Default Gateway: 192.168.0.1
DNS Server: 192.168.0.1
Hit OK and then, being the Microsoft way, you will likely need to bruteforce the new application of the new setting by disconnecting and reconnecting the Internet Sharing connection. The LAN connection on the laptop will disappear and reappear, hopefully with a static address assigned (right-click it and select Status - DHCP should be disabled).
I still don't know why DHCP was failing but regardless I've got what I wanted - shared access to the Internet!
Cheers,
Mathew
Nice one, thanks for sharing.
My Galaxy S has been connecting fine to my home network lately and the connection has always been strong as well. Since late last night though it won't connect. It says connecting > obtaining i.p > connected > disconnected and continuously repeats this cycle. My mates Samsung Europa can connect and so can my p.c and laptop, so it is obviously an issue with my phone. I downloaded WeFi and that has the same problem. Does anyone have any ideas?
Sorry my English, flash a kernel
Which kernal and why?
I had this EXACT problem just earlier when I upgraded to 2.2.
My phone always used to connect fine until the upgrade, and afterwards i got the same error.
Anyway what you need to do is to find all your router settings (you need a computer for this);
click start > run > cmd
in the command prompt type ipconfig and gather the following data:
ip adress: (your ip will be the same as your router's ip apart from the last set of digits (just make sure to make it a digit not already being used otherwise it will clash). 5-10 is a good option.)
gateway: (same as found in cmd)
net/subnet mask: (same as found in cmd)
Depending on your router you may also need a primary and secondary DNS: (generally the router ip)
With the following information gathered, on your phone click aps> settings> wireless and network> wifi settings> and then hold the left soft key to reveal the advanced tab. In the advanced tab click static ip and enter all the information about your router you gathered earlier.
After entering the router settings click and hold the left key again and press save.
Hopefully afterwards your phone will connect automatically as mine did, or just click your router SSID agian and it should connect.
I had the same issue after I upgraded to froyo. The way I fixed was actually just unplugging the router, unplug the modem, wait 10 seconds.... reset everything.
Ever since then 0 problems.
Thanks Johno.
johno1994 said:
I had this EXACT problem just earlier when I upgraded to 2.2.
My phone always used to connect fine until the upgrade, and afterwards i got the same error.
Anyway what you need to do is to find all your router settings (you need a computer for this);
click start > run > cmd
in the command prompt type ipconfig and gather the following data:
ip adress: (your ip will be the same as your router's ip apart from the last set of digits (just make sure to make it a digit not already being used otherwise it will clash). 5-10 is a good option.)
gateway: (same as found in cmd)
net/subnet mask: (same as found in cmd)
Depending on your router you may also need a primary and secondary DNS: (generally the router ip)
With the following information gathered, on your phone click aps> settings> wireless and network> wifi settings> and then hold the left soft key to reveal the advanced tab. In the advanced tab click static ip and enter all the information about your router you gathered earlier.
After entering the router settings click and hold the left key again and press save.
Hopefully afterwards your phone will connect automatically as mine did, or just click your router SSID agian and it should connect.
Click to expand...
Click to collapse
Amazing mate, i really f.ing appreciate it. I've flashed so many roms, so many wifi drivers, deleted dhcp_list so many times, created so many tasker profiles and tried so many apps just to stop wifi error and disconnecting and mate, your method has fixed it!
If we were in prison together, id protect you in the showers!
boarder.2k9 said:
If we were in prison together, id protect you in the showers!
Click to expand...
Click to collapse
lolz... proper fix -> http://forum.xda-developers.com/showpost.php?p=13235272&postcount=19
Attached is a somewhat-crude shell script that enables wired USB networking ("reverse tethering") on the Epic. Sadly it's not a standalone app, and it doesn't have perfect application compatiblity either. However, some folks may find it useful in order to get Internet where neither cellular nor WiFi service is available.
Requirements:
Rooted Epic with busybox (one-click root satisfies this).
Host PC with Internet sharing capabilities.
ConnectBot or another terminal emulator.
The attached "usbnet.sh" script.
Initial setup:
First, setup the host PC for Internet sharing on the USB network interface:
On Windows, you'll need to install the Samsung USB drivers (if you already did for the one-click root or Wired Tether, you should be OK). The remaining part of the ICS setup on Windows has to be done the first time the script is ran on the phone, so it's covered below.
On Linux, you'll need to setup netfilter (for NAT), install & configure dnsmasq or another DHCP server, and enable IP forwarding. Details on those are outside the scope of this thread, but it's essentially the same as setting up network sharing for an Ethernet connection.
On the phone, install ConnectBot or an alternate terminal emulator. Unfortunately USB ADB and RNDIS can't be used simultaneously, so the script can't be run via "adb shell".
Next, copy usbnet.sh to the phone. It can go anywhere, although it can't be run from /sdcard directly. Good places are /data/local or /data/local/tmp. For example:
Code:
adb push usbnet.sh /data/local
adb shell chmod 755 /data/local/usbnet.sh
If you're using ConnectBot (recommended), create a "host" for the usbnet script. Enter "usbnet" in the bottom-of-the-screen input box, select "local" from the drop-down menu to the left, and press enter. At the "$" prompt, enter "exit", and close the session. Now "usbnet" will appear in the host list, long-press it, and select "Edit host". Select "Post-login automation" and enter:
Code:
exec su -c /data/local/usbnet.sh
substituting the appropriate path for "/data/local/usbnet.sh". Also, make sure to press Return to create a newline, otherwise the script won't execute automatically. Alternatively, if you're not using ConnectBot, you can run the script manually after su-ing to root.
Directions for use:
Before using, make sure "USB debugging" is disabled on the phone (unless you're running a patched custom kernel). Also make sure the USB cable is disconnected.
Next, disable WiFi, 4G, and the cellular data connection (long-press power and select either "Data network mode", which lets you still receive calls and SMSes, or "Airplane mode", which doesn't) as these interfere with the wired connection.
Open ConnectBot, and select the "usbnet" entry. Press "Allow" at the su prompt if it comes up. Now, connect the USB cable to the host PC, and select "Charging" from the "Select USB mode" menu.
If the host PC is running Windows, and this is the first time using the wired connection, you'll have to finish the inital setup. On Windows 7, go to Control Panel -> Network and Internet -> Network and Sharing Center -> Change adapter settings. Once the USB cable is plugged in a new "Local Area Connection" should appear (e.g, "Local Area Connection 3") for the phone. You can unplug and replug the USB cable to verify which is the phone's connection, it will disappear and reappear.
Now, right-click the other network adapter that's providing the Internet connection for the host PC. It's likely "Local Area Connection" for Ethernet, and "Wireless Network Connection" if wireless. Select Properties, and click on the Sharing tab. Check "Allow other network users to connect through this computer's Internet connection", and if it asks to select a "Home networking connection" (which it should if you have three or more adapters, including the phone, in total), select the phone's adapter (e.g., "Local Area Connection 3"). Then click OK.
Note that, on Windows, to setup sharing the phone's network adapter must be present, which is why it must be done after first running the usbnet script. The sharing setting does persist across disconnects, so the previous setup only needs to be done once unless sharing is manually disabled.
No additional setup should be required if the host PC is running Linux, although you may have to manually assign an IP address to the USB network interface (host side) and manually start dnsmasq/dhpd depending on your configuration.
At this point, the phone should report "netcfg usb0 dhcp ... wait ..." while it attempts to acquire an IP address from the host PC. On Windows, this may take a minute or longer. If for some reason it's unable to get an IP address (may happen during first time setup on Windows) it will report "action 'dhcp' failed (Timer expired)". If it does, unplug the USB cable, select the "usbnet" entry again, and replug the USB cable.
Once the phone acquires an IP address, the usbnet script will print out a table of network adapters and IP addresses (one of which includes the address for usb0) and exit. The connection should be working now.
To disconnect, run "usbnet" from ConnectBot again, which will bring down the connection, reset the USB mode, and exit. Now you can unplug the USB cable, and reenable the cellular ("Data network mode"), WiFi, or 4G connections.
Known issues:
Since the usbnet script operates below the Android framework, it can't tie into the connectivity service and notify waiters than a network connection is available. This doesn't matter for most apps, and they should work just fine. Others won't "believe" a network connection is available and refuse to work. In testing I found that ConnectBot, Maps, Market, and Opera Mobile all work, but that the Amazon Appstore does not. I'm uncertain, but I think sync services (e.g., Calendar) may not work either. To my knowledge, there's no obvious place to tie into the framework to increase application compatibility. Hopefully this is still useful for most of the purposes of folks wanting wired connectivity.
The Linux rndis_host driver is rather finicky, even more so then when using Wired Tether. In testing, I found between half to 2/3rds of connection attempts to a Linux host would fail, but once connected, it seems to work fine.
Again, on Windows, getting an IP address is very slow, I'm not sure if anything can be done about that.
Also, I've only been able to test on EC05 (Froyo). I'm unlikely to be able to test this on Gingerbread before the official release hits.
Mirror link (does not require forum login):
usbnet.sh
Wait, nobody has posted anything here yet? I recall a couple of people looking for this so it gets a....BUMP..
Sent from my SPH-D700 using XDA Premium App
i have followed your method step by step...
but
when i connect usb cable to the host pc, select charging... and nothing happened
there is no new "Local Area Connection" appeared in Network and Sharing Center -> Change adapter settings....and so connect bot cannot acquired an IP addres.
any solution?
many thanks before
taufancandra said:
there is no new "Local Area Connection" appeared in Network and Sharing Center
Click to expand...
Click to collapse
Does Wired Tether work, or have you tried using it before?
When you connect the USB cable, what USB devices show up in Device Manager on the host?
Whether this works or no I'm glad you atleast tried.
Sent from my SPH-D700 using XDA Premium App
This seems to be just what I was looking for. Going to try it soon and report back.
Results:
Everything goes according to instructions (taking into account WinXP ILO Win7) until-
I get the LAC3.
Per Windows help menu instructions I run the Network set-up wizard to configure for ICS.
ERROR occurs during configuration, suggests to set up network manually.
Connectbot times out with a fail.
Ideas?
Hey there,
I would like to use reverse tethering over my usb cable.
Before I start I'll let you know my setup:
Windows 7 x64 machine, sdk (inc. adb) installed but adb seems to make problems
i9000 running infinitum 2.1 with devil2 v0.72
These are the steps I used:
-connect the phone
-activate usb-tethering on the phone
-PC: change the ip on the new network adapter to 192.168.2.1
-PC: set my local area connection to share my internet connection with the new network adapter
-PC: add http service to the shared internet services
-open terminal on the phone
-executing the following commands:
Code:
ifconfig rndis0 192.168.2.2 netmask 255.255.255.0 up
route add default gw 192.168.2.1 dev rndis0
iptables -F
iptables -F -t nat
setprop net.dns1 78.42.43.62
setprop "net.gprs.http-proxy" ""
Funny part is: I can't ping a domain like google.de also no app is able to access the internet... BUT I can ping 173.194.35.151 (google.de ip afaik?!).
So I DO have a connection... somehow (tested with WiFi off and mobile data off) but no app has access and it can't resolve any domain names?!
78.42.43.62 is the correct ip for my dns provider!
Here are two screenshots proving what I'm talking about: Screen1 Screen2
So what can I do? Can some1 help me out here?
EDIT: I just wanted to point out that normal tethering IS WORKING, I do have a stable connection to my phone (even when transfering data), drivers are working!
Read the following post.. maybe it'll help you
Reverse Tethering
I recently did a full install of android-x86_64-7.1-rc2 on my Laptop Lenovo Ideapad 110. Everything runs. Only issue I am running into is the WiFi connection as it keeps dropping. The weird thing is that when I plug the laptop to a direct connection (Ethernet) the internet connection is completely stable. All my other wireless devices that use my home WiFi are also stable.
Same problem
georgeellis28 said:
I recently did a full install of android-x86_64-7.1-rc2 on my Laptop Lenovo Ideapad 110. Everything runs. Only issue I am running into is the WiFi connection as it keeps dropping. The weird thing is that when I plug the laptop to a direct connection (Ethernet) the internet connection is completely stable. All my other wireless devices that use my home WiFi are also stable.
Click to expand...
Click to collapse
Same problem on my Asus Vivobook Flip TP203NA.
Release rc-1's wifi was working normally.
Ethernet cable still works.
How to
georgeellis28 said:
I recently did a full install of android-x86_64-7.1-rc2 on my Laptop Lenovo Ideapad 110. Everything runs. Only issue I am running into is the WiFi connection as it keeps dropping. The weird thing is that when I plug the laptop to a direct connection (Ethernet) the internet connection is completely stable. All my other wireless devices that use my home WiFi are also stable.
Click to expand...
Click to collapse
Can you please tell me how did you manage to activate Xposed on Android x86?
WIFI x86 8.1 RC1 not working on asus TP200SA
Hello, same thing for me here too, but I have installed RC1 and that does the same, all seems to work no wifi.
georgeellis28 said:
I recently did a full install of android-x86_64-7.1-rc2 on my Laptop Lenovo Ideapad 110. Everything runs. Only issue I am running into is the WiFi connection as it keeps dropping. The weird thing is that when I plug the laptop to a direct connection (Ethernet) the internet connection is completely stable. All my other wireless devices that use my home WiFi are also stable.
Click to expand...
Click to collapse
I also have the same issue.
LENOVO ideapad 110
Did you find solution?
I have Dell Inspiron Mini i installed Android-x86-8.1-r1 and only frist time after instalattion wifi work fine then when i restart Android wifi connection lost and no showing in wifi connections.
How to fix that?
Any update on this? I have an ASUS vivo pc with the wifi constantly dropping.
I have the same issue, using Chromebox with 9.0 rc1
Same issue here on a dell Pavilion DM4. Wifi worked on initial setup and then suddenly drops and cannot turn it on.
I've been having the same problem on android-x86_64-9.0-r2.iso (baremetal install/no VM, on asus laptop ux305fa). Found a workaround to get wifi back up and running:
Ctrl-Alt-F1 (to switch to console)
su (to get root)
ip link show wlan0 (shows wlan0 as DOWN)
ip link set wlan0 up
ip link show wlan0 (shows wlan0 as UP)
ping address-for-wifi-router (works now)
Ctrl-Alt-F7 (to switch back to GUI)
GUI at this point shows wifi is status is "connected" to my router, which I set up before with password and everything. Before I did the manual workaround, turning on the wifi slider button in the GUI caused an endless hang condition.
So the question is, why does wifi get hung up in the first place?
@colonal35 @panda9 @dbroadus2007 does my workaround have the desired effect for you?
UPDATE: in my case, after fixing as shown above, wifi came up automatically after next reboot.
UPDATE2: I noticed that after applying my fix, my wireless mouse does not work anymore. Could it be that the orioginal problem occurs because ax86 gets confused when there are two wireless devices wifi+mouse (+bluetooth, but bt seems not affected). Strike the preceding. After next reboot the wireless mouse is working again. At least so far.
reikred said:
I've been having the same problem on android-x86_64-9.0-r2.iso (baremetal install/no VM, on asus laptop ux305fa). Found a workaround to get wifi back up and running:
Ctrl-Alt-F1 (to switch to console)
su (to get root)
ip link show wlan0 (shows wlan0 as DOWN)
ip link set wlan0 up
ip link show wlan0 (shows wlan0 as UP)
ping address-for-wifi-router (works now)
Ctrl-Alt-F7 (to switch back to GUI)
GUI at this point shows wifi is status is "connected" to my router, which I set up before with password and everything. Before I did the manual workaround, turning on the wifi slider button in the GUI caused an endless hang condition.
So the question is, why does wifi get hung up in the first place?
@colonal35 @panda9 @dbroadus2007 does my workaround have the desired effect for you?
UPDATE: in my case, after fixing as shown above, wifi came up automatically after next reboot.
UPDATE2: I noticed that after applying my fix, my wireless mouse does not work anymore. Could it be that the orioginal problem occurs because ax86 gets confused when there are two wireless devices wifi+mouse (+bluetooth, but bt seems not affected). Strike the preceding. After next reboot the wireless mouse is working again. At least so far.
Click to expand...
Click to collapse
Just writing to share my almost-successful experience on this.
Symtpom: Many months ago, I installed Android x86 9.0 rc1 on one of my spare laptop (a Dell Latitude E5530, FWIW). It worked fine at that time. I did not use it since then, and recently when I booted that laptop, the WiFi icon in notification bar is dimmed, and the machine keeps "searching for Wi-Fi networks...".
Trying to follow @reikred 's workaround above, but in my case, the initial "ip link show wlan0" already shows wlan0 as UP, and then toggling "ip link set wlan up" or "... down" does NOT change the "ip link show wlan0" status at all. Inspired by @reikred's idea, I use "ifconfig" instead. "ifconfig wlan0 down" and "... up" can change wlan0 status. And then, the WiFi works ... momentarily. After I read a couple web pages, the WiFi hung up again.
But thanks for @georgeellis28 's sharing, the workaround of plugging in an ethernet cable does work! That is a pleasant surprise. I was not aware that an Android device would work with ethernet.
Well I have the same problem and I've figured out what the issue is. The wireless adaptor isn't supported in the version of linux that android x86 is using, specifically the Realtek 8822CE. I think a usb wifi adaptor would work. There may be different versions of the android x86 that work depending on what version of linux is used.
Same problem on HP Laptop.
i used on android 4.4 rc2 but it says "device wlan0 does not exist"