Wireless Pi

I is very convenient to have a wireless access to your Raspberry. I chose a small USB adapter from TP-LINK: TL-WN725N v2.0. Unfortunately the latest available Raspbian (2014-09-09) hasn’t got any driver for this device by default. This is not a problem, because newest release of Linux kernel for Raspberry (3.12.29+) has all needed sources. To enable this driver we need to change the .config file. The easiest way to do this is to use the graphical kernel configuration tool:

make ARCH=arm CROSS_COMPILE=${CCPREFIX} menuconfig

The CCPREFIX variable should be set, like it was described in First steps page. Menuconfig needs ncurses library. If you don’t have it, install it with:

sudo apt-get install libncurses5-dev

The driver for TL-WN725N v2.0 ( RTL8188EU) is in Device Drivers -> Staging drivers section:

We need to enable its compilation as a kernel module by pressing M. Now we can save changes and close the configuration tool. The .config file is ready, so we can start the compilation. If you don’t need the whole kernel image, you can just compile the modules (check First steps for help). After the compilation, the driver file is ready to use. It is inside the directory:


Copy it to the same directory on your Raspberry SD card or, if you want also to upgrade the kernel, copy the kernel image with all modules (including 8188eu.ko).

If you have copied the driver to the running Pi using for example the scp command, you need to update the kernel modules list using depmode and run the driver using modprobe r8188eu (both commands as a root). You can check if the driver is active running lsmod – it should be on the modules list.

Now we can plug in the TL-WN725N and check the list of active network interfaces using ifconfig. There should be an interface called wlan0. If it is present on the list – everything was done correctly.

To connect to the wireless network using command line, you need to edit the configuration file (for example using nano or vi):

sudo nano /etc/wpa_supplicant/wpa_supplicant.conf

For WPA2-PSK connection just paste following lines at the end of the file:
  proto=RSN WPA
  pairwise=CCMP TKIP
  group=CCMP TKIP

For other connection types you can check out this link.

This is all. Just reboot the system and unplug the Ethernet cable (if you used any before). The adapter should automatically connect to your WiFi router and get the IP address.

Leave a Reply

Your email address will not be published. Required fields are marked *