Raspberry Pi Manual Setup¶
Requirements¶
If your Raspberry Pi is not yet set up, we recommend installing Raspberry Pi OS. To set up your Pi, you’ll need the following:
Your Raspberry Pi 3 or 4
Computer monitor
HDMI cable
USB mouse and keyboard
Micro SD card
Some kind of adapter to modify the micro SD card with your development machine
Initial Setup¶
If you have all the equipment listed above, follow these steps to set up the board:
Download the latest Raspberry Pi OS image to your development machine. Select the “Raspberry Pi OS (32-bit) with desktop and recommended software” download from the Raspberry Pi OS download page.
Flash the image on your SD card using a tool like balena Etcher.
Attach the monitor, mouse, and keyboard to the Raspberry Pi, plug in the SD card, and boot the Pi. Go through the initial configuration.
Update the installed packages: In a terminal run
sudo apt-get update && sudo apt-get upgrade -y
to ensure you have the latest packages installed.Enable SSH: Open a terminal and run the
sudo raspi-config
command to bring up the configuration tool. In the “Interfaces” tab, select the “SSH” line to enable SSH.Connect to Wi-Fi: Before you move over to your development machine, you should connect to Wi-Fi and note down the Pi’s IP address. In
raspi-config
go to the “Networking Options” and select the “Wi-Fi” option. Enter your Wi-Fi credentials to connect. SelectFinish
to exitraspi-config
. In your terminal, enterifconfig
and note down the IP address in thewlan0
section. It will look like this:inet 192.168.1.75
Test your SSH connection: From a terminal on your development machine, open an SSH connection to the Pi using the device credentials. If you left the defaults your username will be
pi
, your hostname will beraspberrypi
, and the password will beraspberry
.$ ssh <username>@<hostname>
If the hostname is not found on your network, try the IP address. If the connection goes through, you’re ready to move on to installing Docker and other edgeIQ requirements.
Install Docker and Other Dependencies¶
Connect to your device¶
From your host machine, SSH to your device using the device credentials. If you left the Raspbian defaults, your username will be pi
, your hostname will be raspberrypi
, and the password will be raspberry
.
$ ssh <username>@<hostname>
If the hostname is not found on your network, try the IP address.
Enable the camera¶
If you’re using the Raspberry Pi ribbon camera, in a terminal run the sudo raspi-config
command to bring up the configuration tool. In the “Interfaces” tab select the “Camera” line and choose it to enable the camera. You can reboot now or wait until after the Docker install.
Install Docker¶
Run the following commands in the SSH connection to install Docker on your Raspberry Pi:
$ sudo curl -sL get.docker.com | sh
$ sudo usermod -aG docker $USER
$ sudo reboot
Test¶
Once the Pi reboots, open a new SSH connection and test the Docker installation with the following command:
$ docker run hello-world
Your Raspberry Pi is now ready to go!