SRUG 2024.02 Meetup
https://slides.com/u007d
On a Raspberry Pi Pico
Prerequisites:
1. https://www.rust-lang.org/tools/install
2. `rustup target add thumbv6m-none-eabi`
Mac: `brew install git` (see https://brew.sh/) or
https://github.com/git-guides/install-git
Ubuntu: `apt install git`
Windows: https://github.com/git-guides/install-git
1. Wire pin 1 (GPIO 0) to an empty row
2. Add resistor from wire end row to new empty row
3. Add LED (long leg) from resistor end row to new empty row
4. Wire from LED (short leg) to - rail
5. Wire - rail to pin 38 (Ground)
The Raspberry Pi Pico has a different CPU then your computer.
Your computer has to compile your source code to machine language for a processor it can't run. This is called cross-compiling.
Your cross-compiled program then needs to be transferred to the Pi and run there.
To do this:
1. Unplug your RPi Pico USB cable (either end) if it is plugged in.
2. Hold down the white button on the RPi Pico.
3. Re-connect your RPi Pico with the white button held down.
(Your RPi Pico is now ready to receive your cross-compiled program.)
4. `cargo run`. (Your program is now running on your RPi Pico.)
5. Repeat the above procedure to send and run a new version of your code to your RPi Pico.
https://github.com/dougsummerville/Bare-Metal-Raspberry-PI-Pico/blob/main/baremetal/include/rp2040/pll.h
Let's Get Started
(We are in a new Golden Age for programming!)