pi_pico/color_switcher
Mohamed Salem b62a86bdc7 Move build.sh and flash.sh to repo root as shared scripts
build.sh runs inside Docker (mounted at /scripts/build.sh via
docker-compose volume). flash.sh runs on the host and takes the
project name as an argument, auto-detecting the .uf2 file.

Usage:
  cd color_switcher && docker compose run --rm pico-build bash /scripts/build.sh
  cd .. && ./flash.sh color_switcher
2026-04-13 04:06:15 +02:00
..

Color Switcher

A Raspberry Pi Pico project that sends commands over UART to a connected computer. Written entirely in C using the Pico SDK.

Prerequisites

No local toolchain installation needed — everything runs inside the container.

Building

# Build the Docker image (first time only, or after Dockerfile changes)
docker compose build

# Compile the firmware
docker compose up

The .uf2 firmware file will appear in build/.

Flashing

  1. Hold the BOOTSEL button on the Pico and plug it into USB
  2. It mounts as a USB mass storage device
  3. Drag the .uf2 file from build/ onto the Pico
  4. The Pico reboots and runs the firmware

Interactive Shell

To drop into the build container for debugging or manual commands:

docker compose run --rm pico-build bash