chapter one

1 The Foundations of embedded Rust development

 

This chapter covers

  • Why embedded Rust is timely for dependable firmware.
  • Rust from reset to main().
  • Using Rust’s core crate with an no_std build (no operating system).
  • Platform preview: Cortex-M focus with selected RISC-V examples.
  • What you need to follow along.

1.1 Why embedded Rust? Benefits and adoption

1.1.1 Compile-time safety and reliability

1.1.2 Constraints, Determinism, and Performance

1.1.3 How Rust compares to other approaches

1.2 Rust execution sequence: From reset to main

1.2.1 Power on and reset (steps 1 to 4)

1.2.2 Minimal runtime setup (step 5)

1.2.3 Transfer to user code (step 6)

1.2.4 Exceptions and interrupts at a glance (step 7)

1.3 What is non-standard library Rust?

1.3.1 What no_std excludes and what core provides

1.3.2 Entry and panic requirements

1.3.3 What minimal runtime crates initialize

1.4 Core Rust features in embedded context

1.4.1 Ownership and borrowing for hardware resources

1.4.2 The singleton pattern for peripherals

1.4.3 Type-enforced hardware correctness

1.4.4 Concurrency preview: Interrupts, sharing, and async

1.5 Scope and audience: architectures and examples

1.5.1 Platform focus

1.5.2 What transfers across architectures

1.5.3 What is out of scope

1.6 How this book teaches

1.6.1 Teaching strategy