The Most Addictive Python and SQL Courses
AI Adoption - Drive Business Value and Organizational Impact
Overview
Coursera Flash Sale
40% Off Coursera Plus for 3 Months!
Grab it
Learn to build a blinking LED program from scratch using embedded Rust on the Raspberry Pi Pico 2 in this 43-minute tutorial. Explore essential embedded systems concepts including bare-metal programming, hardware abstraction layers (HAL), and the no_std environment while moving beyond high-level frameworks like Arduino or MicroPython. Set up an embedded Rust project using Cargo, configure cross-compilation for the ARM Cortex-M33 processor (thumbv8m architecture), and work with the rp235x-hal crate for RP2350 hardware control. Master the essential project files including Cargo.toml for dependency management, .cargo/config.toml for build configuration, memory.x for defining the linker memory map, and main.rs for writing the embedded application. Understand how the cortex-m-rt crate handles startup code and memory layout, how the RP2350's Boot ROM initializes programs, and how Rust's type system provides compile-time safety for GPIO operations. Discover why embedded Rust uses #![no_std] and #![no_main] attributes, create custom panic handlers for bare-metal environments, and control hardware peripherals safely through Rust's ownership system. See how the Pin struct uses generic type parameters to enforce correct GPIO usage at compile time, preventing common embedded programming errors before code runs on hardware. Gain hands-on experience with key Rust concepts including ownership, type safety, and zero-cost abstractions applied to microcontroller development, creating a solid foundation for advanced embedded Rust projects with USB serial communication, interrupts, and complex peripheral interactions.
Syllabus
Intro
Cargo.toml
.cargo/config.toml
memory.x
src/main.rs
Build
Generate UF2 File and Flash
Conclusion
Taught by
Digi-Key