Raspberry Pi Zero W Setup

Over the weekend I purchased a Raspberry Pi Zero W from Pimoroni. The Zero W is a very small computer that has wi-fi and I hope to use it to run some automated scripts.  I already have a Raspberry Pi 2 and a Raspberry Pi 3 but wanted a Zero W as its smaller and can be tucked away.

img_20180619_111141.jpg

The tech specs of the Pi Zero W are:

  • 1GHz, single-core CPU
  • 512MB RAM
  • Mini HDMI and USB On-The-Go ports
  • Micro USB power
  • HAT-compatible 40-pin header
  • Composite video and reset headers
  • CSI camera connector
  • 802.11 b/g/n wireless LAN
  • Bluetooth 4.1
  • Bluetooth Low Energy (BLE)
Look how small the Pi Zero W is!
Look how small the Pi Zero W is!

I downloaded the latest Raspbian lite operating system image as I’m not looking to use the desktop GUI and I like having to use the terminal (keeps me on my toes).

To get the Pi Zero W to auto connect to wi-fi and allow an ssh connection 2 files must be placed on the microSD card’s “boot” section. The first file handles the wi-fi connection, must be called “wpa_supplicant.conf” and has to contain the following information:

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev

update_config=1

country=UK

network={

                  ssid=”Your network name/SSID”

                  psk=”Your WPA/WPA2 security key”

                  key_mgmt=WPA-PSK

}

When creating this file I used nano via Ubuntu, do not use a word processor (e.g. MS Word).

The 2nd file that is needed is a blank text file called ssh (no dot or file extension).

With these files on the boot sector of the microSD card, pop the card into the Pi Zero W and power it up. Hopefully it will connect to your wi-fi and SSH can be used to log into the Pi Zero W.

mac ssh
Notice the prompt alters when successfully logged into an SSH session

One thought on “Raspberry Pi Zero W Setup

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.