Rust Embedded is a course designed to help Rust developers get up and running with embedded development. Rust is often associated with safety, but in the embedded world, sometimes those safety mechanisms are in conflict with typical embedded system development. The embedded world has its own tooling and concerns. This course covers tools and techniques for developing embedded software in Rust. The approach is driven by best practices and the preservation of Rust’s many safety-oriented mechanisms. Upon completion, engineers will be ready to build high quality embedded software in Rust with support for improved safety over traditional languages.
Day one moves from environment setup and no_std fundamentals into building and debugging programs with QEMU and the STM32F3DISCOVERY board. It then covers peripherals through the borrow checker and singletons. The day closes by applying static guarantees with typestate programming and zero-cost abstractions. Day two focuses on portability through hardware abstraction layers and concurrency techniques such as interrupts, critical sections, and atomic operations. It also covers collection types suited to constrained memory and design patterns drawn from the Rust API guidelines. Day three rounds out the course for engineers coming from C, covering C/C++ interoperability and techniques for optimizing code for speed and size. It closes with a look at building WASM applications with Rust.
Lab work for this course uses the STMicroelectronics STM32F3DISCOVERY development board based on the ARM Cortex-M architecture. The board and Mini-USB cable are included with the course. Attendees must provide their own laptops.
Who Should Attend
(Embedded Systems) Developers
What Attendees Will Learn
Upon completing Rust Embedded, attendees will be able to:
- Set up an embedded Rust development environment, including no_std
- Build and debug embedded Rust programs using QEMU and STM32
- Work with peripherals using the borrow checker and singletons
- Apply static guarantees using typestate programming and zero cost abstractions
- Apply hardware abstraction layers (HAL) for portability
- Apply concurrency techniques, including interrupts, mutexes, and critical sections
- Use Rust collections and manage memory in embedded systems
- Apply embedded Rust design patterns and API guidelines
- Apply C/C++ interoperability techniques in embedded Rust
- Optimize embedded Rust for speed and size
- Build WASM applications with Rust
Prerequisites
Attendees must have taken RX-M’s Rust Introduction or Foundation course or have equivalent knowledge. Familiarity with developing and debugging embedded systems in another language such as C or C++ is highly recommended but not absolutely required.