Skip to content

Instantly share code, notes, and snippets.

@rockstarartist
Last active December 28, 2017 15:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rockstarartist/482599aae63f165109144d93bf6f79d8 to your computer and use it in GitHub Desktop.
Save rockstarartist/482599aae63f165109144d93bf6f79d8 to your computer and use it in GitHub Desktop.
Setup Raspberry Pi Zero W without HDMI

MacOSX Instructions:

Download and unzip latest Raspbian lite image: https://www.raspberrypi.org/downloads/raspbian/

Download and install Etcher (Very easy to use Image Burner) https://etcher.io/

Insert your MicroSD card into your reader or adapter

Run Etcher, select Raspbian Image, select SD card, and reimage

Open your terminal, and type the following (Change directory into the SDHC card, create a file called ssh, and create a file called wpa_supplicant.conf:

cd /Volumes/boot
touch ssh
touch wpa_supplicant.conf

After November 2016, SSH has been disabled for security reasons. Creating the ssh file is like a flag, it tells the Pi during boot-up to start the ssh server.

In the wpa_supplicant.conf file type the following:

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

network={
    ssid="Your SSID Here"
    key_mgmt=WPA-PSK
    psk="YourPresharedKeyHere"
}

Unmount the SDHC card, and place it in the Raspberry PI zero W Plugin in the Raspberry PI zero W, wait a couple of minutes for it to startup and connect to your router, then check your router to see what your PI's IP is, otherwise use a tool like NMAP to scan your network and find your PI's IP address.

Update the software running on your Zero:

sudo apt-get update -y
sudo apt-get upgrade -y

Save energy and speed up the device.

Boot up into multi-user mode (disable GUI on boot)

sudo systemctl set-default multi-user.target.

Disable HDMI by editing /etc/rc.local by adding the following line at the bottom above the exit 0 line:

/usr/bin/tvservice -o

Change other common Raspberry Pi settings via:

sudo raspi-config
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment