Installing wifi adapter on raspberry pi

After configuring my raspberry using various images (xmbc or mpd )with an ethernet connection, it’s time to make it wireless 🙂

Bought an Edimax EW-7811UN wifi adapter for 11 Euro. How to install this on the latest Raspbian Wheezy image.

Install the driver

First you have to the right driver (see Raspberry forum) for the Realtek RTL8188CUS chipset.

Unpack it and copy 8192cu.ko to /lib/modules/3.1.9+/kernel/net/wireless

cp 8192cu.ko /lib/modules/3.1.9+/kernel/net/wireless

Add the following line to /etc/modprobe.d/blacklist.conf.

blacklist rtl8192cu

To load the wifi driver on boot put this to /etc/modules

8192cu

To make sure the driver can be loaded successfully, run

depmod -a

To activate the wifi interface, add the following lines to /etc/network/interfaces

auto wlan0
iface wlan0 inet dhcp
pre-up wpa_supplicant -Dwext -i wlan0 -c /etc/wpa_supplicant.conf -B

To configure the wifi, create the file /etc/wpa_supplicant.conf and put the following lines

ctrl_interface=/var/run/wpa_supplicant
ctrl_interface_group=0
ap_scan=2
network={
  ssid="myssid"
  scan_ssid=1
  proto=RSN
  key_mgmt=WPA-PSK
  pairwise=CCMP
  group=CCMP
# choose one of the following
# run wpa_passphrase "ssid"
  psk=<output wpa_passphrase>
}

Reboot the raspberry, and wifi should be running 🙂

PS: according to the post on raspberry pi forum, there’s a shell script to automate the steps above. I haven’t tried it.

Sources

  • http://www.raspberrypi.org/phpBB3/viewtopic.php?p=117530#p116866
  • http://elinux.org/RPi_edimax_EW-7811Un

wifi day

oh yeah. for me this weekend is wifi day.

now otw to dietzenbach (like 30min with train) helping a friend setting up home network, wifi, isdn phone with 3 lines. and maybe this evening in frankfurt also setting up wifi in combination with cable modem. wow totally interesting…. bazinga 😉

maybe for us (read nerd) is simple, but to those poor people, networking is like hell. which cable should i use, what this black box for, or why the lamps are blinking and no google. yeah dumb question, but its frustating for them.

when do i have time for myself…. 🙁