Raspberry Pi

How to connect a Raspberry Pi with the WLAN Home Network

The very first thing you have to do is plug your Wireless USB Adapter into a USB port of the Raspberry Pi. If you came straight to this Tutorial and haven’t done the last Tutorial you can have a look on this Page to know what you need for building an internet radio with the Raspberry Pi. For establish a WLAN connection you only need the Wireless USB Adapter and a Raspberry Pi itself. For building an internet radio with the Raspberry Pi you will need all of the mentioned items.

First you have to establish a connection to your Raspberry Pi  just like in this Tutorial. After this you need to login into your Raspberry Pi via Putty just like in the beginning of this Tutorial.

Now that you are logged in again your Putty screen should look like this:

This picture shows the screen of the program Putty after you logged into your Raspberry Pi.

If you already know the exact name and the password of your WLAN network you can jump to steps 2 if not the following will help you to find them.


To scan the environment for WLAN networks you need to run the folowing code snippet:

sudo iwilist wlan0 scan

If there are many WLAN networks in your neighbourhood the command window will print out quiet a few lines. Here you have to search for a line that looks like this:


Obviously “THE_NAME_OF_YOUR_WLAN_NETWORK” in the line above must be replaced by the real name of your WLAN network. What is within the quotation marks is the exact name of your WLAN network.

The password can be found on the backside of your Router if you didn’t change it. If you changed it you should know it. 😉


Now you have to open the file where you can fill in the name and password of the network:

sudo nano /etc/wpa_supplicant/wpa_supplicant.conf

You have to add these three lines at the end of the file you just opened:


But you have to put the real name of your WLAN network after ssid=” and the real password after psk=”.

ADVICE: You can copy and paste in the command line of the Raspberry Pi with selecting and right clicking.

Your file should look like this now:


This picture shows the file where you change network connections.

After this is written to the file you press Strg+x and the Raspberry will ask you if you want to save the modified buffer. You hit y and enter. Now you should be back in the command line.

Now you can unplug the LAN cable from your Raspberry Pi and restart the Raspberry Pi by unplugging and reconnecting the micro USB charger cable. The Wireless adapter should blink blue and the internet radio should start playing within a minute after reconnecting the electricity. You are almost done! In the next Tutorial I will show you how you can build up the whole internet radio for a reasonable use.

Leave a Reply

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