13

I have to use a wired conection to my PC and i'd like to connect my android phone to the internet over Wi-Fi. I tried using the new Wireless Hosted Network functionality in Windows 7, but my phone can't connect - it gets stuck at "Obtaining IP address...". The AP is working - it is visible in the list, but i can't connect.

I'm using the following comands(as administrator):

netsh wlan set hostednetwork mode=allow ssid=name key=password
netsh wlan start hostednetwork

Output of netsh wlan show hostednetwork:

Hosted network settings
-----------------------
    Mode                   : Allowed
    SSID name              : "name"
    Max number of clients  : 100
    Authentication         : WPA2-Personal
    Cipher                 : CCMP

Hosted network status
---------------------
    Status                 : Started
    BSSID                  : 70:f3:95:ad:a4:62
    Radio type             : 802.11n
    Channel                : 13
    Number of clients      : 1
        f0:08:f1:2f:aa:b7        Authenticated

My network adapter: Broadcom 4313 802.11b/g/n.

1
  • Your information is kind of cryptic. But I believe PleaseStand nails it on the head with Internet Connection Sharing. When you say "I have to use a wired conection to my PC . . .", I'm assuming you mean a wired connection to the Internet and not the phone :) Cause I can totally see someone thinking a USB is a Wired Connection.
    – surfasb
    Commented Sep 24, 2011 at 19:08

4 Answers 4

2

You will have to either bridge your wired and wireless interfaces or use Internet Connection Sharing.

Note: Use "Change adapter settings" instead of "Manage network connections"; Microsoft's web site refers to Windows Vista rather than Windows 7.

If you are doing this with the ICS approach, you need to make sure the ICS is set up before you start the hosted network with the "netsh wlan start hostednetwork" command. (I have tested this for 64-bit Windows 7 with the Internet connection provided via a USB-tethered Huawei smartphone.)

1
  • You mean that DHCP server should be launched somewhere in another network (either bridged or shared)? If so that won't work well for me, as I need just to access application running on Windows and listening on some port. Does Windows have a build-in DHCP server? It should be cause there are some registry settings for IP range.
    – dma_k
    Commented Jul 9, 2014 at 17:08
11

This is actually deceptively simple. It relates to the ORDER you do things in, The simple answer is you have shared the wrong network. A lot of "howtos" tell you to do it in a order that CANNOT work.

The correct order is covered here

1, In Windows 7 go to Change Adapter Settings (Open Control Panel and go to Network and Sharing Center. Click Change Adapter Settings.) have a look before you start any of this there will be at least TWO icons. a LAN icon and a WIFI icon. At least these two.

  1. Now run this:
  @cmd as admin:@ netsh wlan set hostednetwork mode=allow ssid=mywifi key=passphrase
  @cmd as admin:@ netsh wlan start hostednetwork

You will immediately see a NEW icon appear in Change Adapter Settings this is the actual connection that needs permission to share.

  1. Back to the Change Adapter Settings window. Right click your Actual Internet LAN connection icon (on my PC is is called "Local Area Connection" the icon has a little RJ45 connector symbol on it and the grey text says "Realtek PCIe GBE Family Controller" it has no red ticks on it and it's the internet connection for my windows 7 pc, which I know because if I disconnect the LAN cable from the back of the pc, it THIS icon that goes ill on me) and select Properties. Click the Sharing tab. Choose your new virtual Wi-Fi adapter that appeared after step 2 and click OK.

NB: the new one that appeared will have the grey text "Microsoft Virtual WiFi Miniport Adapter" under a name like "Wireless Network Connection 2"

Then right click the new virtual Wi-Fi adapter that appeared after step 2 and disable all the gubins except TCP/IP v4 (un tick them all under Networking tab except the "Internet Protocol Version 4 (TCP/IPv4)"

it was this website that helped me figure it out http://mintywhite.com/windows-7/set-windows-7-wifi-hotspot-quick-tip/

3
  • 1
    Removing anything but TCP/IPv4 solved it. Thank you! :)
    – NagyI
    Commented Oct 2, 2013 at 12:29
  • disable all the gubins except TCP/IP v4 this was the trick that worked for me too:)
    – VSB
    Commented Oct 11, 2014 at 14:03
  • At Step 3 at Sharing tab I had no choice of network to share with. The remedy: (1) Untick "Allow other net...", (2) Click OK, (3) Redo Step 3: a choice of connection will now be given via a dropdown menu. Commented Aug 4, 2015 at 6:54
2

Use these two links to set the AP: http://www.howtogeek.com/112050/how-to-turn-your-windows-8-laptop-into-a-wireless-access-point/ and http://msdn.microsoft.com/en-us/library/windows/desktop/dd815243(v=vs.85).aspx.

The best thing to do always is to rename the network that appears in grey text "Microsoft Virtual WiFi Miniport Adapter" under a name like "Wireless Network Connection 2" to something like "FooWifi" then you easily share with it. Your main problem is sharing the wrong network and checking if your AP has internet access.

0

In my case, I utilized this method to use my Laptop Internet on my phone. Then after a while, the problem of getting stuck in "obtaining IP address" on the phone happened, seems without any reason.

After trying the above solutions here with no success, I just renamed the SSID, and surprisingly it was fixed. Maybe helpful for someone else!

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .