Tutorial 02

Tutorial 02 — Camera + Phone Control

Raspberry Pi 4 / Raspberry Pi 5

What you’ll build

You’ll add a Pi Camera to your robot car and control it from a phone or laptop over Wi‑Fi. You’ll get a simple web control page (buttons) + live video stream.

Prereq: Tutorial 01 robot car should already drive normally.
Tutorial 02 hero

Parts you need (add-ons)

  • Raspberry Pi Camera (v2 or v3) + ribbon cable
  • Pan/Tilt mount (optional) + 2 micro servos (optional)
  • Stable Pi power: 5V 3A (Pi 4) or 5V 5A USB‑C (Pi 5) recommended
  • Wi‑Fi access (home router or phone hotspot)

Shopping links are embedded in the PDF too.

Step 1 — Enable the camera

  1. Power off the Pi.
  2. Connect the camera ribbon cable to the Pi camera port (blue tab faces the Ethernet/USB side on most Pi boards).
  3. Boot Pi → run: sudo raspi-config → enable camera (if shown) → reboot.

Step 2 — Install the simple streaming + control app

Run these commands in Terminal:

sudo apt update
sudo apt install -y python3-flask python3-picamera2

Create a folder:

mkdir -p ~/wolfieweb_robot_control

Download the starter code package (included in the PDF):

Option A: Copy/paste from PDF.

Option B: I can generate a ready-to-upload ZIP for the code folder if you want it as a download on the site.

Step 3 — Videos that help

  • Search YouTube: “Raspberry Pi camera live stream picamera2”
  • Search YouTube: “Flask robot control Raspberry Pi”
  • Search YouTube: “Raspberry Pi robot car web control”

(These are stable search phrases so you’re not locked to a single video that might disappear.)