I am trying to connect my RPi to my WLAN, but I fail. The network connection works when I use a cable. The RPi was bought about two weeks ago, and I am using a recent (I don't know exactly which) version of Raspbian.
My router is an AVM Fritzbox 7270 running a WPA/WPA2-secured wireless network with a public SSID and DHCP enabled. The network key is a number with 16 digits.
The wireless network is found if I type iwlist wlan0 scan
. The wireless network adapter being used is a Netgear WNA1000M. The adapter is listed if I type ifconfig
, but it has no IP address assigned.
I updated the /etc/network/interfaces
file according to the information I found on the web. Now the file looks like this:
auto lo
iface lo inet loopback
iface eth0 inet dhcp
auto wlan0
allow-hotplug wlan0
iface wlan0 inet dhcp
wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
wpa-ssid MYSSID
wpa-psk MYPSK
iface default inet dhcp
For MYSSID
and MYPSK
I entered the SSID of my network (without quotes) and the value I got from the wpa_passphrase
command (also without quotes).
The file looked originally like this:
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
When I reboot my RPi, the blue led of the wireless adapter flashes for about one second, then turns off again, and I can not access my RPi in a wireless way.
Once I connect it to the cable, I am able to access it using SSH again.
The last lines of dmesg
are:
[ 3.010438] usb 1-1.1: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[ 3.036171] smsc95xx v1.0.4
[ 3.098577] smsc95xx 1-1.1:1.0: eth0: register 'smsc95xx' at usb-bcm2708_usb-1.1, smsc95xx USB 2.0 Ethernet, b8:27:eb:85:47:8d
[ 3.213348] usb 1-1.3: new high-speed USB device number 4 using dwc_otg
[ 3.325470] usb 1-1.3: New USB device found, idVendor=0846, idProduct=9041
[ 3.343128] usb 1-1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 3.363116] usb 1-1.3: Product: 802.11n WLAN Adapter
[ 3.370586] usb 1-1.3: Manufacturer: Realtek
[ 3.393128] usb 1-1.3: SerialNumber: 00e04c000001
[ 3.843420] udevd[137]: starting version 175
[ 6.484503] usbcore: registered new interface driver rtl8192cu
[ 9.612649] EXT4-fs (mmcblk0p2): re-mounted. Opts: (null)
[ 10.076909] EXT4-fs (mmcblk0p2): re-mounted. Opts: (null)
[ 10.838719] bcm2835 ALSA card created!
[ 10.852938] bcm2835 ALSA chip created!
[ 10.865355] bcm2835 ALSA chip created!
[ 10.871429] bcm2835 ALSA chip created!
[ 10.882875] bcm2835 ALSA chip created!
[ 10.891016] bcm2835 ALSA chip created!
[ 10.899001] bcm2835 ALSA chip created!
[ 10.906941] bcm2835 ALSA chip created!
[ 19.430721] smsc95xx 1-1.1:1.0: eth0: link up, 100Mbps, full-duplex, lpa 0x45E1
[ 50.632430] smsc95xx 1-1.1:1.0: eth0: link down
[ 65.384999] smsc95xx 1-1.1:1.0: eth0: link up, 100Mbps, full-duplex, lpa 0x45E1
[ 83.627435] Adding 102396k swap on /var/swap. Priority:-1 extents:1 across:102396k SS
As you can see the wireless adapter is being detected in the lines that start with usb 1-1.3
, but nothing happens afterwards.
The RPi is powered by an adapter with (I guess) 1.0A, it may be 2.0A.
Any idea what I am doing wrong?