1. Computer Skills
  2. Electronics

Raspberry Pi Cheat Sheet, Part 1

Read Time:5 minsLanguages:

The Raspberry Pi is an incredible little computer that is revolutionising computing in the classroom, and at home.  It's single-handedly responsibly for introducing a new generation to programming and experimentation as opposed to learning how to use spreadsheets and word processors.

For anyone new to Raspberry Pi, there is a lot to get to grips with and–consequently–a lot to remember.  This tutorial provides an aide memoire, a cheat sheet of useful things that you need to know.  You might wish to bookmark this one.

Setting Up an SD Card

Before you are able to use this cheat sheet, you will need to have your Raspberry Pi up and running with an operating system.  This tutorial assumes that is the case.  If it is not, please refer to our tutorials to set up an SD card for your Pi.

Tip: To set up an SD card, refer to our tutorials How to Flash an SD Card for Raspberry Pi and How to Install NOOBS on a Raspberry Pi With a Mac

Enter Recovery Mode (NOOBS)

Immediately on powering-up the Raspberry Pi, a screen will appear–momentarily–saying Press SHIFT key to enter recovery mode.  Provided that you are ready and press the Shift key, you will enter a recovery partition.

The recovery partition allows you to start again, easily, with another copy of Raspian or with an alternative OS.

On boot hold down the Shift key

Access and Run the Pi Configuration Tool

From the command line interface, or in Raspbian, open LXTerminal and type: 

The Raspberry Pi configuration tool allows you to define a number of settings on your Pi, including:

The Raspberry Pi configuration tool
  • Expand Filesystem–ensures that all of the SD card is used for storage
  • Change User Password–replace the default user and password, pi and raspberry respectively
  • Enable Boot to Desktop/Scratch–choose to boot direct into desktop environment rather than command line interface, CLI
  • Internationalisation Options–Specify language and regional settings
  • Enable Camera–for use with the Raspberry Pi camera add-on
  • Add to Rastrack–to add to the global Raspberry Pi tracker
  • Overclock–change the speed of the processor
  • Advanced Options– 
  • About raspi-config–information about the configuration tool

To navigate the interface use the Up Arrow and Down Arrow keys to move up and down in the list.  The Tab key allows your to choose the <Select> and <Finish> options.

Overscan Explained

When a Raspberry Pi is first connected to a television or monitor, the graphics may not occupy the entire screen.  You may see a black border around the image; this is underscan.  Alternatively, the full image may be truncated around the edges, the graphic environment disappearing over the edges of the monitor.  This is overscan.

One is to enable overscan or underscan on the monitor through the display menu options.  If this is not possible, it can be done on the Raspberry Pi.

Overscan settings in raspi-config

To enable or disable overscan, on the Raspberry Pi, from the command line interface, or LXTerminal if you are in the graphical user interface, enter the command:

Select 8 Advanced Options > A1 Overscan then <Enable> or <Disable> as required.

How to Determine the IP and MAC Addresses

Often, it is useful to know the IP address, on the network, of a Raspberry Pi.  To determine the IP address of the device, enter the following command from the command line interface, or LXTerminal if you are in the graphical user interface:

The IP address of the Raspberry Pi is displayed on the second line, in this example as inet addr:

Determining the IP address using ifconfig

The first line shows the MAC address.  In this example, the MAC address of the device is HWaddr b8:27:eb:45:1c:a0.

How to Set a Static IP Address

In order to set a static IP address on a Raspberry Pi, just edit the interfaces file using a text editor, in this example I am using nano. Enter the following command from the command line interface, or LXTerminal if you are in the graphical user interface:

This will open the text editor that will enable the editing of the configuration file.

Editing the /etc/network/interfaces confgiuration file

Edit the appropriate line, in the file, from iface eth0 inet dhcp to iface eth0 inet static.  Then add the following lines to the file:

The address IP setting will be the IP address you wish to specify as static on your network.  The gateway, netmask, network and broadcast IP addresses are dependent on your network and can be obtained from the router.

Press Control-O and then Enter to save, followed by Control-X to exit.

Changing the Default Hostname

In order to change the default hostname of a Raspberry Pi, just edit the hostname file using a text editor, in this example I am using nano

Enter the following command from the command line interface, or LXTerminal if you are in the graphical user interface:

Entering a custom hostname. Useful if you have more than one Pi on the network.

Enter the desired name  then press Control-W  then Y to save and exit the text editor.  Enter the following command to replace raspberry with the hostname you chose above.

Save and close the file and enter the following command to apply the changes:


In this tutorial, I have covered a number of areas that are useful for any Raspberry Pi enthusiast to know.  I covered setting up an SD card, configuring NOOBS, Overscan, determining IP and MAC addresses, setting a static IP address and changing the hostname.

In part two of my Raspberry Pi Cheat Sheet I will show you how to enable secure shell–SSH–access,  accessing a Raspberry Pi from different operating systems, changing the default username and password, explaining the software respository, setting up and getting the most out of VNC screensharing and looking at alternative browsers

Looking for something to help kick start your next project?
Envato Market has a range of items for sale to help get you started.