-
Notifications
You must be signed in to change notification settings - Fork 8
User Guide
Zakaria Madaoui edited this page Jul 24, 2026
·
9 revisions
This guide is for application developers who want to write real-time Rust applications using an existing RTIC distribution.
RTIC is a Rust framework for building event-driven, real-time embedded applications. It uses a set of attributes (#[rtic::app], #[task], #[shared], etc.) to generate code that implements the Stack Resource Policy (SRP) for safe resource sharing between tasks and interrupts.
In this rewrite, the framework is split into three layers:
-
rtic-core— parses the RTIC syntax, runs resource-ceiling analysis, and generates code for tasks, resources,init, andidle. - Compilation passes — independent crates that extend RTIC syntax (e.g., software tasks, automatic core assignment, deadlines-to-priorities).
-
Distributions — target-specific crates that bind the core and selected passes to a particular microcontroller, exposing the final
#[rtic::app]macro.
As an application author, you pick a distribution, write an RTIC application using the supported syntax, and let the macro do the rest.
- Tasks — units of work that can be triggered by interrupts or by other tasks.
- Shared resources — data protected by the SRP ceiling protocol.
- Priorities — RTIC assigns ceilings based on task priorities so that higher-priority tasks can preempt safely.
- Init — the startup task that runs once and returns the initial shared resources.
- Idle — the loop that runs when no task is active.
- Getting Started — build your first RTIC application.
- Syntax Reference — learn the RTIC attributes supported by the core and software-task passes.
- Supported Distributions — pick the right distribution for your target hardware.