Toby Branfoot
Posts: 21
Joined: Thu Nov 15, 2012 8:59 am

RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 01, 2012 8:35 pm

Help

I'm VERY new to this (or old, the last computers I used at this level were a PET, an Apple II & a ZX80)

I've got a Pi which works out of the box, and connects to the net OK when I plug in an Ethernet cable. But I can't get WiFi to work. I'm trying to get things working and understand how as I'm planning RPi Xmas presents for a niece and a nephew and want to be able to help them ...

I plugged in an Edimax EW-7811UN - read on this forum it works out of the box. It does ... only partly ... it seems to find my network but fails to make a proper connection ...

"Current Status
Adaptor: wlan0
Network 0:Netgear
Status: Completed(station)
Last message: Associated with 00:22:3f:84:cc:e2
Authentication: WPA-PSK
Encryption: TKIP
SSID: Netgear
BSSID: 00:22:3f:84:cc:e2
IP Address: (blank)" # I assume this is the problem?

"Scan
Netgear
BSSID: 00:22:3f:84:cc:e2
Frequency: 2942
Signal: -201dBm
Flags: [WPA-PSK-TKIP] [WPS] [ESS]"

I don't know what most of this means, and I don't know where to start "diagnostically".

I am guessing that the basic hardware is fine, and that somewhere I need to change settings for the RPi OS and/or the Adapter so they'll "talk properly"

Can anyone help ... what to do, where to ask, etc?

Cheers

Toby

Wheel_nut
Posts: 136
Joined: Tue Sep 18, 2012 7:51 pm

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 01, 2012 9:17 pm

If you are using the current download of Raspian Wheezy then all you need to do is open the WiFi setup utility on the GUI and enter your WPA passphrase.

Sometimes, I have needed to re-boot after changing the Passphrase.

Toby Branfoot
Posts: 21
Joined: Thu Nov 15, 2012 8:59 am

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 01, 2012 9:42 pm

Oh - should have said - I did that already ...

bgirardot
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 01, 2012 10:08 pm

Toby Branfoot wrote: "Scan
Netgear
BSSID: 00:22:3f:84:cc:e2
Frequency: 2942
Signal: -201dBm
Flags: [WPA-PSK-TKIP] [WPS] [ESS]"
That signal level looks really low. How far away from the Access Point are you?

Toby Branfoot
Posts: 21
Joined: Thu Nov 15, 2012 8:59 am

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 01, 2012 10:50 pm

Hi

I am about 6 m away from the router I'd estimate, through a floor by maybe 0.5 m ... so not a long way ...

I could try moving things about to get closer if you think that's the issue?

Cheers

Toby

bgirardot
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 01, 2012 11:10 pm

Yes, I would move it closer and see if that makes any difference, it should. You need about -65dBm for about 50% signal strength I think.

Toby Branfoot
Posts: 21
Joined: Thu Nov 15, 2012 8:59 am

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 08, 2012 3:38 pm

I have moved very close to the router - and no joy.

I read the RPi user guide - it talks about editing the /etc/network/interfaces file. I set out to try this ...

Opening the file with the nano editor I find

auto lo

iface lo inet loopback
iface eth0 inet dhcp

allow-hotplug wlan0
iface wlan0 inet manual
wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
iface default inet dhcp


The book suggest I should expect the first 2 lines, but not the next four about wlan0

The book advises adding:
auto wlan0
iface wlan0 inet dhcp
wpa-conf /etc/wpa.conf



Should I do this? Beyond the last four lines? Before them? Replacing them?

Cheers

Toby

bgirardot
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 08, 2012 4:00 pm

Toby Branfoot wrote:
auto lo

iface lo inet loopback
iface eth0 inet dhcp

allow-hotplug wlan0
iface wlan0 inet manual
wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
iface default inet dhcp
One simple change to try is change the line in the above file to:

iface wlan0 inet dhcp

instead of iface wlan0 inet manual

And then reboot the rpi

I am guessing you have a dhcp server someplace on your network. if not let us know.

the 'manual' setting means the wifi interface will not come up until you manually bring it up so lets try it on dhcp which also means it will try automatically when it first gets initialized.

Toby Branfoot
Posts: 21
Joined: Thu Nov 15, 2012 8:59 am

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 08, 2012 4:22 pm

Tried that - not helped - it now doesn't even find wlan0 apparently. iwlist scan reports "No scan results" and iwconfig reports :-
wlan0 unassociated Nickname:"<[email protected]>"
Mode:Auto Frequency=2.412 GHz Access Point: Not-Associated
Sensitivity:0/0
Retry:off RTS thr:off Fragment thr:off
Power Management:off
Link Quality:0 Signal level:0 Noise level:0
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:0 Invalid misc:0 Missed beacon:0


I will change the interfaces file back and see if it is found then ...

Cheers

Toby

Toby Branfoot
Posts: 21
Joined: Thu Nov 15, 2012 8:59 am

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 08, 2012 4:24 pm

PS:- I dont know what dhcp refers to, to know if one is part of my network ...

bgirardot
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 08, 2012 4:36 pm

Toby Branfoot wrote:PS:- I dont know what dhcp refers to, to know if one is part of my network ...
dhcp is the software that gives your computer an ip address and some other network info automatically instead of you having to manually configure it. Typically your home router does that now a days.

What does the blue light on the wifi dongle do when you boot it up?

What is the contents of your /etc/wpa_supplicant/wpa_supplicant.conf file?

I do not think I would go with what the book says, I think that is a bit out of date, my 2012-10-28 raspbian does not have an /etc/wpa.conf file, everything is in the /etc/wpa_supplicant/ directory

My wifi using the same dongle as yours works with the bare minimum in the wpa_supplicant.conf file:

Code: Select all

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
network={
        ssid="Exact Network Name Here"
        key_mgmt=WPA-PSK
        psk="your_password_here"
}
Last edited by bgirardot on Sat Dec 08, 2012 5:06 pm, edited 1 time in total.

Toby Branfoot
Posts: 21
Joined: Thu Nov 15, 2012 8:59 am

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 08, 2012 4:53 pm

Hi

My /etc/wpa_supplicant/wpa_supplicant.conf file is

[i]
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1

network={
ssid="NETGEAR"
psk="a21a21a211"
proto=WPA
key_mgmt=WPA-PSK
pairwise=TKIP
auth_alg=OPEN
}
[/i]

Toby Branfoot
Posts: 21
Joined: Thu Nov 15, 2012 8:59 am

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 08, 2012 5:04 pm

Just re-booted - the blue ight on the WiFi dongle flashes a mixture of fast and slow pulses during boot - and is now switched off ...

bgirardot
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 08, 2012 5:14 pm

That looks right and it sounds right as far as the flashing goes.

Give this a try and see what happens:

Code: Select all

sudo ifup wlan0
probably returns an error so do what it says:

Code: Select all

sudo ifdown --force wlan0
then try again:

Code: Select all

sudo ifup wlan0
and see if that gets the blue light blinking in a basically rhythmic way.

Wheel_nut
Posts: 136
Joined: Tue Sep 18, 2012 7:51 pm

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 08, 2012 6:11 pm

Could you check the voltage between TP1 and TP2 on the RPi Board and post the reading here.

Toby Branfoot
Posts: 21
Joined: Thu Nov 15, 2012 8:59 am

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 08, 2012 7:08 pm

Hi

bgiradot ... did what you suggested ...not good ... thanks for the really positive and helpful ideas though ...

[email protected] ~ $ sudo ifup wlan0
ioctl[SIOCSIWAP]: Operation not permitted
ioctl[SIOCSIWENCODEEXT]: Invalid argument
ioctl[SIOCSIWENCODEEXT]: Invalid argument
[email protected] ~ $ sudo ifdown --force wlan0
[email protected] ~ $ sudo ifup wlan0
ioctl[SIOCSIWAP]: Operation not permitted
ioctl[SIOCSIWENCODEEXT]: Invalid argument
ioctl[SIOCSIWENCODEEXT]: Invalid argument
[email protected] ~ $


No blinking ... silent ...

Wheel_Nut ...sorry, not sure what/where I need to test/check ... not even sure if the "multimeter" I have somewhere down in the basement is the right tool for this job ... but will give it a go ...

bgirardot
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sat Dec 08, 2012 8:42 pm

Ya, interesting. I actually get those same error messages with ifup wlan0, but it comes up and works none the less.

I do get a different message the first time I try it though, mine says wpa_supplicant has control of the interface and that I need to use the ifdown --force command first, interesting that you did not receive that message.

Yes, a multi meter is what you need to test the power on the board, you will see two small holes on the top surface of the RPi, one labeled TP1 and one labeled TP2 (Test Point 1 & 2) measuring the DC voltage across them will tell us if the board is actually getting enough power.

mixer
Posts: 11
Joined: Fri Dec 07, 2012 10:14 pm

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sun Dec 09, 2012 10:37 am

Hey Toby,

I had the same problem with the same WiFi stick. I tried to connect to the router with the GUI, but it seemed to connect and disconnect continuously every second.

I then started using Occidentalis v 0.2 http://learn.adafruit.com/adafruit-rasp ... s-v0-dot-2 instead of the original Wheezy.

then do

Code: Select all

# sudo nano /etc/network/interfaces
-> insert SSID and password

Code: Select all

# sudo shutdown “now“ –r
-> restart

Code: Select all

# iwconfig
# sudo ifconfig –a
-> to get your IP adress

(I had to restart twice to get it to work)

Hope it helps ;)

User avatar
walney
Posts: 233
Joined: Wed Nov 30, 2011 6:57 pm
Contact: Website

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Fri Dec 14, 2012 10:34 am

Hey Toby,

I had exactly the same problems with my pi / netgear router / Edimax.

My netgear is set up as a DHCP server. This works fine when connection via the built-in ethernet, but when connecting across wlan0, no IP address seems to be assigned. I got round the problem by assigning a static address.

To see if this works for you, edit /etc/network/interfaces:

Code: Select all

#iface default inet dhcp
iface default inet static
   address 192.168.0.10
   netmask 255.255.255.0
   network 192.168.0.0
   gateway 192.168.0.1
Values assume that the default networking is set up on the netgear. (But you might also need to check what the range of addresses that the netgear generates for DHCP, and make sure that either the static address is not in the range, or else ensure that the router excludes it.)

Toby Branfoot
Posts: 21
Joined: Thu Nov 15, 2012 8:59 am

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Sun Dec 16, 2012 11:54 pm

Hi

Thanks Mixer & Walney - tried both of your suggestions without success - both generate errors so I don't even get a connection or the network found - instead of the network being found and a connection but without an IP address so it's non-functional ...

Stuck ... but thankfully the ethernet cable works just fine ... hmmm ...

Cheers

Toby

klamath
Posts: 1
Joined: Fri Aug 03, 2012 8:55 pm

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Fri Dec 21, 2012 10:04 am

Hi Toby,

I was having similar problems to you with my Pi and EW-7811UN to the point of binning them both .... but the latest distro 2012-12-16-wheezy-raspbian.zip seemed to fix and now it works out of the box and wpa_gui seems to work very well now, rather than just hanging.

Suggest you try again with this new distro?

Hope this helps.

David.

arbboy1998
Posts: 1
Joined: Wed Aug 21, 2013 12:42 am

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Wed Aug 21, 2013 12:48 am

You need a better power adapter. I have seen many experience the same problem. Although most power adapters supply enough for this adapter, some do not. Others have experienced this exact same problem, look at the Amazon.com reviews for this product. Hopefully this will fix your problem.

User avatar
sav25
Posts: 364
Joined: Thu Aug 30, 2012 7:18 pm
Location: Southend-on-Sea, Essex, UK
Contact: Website Twitter

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Wed Aug 21, 2013 12:55 pm

Check out the 'Helpful Pi Links' section on my blog, and find the one labelled "Edimax Nano Wifi Adapter Setup".

I tried a few methods but this is the only one that worked for me.

http://www.AverageManVsRaspberryPi.com
Last edited by sav25 on Wed Apr 16, 2014 9:15 pm, edited 1 time in total.
Averagemaker.com

User avatar
avatar1337
Posts: 78
Joined: Sun Jan 27, 2013 3:14 pm

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Thu Aug 22, 2013 6:50 pm

I have the same adapter it just stopped working for me in Raspbian. I think it worked after reflashing, but I am using another one now. Try reflashing the raspbian image. If the X11 wifi config tool doesn't find the adapter I believe you have to reflash the image.
The creator of the Raspberry Pi Configuration Manager (PiCon)

andyfras
Posts: 6
Joined: Mon Feb 27, 2012 5:28 pm

Re: RPi & WiFi USB Adapter problems (Edimax EW-7811UN)

Thu Nov 07, 2013 10:12 am

I have been having the same problem for some time (lack of IP address). I'd almost given up with the Pi because, if I couldn't get this simple part working, what chance would I have of doing anything useful with it? I decided to give it another go in the hope that there would be more suggestions for a solution since the last time I checked - there were, but none of them worked for me.

I eventually got it going with the following:

auto lo

iface lo inet loopback
iface eth0 inet dhcp

allow-hotplug wlan0
iface wlan0 inet manual
wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
iface default inet static
address 192.168.0.20
netmask 255.255.255.0
gateway 192.168.0.1


The address and gateway above is an example and would have to match your router of course.

It's disappointing that the WiFi setup seems to be so flaky in Raspbian. Any other WiFi device that I buy logs onto my wireless network without a problem.

Return to “Beginners”