**Bare-Metal Rust on the nRF52840** is a 10-day hands-on guide for embedded
engineers who want to understand what their microcontroller is actually doing —
without an RTOS in the way.
Each day introduces one concept, one working example, and four practice tasks.
You start by flashing a minimal program that does nothing (proving the toolchain
works), and finish by writing a multi-task concurrent application using Rust's
RTIC framework — with compile-time proof that there are no data races.
**What you will build:**
- A PAC-level LED blinker using direct register writes
- Type-safe GPIO with the nrf52840-hal's type-state pattern
- Accurate millisecond delays with the SysTick timer and HFXO crystal
- RTT logging with defmt — zero-allocation, zero-UART, streams through the
debug probe
- Hardware interrupts via the GPIOTE peripheral, using Rust's ownership model
to share state safely between main and the ISR
- A UART echo server over the DK's J-Link OB virtual COM port
- Independent hardware timers driving multiple LEDs at different frequencies
- A full RTIC application with hardware tasks, local resources, and shared
state protected by the priority-ceiling protocol
**Who this is for:**
- Embedded C engineers who want to evaluate Rust for their next project
- Rust developers who have never written firmware before
- Anyone who has used Zephyr or FreeRTOS and wants to understand what is
underneath the scheduler
**What you need:**
- A Nordic nRF52840 DK (~$40 USD) and a USB cable
- A Linux, macOS, or Windows PC
- Basic Rust familiarity (ownership, borrowing, structs) — no embedded
experience required
**Hardware:** Nordic nRF52840 DK (`nrf52840dk/nrf52840`)
**Toolchain:** Rust stable, probe-rs, nrf52840-hal 0.16, RTIC 1.1