Zephyr#

Modules, backends, and helpers for the Zephyr RTOS

Pigweed’s Zephyr integration provides a suite of abstractions and helpers designed to make developing C++ applications on Zephyr safer, more robust, and fully compatible with Pigweed’s portable facades.

  • Compile-time lock safety: Support for Clang’s static thread-safety analysis annotations, enabling compile-time detection of data races and incorrect lock ordering.

  • Safe non-recursive mutexes: Enforces strict non-recursive mutex semantics and assertions to detect bugs and prevent deadlocks.

  • Safe callback execution: Routes timer callbacks to delayable work queues running in thread context, enabling race-free synchronous timer deletion.

  • Tokenized logs and asserts: Drastically reduces binary size by tokenizing all assertion and logging statements in both the application and the Zephyr kernel.

Advantages & differences

Learn how Pigweed’s wrappers improve safety, catch bugs at compile-time or runtime, and compare directly with raw Zephyr APIs.

Advantages & differences
Setup

Get started using Pigweed with Zephyr, build the starter project, and run tests.

Setup

Modules#

The following table lists all modules related to Zephyr.

Name

Status

Description

Languages

pw_allocator_zephyr

stable

pw_assert_zephyr

stable

pw_chrono_zephyr

stable

pw_digital_io_zephyr

experimental

C++

pw_env_setup_zephyr

experimental

Zephyr utilities

pw_i2c_zephyr

experimental

Zephyr implementation for pw_i2c

pw_interrupt_zephyr

unstable

pw_log_zephyr

stable

pw_spi_zephyr

stable

pw_sync_zephyr

stable

pw_sys_io_zephyr

stable

pw_thread_zephyr

stable