Zephyr System Requirements
SPDX-License-Identifier: Apache-2.0
The Zephyr RTOS shall provide a framework to communicate with a set of hardware architectural services.
As a Zephyr RTOS user I want to be able to easily switch my application to a different MCU architecture (x86, ARM Cortex-M/A, RISCV etc.).
The Zephyr RTOS shall support symmetric multiprocessing on multiple cores.
As a Zephyr RTOS user I want to use Zephyr OS on multi core (SMP-)MCUs/MPUs.
- ZEP-SRS-18-1 Formatted output
- ZEP-SRS-18-2 Floating Point Math Support
- ZEP-SRS-18-3 Boolean Primitives Support
- ZEP-SRS-18-4 Standard Unix time interface
- ZEP-SRS-18-5 Strings support
- ZEP-SRS-18-6 Moving/copying regions of memory
- ZEP-SRS-18-7 I/O based interface
- ZEP-SRS-18-8 C99 integer types
- ZEP-SRS-18-9 Standard System Error Numbers (IEEE Std 1003.1-2017)
- ZEP-SRS-18-10 Document set of Zephyr OS required C library functions in Safety Manual
- ZEP-SRS-18-11 Support external C libraries documentation in Zephyr Safety Manual
The Zephyr RTOS shall support a subset of the standard C library.
As a Zephyr RTOS user I want to have a selection of standard C library implementations e.g. a full extend and a minimal with a smaller footprint or a particular fast executing implementation.
The Zephyr RTOS shall provide a framework for managing device drivers and peripherals.
As a Zephyr RTOS user I want my application to be portable between different MCU architectures (ARM Cortex-M/A, Intel x86, RISCV etc.) and MCU vendors (STM, NXP, Intel, etc.) without having to change the MCU peripherals access.
The Zephyr RTOS shall provide a framework for error and exception handling.
As a Zephyr RTOS user I want errors and exceptions to handled and react according to my applications requirements (e.g. reach/establish the applications safety state).
The Zephyr RTOS shall provide a framework for managing file system access.
As a Zephyr RTOS user I want a posix / c like file system access to store data.
- ZEP-SRS-7-1 Installing static IRQ service routines (ISR).
- ZEP-SRS-7-2 Static IRQ initial status.
- ZEP-SRS-7-3 Installing direct IRQ service routines (ISR).
- ZEP-SRS-7-4 Direct IRQ initial status.
- ZEP-SRS-7-5 Installing dynamic IRQ service routines (ISR).
- ZEP-SRS-7-6 Dynamic IRQ initial status.
- ZEP-SRS-7-7 Uninstalling dynamic IRQ service routines (ISR).
- ZEP-SRS-7-8 Global IRQ disable
- ZEP-SRS-7-9 Global IRQ enable
- ZEP-SRS-7-10 Specific IRQ disable
- ZEP-SRS-7-11 Specific IRQ enable
- ZEP-SRS-7-12 IRQ Enabled status
- ZEP-SRS-7-13 ISR Context status
- ZEP-SRS-7-14 Multi-level interrupts
- ZEP-SYRS-20 Direct ISR, Platform Specific helpers.
The Zephyr RTOS shall provide a framework for interrupt and interrupt service routine management.
As the Zephyr RTOS user I want the Kernel to provide abstracted interfaces to the platform enabling me to implement standard interrupts interrupt service routines without detailed knowledge of the platform architecture and programming model.
- ZEP-SRS-21-1 Dynamic initialization of condition variables
- ZEP-SRS-21-2 Static initialization of condition variables
- ZEP-SRS-21-3 Signal one waiting thread
- ZEP-SRS-21-4 Signal multiple waiting threads
- ZEP-SRS-21-5 Wait on a condition variable
- ZEP-SRS-21-6 Wait timeout on a condition variable
- ZEP-SRS-21-7 Wait timeout occurence
- ZEP-SRS-21-8 Release mutex on wait
- ZEP-SRS-21-9 Unblock a waiting thread
Zephyr RTOS shall support development of direct ISRs by providing platform specific code fragments and factory functions including, minimal header instructions, minimal footer instructions, low power termination, and ISR construction.
As the Zephyr RTOS user I want the Kernel to provide support for implementing standard low latency and low power interrupt service routines without detailed knowledge of the platform architecture and programming model.
The Zephyr RTOS shall provide a framework for logging events.
As a Zephyr RTOS user I want to be able to log application defined events as well as framework exceptions.
The Zephyr RTOS shall support a memory management framework.
As a Zephyr RTOS user I want memory to be allocated and protected to my application threads preventing mistakenly access to foreign memory as far as the hardware allows.
The Zephyr RTOS shall provide an interface to control hardware power states.
As a Zephyr RTOS user I want to be able to control the power mode of the MCU and its peripherals to take advantage of the hardware features and to be able to implement low power or battery driven long life applications.
12. Multi core and SMP
The Zephyr RTOS shall support scheduling of threads on multiple hardware CPUs.
As a Zephyr RTOS user I want Zephyr OS to run on MCUs/CPUs with one or more CPU cores.
The Zephyr RTOS shall provide an interface to assign a thread to a specific CPU.
As a Zephyr RTOS user, I want to be able to control which thread will run on which CPU.
13. Thread Synchronization
The Zephyr RTOS shall provide an interface for managing communication between threads.
As a Zephyr RTOS user I want to able to exchange information between threads in a thread-safe manner guaranteeing data consistence.
- ZEP-SRS-5-1 Counting Semaphore Definition At Compile Time
- ZEP-SRS-5-2 Counting Semaphore Definition At Run Time
- ZEP-SRS-5-4 Initialialization with maximum count value
- ZEP-SRS-5-5 Initial semaphore value
- ZEP-SRS-5-6 Semaphore acquisition mechanism
- ZEP-SRS-5-7 Semaphore acquisition with count greater than zero
- ZEP-SRS-5-8 Semaphore acquisition with zero count
- ZEP-SRS-5-9 Semaphore acquisition timeout
- ZEP-SRS-5-10 Semaphore acquisition timeout error handling
- ZEP-SRS-5-11 Semaphore acquisition no wait error handling
- ZEP-SRS-5-12 Semaphore release
- ZEP-SRS-5-13 Semaphore release
- ZEP-SRS-5-14 Semaphore release with priority inheritance
- ZEP-SRS-5-15 Checking semaphore count
- ZEP-SRS-5-16 Semaphore reset
- ZEP-SRS-5-17 Semaphore acquisitions abort after reset
- ZEP-SRS-5-18 Semaphore Initialization Option Validation
The system shall implement a semaphore synchronization primitive for coordinating access to shared resources among multiple threads.
14. Threads
- ZEP-SRS-2-4 Scheduling a thread based on an event
- ZEP-SRS-1-1 Creating threads
- ZEP-SRS-1-3 Suspending a thread
- ZEP-SRS-1-4 Resuming a suspended thread
- ZEP-SRS-1-5 Resuming a suspended thread after a timeout
- ZEP-SRS-1-6 Deleting a thread
- ZEP-SRS-1-7 Thread states
- ZEP-SRS-1-8 Thread stack objects
- ZEP-SRS-1-9 Thread privileges
- ZEP-SRS-1-11 Thread Options
- ZEP-SRS-1-12 Thread Custom Data
The Zephyr RTOS shall support threads.
As a Zephyr RTOS user, I want to be able to have support for the kernel objects named threads for processing work.
- ZEP-SRS-1-1 Creating threads
- ZEP-SRS-1-3 Suspending a thread
- ZEP-SRS-1-4 Resuming a suspended thread
- ZEP-SRS-1-5 Resuming a suspended thread after a timeout
- ZEP-SRS-1-6 Deleting a thread
- ZEP-SRS-1-7 Thread states
- ZEP-SRS-1-8 Thread stack objects
- ZEP-SRS-1-9 Thread privileges
- ZEP-SRS-1-10 Scheduling multiple threads
- ZEP-SRS-1-11 Thread Options
- ZEP-SRS-1-12 Thread Custom Data
The Zephyr RTOS shall provide a framework for managing multiple threads of execution.
As a Zephyr RTOS user, I want to be able to manage the execute of multiple threads with different priorities.
Threads shall have a priority.
As a Zephyr RTOS user, I want to be able to give my threads different priorities for execution.
- ZEP-SRS-4-1 Timer definition at compile time
- ZEP-SRS-4-2 Timer expiry function
- ZEP-SRS-4-3 Timer stop function
- ZEP-SRS-4-4 Timer definition at run time
- ZEP-SRS-4-5 Timer start
- ZEP-SRS-4-6 Timer stop
- ZEP-SRS-4-7 Timer status
- ZEP-SRS-4-8 Timer status reinitialization
- ZEP-SRS-4-9 Timer thread synchronization
- ZEP-SRS-4-10 Timer next expiration time in system ticks
- ZEP-SRS-4-11 Timer remaining time until expiration in system ticks
- ZEP-SRS-4-12 Timer remaining time until expiration in milliseconds
- ZEP-SRS-4-13 Timer set user data
- ZEP-SRS-4-14 Timer get user data
- ZEP-SRS-4-15 Timer expire functions in interrupt context
The Zephyr RTOS shall provide a framework for managing time-based events.
As a Zephyr RTOS user, I want to start, suspend, resume and stop timers which shall trigger an event on a set expiration time.
Zepyhr shall provide a framework mechanism for tracing low level system operations (NOTE: system calls, interrupts, kernel calls, thread, synchronization, etc.).
As a Zephyr RTOS user, I want to be able to trace different OS operations.
17. Condition Variables
- ZEP-SRS-24-11 Queue definition at compile time
- ZEP-SRS-20-1 Queue definition at compile time
- ZEP-SRS-20-2 Queue definition at run time.
- ZEP-SRS-20-3 Queue enqueue item to the back
- ZEP-SRS-20-4 Queue enqueue item to the front
- ZEP-SRS-20-5 Queue remove item
- ZEP-SRS-20-6 Queue get and dequeue item from front
- ZEP-SRS-20-7 Queue empty check
- ZEP-SRS-20-8 Queue peek item at back
- ZEP-SRS-20-9 Queue peek item at front
- ZEP-SRS-20-10 Queue insert
- ZEP-SRS-20-11 Queue append item list to the back
- ZEP-SRS-20-12 Queue append and empty item list to the back
- ZEP-SRS-20-13 Queue append unique data item
- ZEP-SRS-20-14 Queue implicit memory allocation
The Zephyr RTOS shall provide a framework to synchronize threads based on a condition variable.
18. Queues
The Zephyr RTOS shall implement a queue which can be used to pass data between threads and interrupt service routines.
19. LIFOs
The Zephyr RTOS shall implement a LIFOs which can be used to pass data between threads and interrupt service routines.
20. FIFOs
- ZEP-SRS-24-1 FIFO definition at compile time
- ZEP-SRS-24-2 FIFO cancel waiting thread
- ZEP-SRS-24-3 FIFO enqueue item to the back
- ZEP-SRS-24-4 FIFO implicit memory allocation
- ZEP-SRS-24-5 FIFO append item list to the back
- ZEP-SRS-24-6 FIFO append and empty item list to the back
- ZEP-SRS-24-7 FIFO get and dequeue item from front
- ZEP-SRS-24-8 FIFO empty check
- ZEP-SRS-24-9 FIFO peek item at front
- ZEP-SRS-24-10 FIFO peek item at back
The Zephyr RTOS shall implement FIFOs which can be used to pass data between threads and interrupt service routines.