Labels

Linux (27) Python (12) Raspberry Pi (4) Bugs (3) Install (3) Brainf**k (1) C (1) HTML (1) Maths (1)

Thursday, 31 December 2015

How to setup wifi on the Raspberry pi

Setting up wifi on the Raspberry pi on the command line requires a few things.
  1. The ssid i.e. TP-Link
  2. The router password

To get the ssid run :
iwlist wlan0 scan

Then find the ssid out of the data it gives you.
Now we need to login to the Pi.
Once your logged in open up the file /etc/network/interfaces, you will need to be root.
Find the line that says
allow-hotplug wlan0

Add the following lines below it
iface wlan0 inet dhcp
        wpa-ssid "YOURSSID"
        wpa-psk "YOURPASSWORD"

Now reboot your Pi and you should be connected to the wifi.