On most laptops when you share you LAN connection via wireless create an "adhoc" wireless network unless you are lucky and have a wireless card that does "infrastructure mode". Normally this is not a problem but Android does not support it by default.
In order to enable enable it you need to replace the file in /system/bin/wpa_supplicant with a version that supports it. Also you need to have root. If you do not yet have root follow my guide here.
This guide comes via SilverW1ndy (J).
Download this version of wpa_supplicant
This method uses "Root Explorer" which is a paid app but if you want to use the free way you can use the Terminal Emulator method mentioned here.
- use "root explorer" to mount /system/bin/ and make a backup of wpa_supplicant
- rename the current one to wpa_supplicant.bak and copy the new wpa_supplicant to /system/bin
- then we need to adjust the permissions on the file to match this picture
- change /system/bin back to read only
- disable and re-enable wireless
- now your adhoc wireless network should be listed with the other wireless networks and you can connect.
So, have you looked for the original XDA thread? I wonder if a similar thing is doable with other handsets. It's not like the radio and vendor specific, right?
ReplyDeleteI haven't I will have to check. I wouldn't think it I'd phone specific. Why don't you test it on yours? It is pretty easy to roll back the change.
ReplyDeleteIs there any way to fix this problem without having to root?
ReplyDeleteNo unfortunately since you are replacing system files that are normally read only you need to have root.
ReplyDeleteThanks, this guide worked for me. I can now use N-speeds instead of the G speeds of my router. When friends new to Japan ask about cell phone info, I always send them here!
ReplyDeleteOn a side note, I washed my Galaxy S II less than 3 hours after I confirmed it working. Let's see if it lights up after it dries out :( I did that to my n97 a few years ago, and it worked after replacing the battery. Now to find a spare asc29029 battery to test it.
I heard sticking it in a bowl of dry rice really helps dry phones out when they get wet. Just make sure it is dry before testing it. Good luck!
ReplyDeleteya i can view adhoc networks but it stops at obtaining ip adress and says disconnected
ReplyDeleteHmm you might need to check the setting on the computer you are trying to connect to. What type of machine are you trying to share your connection from? If that machine isn't configured properly to give out DHCP addresses that could be the problem.
ReplyDeleteWOW.. Its work for me..
ReplyDeleteMany many Thanx bro...after spending many days to resolve this problem..finally got the solution.. :-)
I am very disappointed as it didnt work for me. I changed the wpa_suppliment and I could able to see the ad hoc network. But it is struck in obtaining IP add.. and phone will hang for 10 seconds.. and it disconnects. Any suggestions for this.?
ReplyDeleteI would check the documentation on whatever OS you are trying to share the connection from. You need to make sure that is properly setup to either relay the DHCP request to your local DHCP server or to assign IP's from the NAT'd interface.
ReplyDeleteI have found that with Linux it can be very hard to get working but in Mac and Windows it is much easier to set up.
thanks for the swift reply..
ReplyDeleteI am using the Win 7 OS.. and trying to connect with laptops Ad Hoc network..
I am using rooted SGS2 with Stock ROM...
take a look at this thread. You might try and change the wireless encryption settings.
ReplyDeletehttp://social.technet.microsoft.com/Forums/en-US/w7itpronetworking/thread/dc00f244-b397-40be-8286-b448249949f0/
But that thread was not having any solutions .. am trying with connectify.. will update the status..
ReplyDeleteI connected using connectify.. But the internet is dropping randomly. But the wifi is steadily connected. i cant access laptop internet in my Samsung galaxy s2 android phone intermittently. i.e. once in 5 sec. after sometime if you try it will work for ten more sec thats all.
ReplyDeleteany ideas?
you might try installing wireshark to look at the packets to see what is what is happening on the network when that is happening. That should give you a good idea of what is going on.
ReplyDeletethanks a lot
ReplyDeletehello,
ReplyDeletethis works for me kind off.... if i use no encryption i can connect. but when i set it up as wpa2 my galaxy s2 stops at the autentication step. do you have a hint for me? thanks a lot
you might try wpa2 with psk rather than aes if that is what you are trying.
ReplyDeleteIt works Perfectly with my Galaxy note .. Thanks man
ReplyDeleteThanks for this article it helped to acess my laptop internet on my samsung galaxy s2
ReplyDeleteIt's perfect with my SGS2! Great Job! Thanks,
ReplyDeleteHi I copy the file and connected my Samsung GS2 to nokia N8 byJoikuSpot Light but no data is pasing ????
ReplyDeletemaybe a problem with the Nokia.
ReplyDeleteNo works with E72 ?
ReplyDeleteit asks me for an application to open the wpa supplicant with...am on ics ressurection remix....can't open the file to make the ticks required
ReplyDeleteI am using "root explorer" to set the permissions. I have not tried this on ICS so let me know if it works for you.
ReplyDeleteI tried it here, but as i changed the WPA_supplicant, Wifi cant be activated anymore.
ReplyDeletesometimes the sign in tray is highlighted, but in the options it says its deactivated.
Galaxy S2 Europe Cyagenmod 9 (Android 4.0.1)
yeah it must be different for ICS then. I would think CM9 would include that functionality.
ReplyDeletei hope so.( need it for gremote )
ReplyDeleteI too am running ICS and can confirm the exact same problem. Wifi wont turn on. Anyone figure out a fix for this issue?
ReplyDeleteHi... Thank u for dis wonderful post... dis adhoc is working my Galaxy S2 Rooted, but the issue is Internet is too slow. i'm using Airtel 3g USB Modem with 3.2mbps. pls can u help me
ReplyDeletei tried the wpa supplicant on my galaxy s2 gingerbread 2.3.3...it was fun.i later factory reset my phone erasing every data on my phone.afterwards i did the wpa supplicant again and this time it sees my ad-hoc network,connects to it but when i browse on my phone it says no internet connection.i flashed my rom with stock rom 2.3.3 tried it again and it still sees my ad-hoc network,connects to it but no internet connection.i think i just spoilt my phones wifi....anyway i have enabled internet sharing on my laptop..please help
ReplyDeleteIt looks like the latest CM9 includes support for ADHOC networks.
ReplyDeleteYEAH!!! it really works for me.
ReplyDelete:( wifi is not working anymor !
ReplyDeleteThis is for GingerBread only, not ICS.
ReplyDeleteI need it for Cynagen Mod 9. Worked well in cyanagen mod 7. but not working for 9. Can please help me
ReplyDeleteDoes this work still I've been messing about with networks for about three weeks
ReplyDelete