Zephyr (operating system): Difference between revisions

Content deleted Content added
Introiboad (talk | contribs)
No edit summary
m removed weasel words
Tags: Visual edit Mobile edit Mobile web edit Advanced mobile edit
 
(138 intermediate revisions by 50 users not shown)
Line 1:
{{Short description|Real-time operating system}}
{{Infobox OS
| name = Zephyr
| logo = Zephyr RTOS logo 2015.svg
| logo = <!-- filename only; no wikilink, Image:/File: -->
| logo size =
| logo caption = Zephyr Project = logo
| logo alt =
| screenshot = <!-- filenameFilename only; no wikilink, Image:/ or File: -->
| screenshot size =
| screenshot alt =
| caption =
| developer = [[Linux Foundation]],<br />[[Wind River Systems]]
| family = [[Real-time operating system]]s
| working state = Current
| source model = [[Open source model|Open source]]
| released = {{Start date and age|2016|0207|1726|df=yes}}<ref name="zephyr-project" />
| latest release version = 4.2.0
| discontinued = <!-- DO NOT use for articles about releases of operating systems -->
| latest release date = {{Start date and age|2025|07|19|df=yes}}<ref>{{cite web |url= https://github.com/zephyrproject-rtos/zephyr/releases/tag/v4.2.0 |title= Zephyr v4.2.0|website= [[GitHub]]}}</ref><ref>{{cite web |url=https://www.zephyrproject.org/zephyr-rtos-4-2-now-available-introduces-renesas-rx-support-usb-video-class-and-more|title= Zephyr RTOS 4.2 Now Available|website= [[Zephyr blog]]}}</ref>
| latest release version = 1.12.0
| marketing target = [[Internet of things]], [[embedded system]]s
| latest release date = {{Start date and age|2018|06|11|df=yes}}<ref>{{cite web |url= https://github.com/zephyrproject-rtos/zephyr/releases/tag/zephyr-v1.10.0 |title= Zephyr v1.10.0 |publisher=}}</ref>
| programmed in = [[C (programming language)|C]]
| latest preview version = 1.12.99
| language = English
| latest preview date = {{Start date and age|2018|06|11|df=yes}}
| update model = <!-- APT, Windows Update, etc. -->
| marketing target = [[Internet of things]]
| package manager = <!-- dpkg, rpm, Windows installer, etc. -->
| programmed in =
| supported platforms = [[ARM architecture|ARM]] ([[Cortex-M]], [[ARM Cortex-R|Cortex-R]], [[Cortex-A]]), [[ARC (processor)|ARC]], [[MIPS architecture|MIPS]], [[Nios II]], [[RISC-V]], [[Tensilica|Xtensa]], [[SPARC]], [[x86]], [[x86-64]]
| language = English
| kernel type = [[Microkernel]] (pre-v1.6)<ref name="NanoMicrokernel"/><ref name="Monolithic1"/><ref name="Monolithic2"/><br />[[Monolithic kernel|Monolithic]] (v1.6+)<ref name="Monolithic1"/><ref name="Monolithic2"/>
| update model = <!-- APT, Windows Update, etc. -->
| userland =
| package manager = <!-- dpkg, rpm, Windows installer, etc. -->
| ui =
| supported platforms = [[ARM architecture|ARM]] ([[ARM Cortex-M0|Cortex-M0]], [[ARM Cortex-M3|Cortex-M3]], [[ARM Cortex-M4|Cortex-M4]]), [[x86]], [[ARC (processor)|ARC]], [[RISC-V]], [[Nios II]], [[Tensilica|Xtensa]]
| license = [[Apache License|Apache 2.0]]
| kernel type = [[Monolithic|Monolithic kernel]]
| preceded by = Wind River Rocket
| userland =
| ui succeeded by =
| other articles =
| license = [[Apache License 2.0|Apache 2.0]]
| preceded by =
| succeeded by =
| website = {{URL|www.zephyrproject.org}}
| other articles =
}}
'''Zephyr''' ({{IPAc-en|ˈ|z|ɛ|f|_|ə|r}}) is a small [[real-time operating system]] (RTOS)<ref>{{Cite news|url=http://linuxgizmos.com/zephyr-a-tiny-open-source-iot-rtos/|title=Meet Linux's little brother: Zephyr, a tiny open-source IoT RTOS|date=2016-02-17|work=LinuxGizmos.com|access-date=2018-02-23|language=en-US}}</ref> for connected, resource-constrained and [[embedded device]]s (with an emphasis on [[microcontroller]]s) supporting multiple architectures and released under the [[Apache License]] 2.0. Zephyr includes a [[Kernel (operating system)|kernel]], and all components and [[Library (computing)|libraries]], [[device driver]]s, [[protocol stack]]s, [[file system]]s, and [[firmware update]]s, needed to develop full [[application software]].<ref name="docs.zephyrproject.org">{{Cite web |url=https://docs.zephyrproject.org/latest/introduction/ |title=Zephyr Project documentation: Introduction |language=en}}</ref>
 
It is named after [[Zephyrus]], the ancient Greek god of the west wind.<ref>{{Cite web|url=https://docs.zephyrproject.org/latest/develop/west/index.html#west-name|title=West (Zephyr's meta-tool) — Zephyr Project Documentation|website=docs.zephyrproject.org}}</ref>
'''Zephyr''' is a small [[real-time operating system]]<ref>{{Cite news|url=http://linuxgizmos.com/zephyr-a-tiny-open-source-iot-rtos/|title=Meet Linux's little brother: Zephyr, a tiny open-source IoT RTOS|date=2016-02-17|work=LinuxGizmos.com|access-date=2018-02-23|language=en-US}}</ref> for connected, resource-constrained devices supporting multiple architectures and released under the [[Apache License 2.0]]. A BSD licensed fork occurs in the [[Arduino]] 101 software source package from Intel.<ref name="1.0.0-release-notes">[https://www.zephyrproject.org/content/zephyr-kernel-v100-release-notes Zephyr Kernel v1.0.0 Release Notes]</ref>
 
== History ==
InZephyr Novemberoriginated 2015,from itVirtuoso wasRTOS originallyfor developed[[digital assignal Rocketprocessor]]s (DSPs).<ref name="zp19">{{Citecite web |last=Clarysse |first=Ivo |date=November 22, 2019 |url=httphttps://windriverwww.com/productszephyrproject.org/zephyr-an-operating-systems/rocketsystem-for-iot/ |title=MCUZephyr Commercial FreeAn RTOSOperating System for smallIoT embedded edge devices {{!}} Rocket|website=windriver.com|language=en|access-date=2018-02-23Zephyr Project}}</ref><ref name="eej"/> In 2001, [[Wind River Systems]] acquired Belgian software company Eonic Systems, the developer of Virtuoso. In November 2015, Wind River Systems renamed the [[operating system]] to ''Rocket'', made it open-source and royalty-free.<ref name="eej">{{Cite webnews |last=Turley |first=Jim |date=25 November 2015 |url=http://www.eejournal.com/archives/articles/20151125-windriver/ |title=Wind River Sets Rocket RTOS Onon Free Trajectory – EEJournal|website=www.eejournal.comElectronic Engineering Journal |publisher=Techfocus Media |language=en-US |access-date=2018-02-23}}</ref><ref>https://software.intel.com/en-us/iot/rocket</ref> kernelCompared byto [[Wind River's Systemsother RTOS, [[VxWorks]], Rocket had much smaller memory needs, especially suitable for [[Internetsensors ofand things]]single-function (IoT)embedded devices.<ref name="patel-zephyr-project">NiheerRocket Patel:could [http://blogs.windriver.com/wind_river_blog/2016/02/wind-river-welcomes-linux-foundations-zephyr-project.htmlfit Windinto Riveras Welcomeslittle Linuxas Foundation’s4 ZephyrKB of Project]memory, Windwhile RiverVxWorks Systems,needed 17200 FebruaryKB 2016or more.<ref name="eej"/ref>
 
In February 2016, ZephyrRocket became a hosted collaborative project of the [[Linux Foundation]] under the name ''Zephyr''.<ref name="zp19"/><ref name=":0">{{Cite news |last=Guerrini |first=Federico |date=2016-02-19 |url=https://www.forbes.com/sites/federicoguerrini/2016/02/19/the-internet-of-things-goes-open-source-with-linux-foundations-zephyr-project/ |title=The Internet of Things Goes Open Source with Linux Foundation's Zephyr Project|last=Guerrini|first=Federico|date=2016-02-19 |work=|newspaper=[[Forbes]] |access-date=2017-01-12|via=}}</ref><ref name="zephyr-project">Zephyr{{Cite Project:web [|url=https://www.zephyrproject.org/news/linux-foundation-announces-project-build-real-time-operating-system-internet-things-devices |title=The Linux Foundation Announces Project to Build Real-Time Operating System for Internet of Things Devices], |author=<!-- Human name. --> |date=17 February 2016 |website=Zephyr Project |publisher=Linux Foundation |archiveurl=https://web.archive.org/web/20160310073146/https://www.zephyrproject.org/news/linux-foundation-announces-project-build-real-time-operating-system-internet-things-devices |archivedate=2016-03-10}}</ref> Wind River Systems contributed the Rocket kernel to Zephyr, but still provided Rocket to its clients, charging them for the cloud services.<ref name="patel-zephyr-project"/><ref name="eej"/> As a result, Rocket became "essentially the commercial version of Zephyr".<ref name="patel-zephyr-project">{{Cite web |url=http://blogs.windriver.com/wind_river_blog/2016/02/wind-river-welcomes-linux-foundations-zephyr-project.html |title=Wind River Welcomes Linux Foundation's Zephyr Project |last=Patel |first=Niheer |date=17 February 2016 |website=Wind River Systems |access-date=18 February 2016 |archive-date=21 February 2016 |archive-url=https://web.archive.org/web/20160221003830/http://blogs.windriver.com/wind_river_blog/2016/02/wind-river-welcomes-linux-foundations-zephyr-project.html |url-status=dead }}</ref>
 
Since then, early members and supporters of Zephyr include [[Intel]], [[NXP Semiconductors]], [[Synopsys]], [[Linaro]],<ref>{{Cite webnews |last=Osborne |first=Charlie |date=2016-02-19 |url=httphttps://www.zdnet.com/article/the-linux-foundations-zephyr-project-building-an-operating-system-for-iot-devices/ |title=The Linux Foundation's Zephyr Project: A custom operating system for IoT devices|last=Osborne|first=Charlie|date=2016-02-19 |website=[[ZDNet]] |publisher=[[CBS Interactive]] |access-date=2017-01-12}}</ref>, runtime.io,[[Texas DeviceToneInstruments]], [[Nordic Semiconductor]], [[Oticon]], and [[OticonBose Corporation|Bose]].<ref>{{Cite web |url=https://www.zephyrproject.org/#project-members/|title="Zephyr Project Members"|website=Zephyr Project}}</ref>
 
{{As of|2025|01}}, Zephyr had the largest number of contributors and commits compared to other RTOSes (including [[Mbed]], [[RT-Thread]], [[NuttX]], and [[RIOT (operating system)|RIOT]]).<ref>{{Cite web |url=https://github.com/zephyrproject-rtos/zephyr |title=Zephyr GitHub page |website=[[GitHub]] |date=January 30, 2025}}</ref>
== Features ==
 
==Features==
The Zephyr kernel is small and designed for use on resource-constrained systems: from simple embedded environmental sensors and [[light emitting diode]] (LED) wearables to sophisticated smart watches and IoT wireless gateways.
Zephyr intends to provide all components needed to develop resource-constrained and embedded or microcontroller-based applications. This includes:<ref name="docs.zephyrproject.org"/>
* A small kernel
* A flexible configuration and build system for compile-time definition of required resources and modules
* A set of protocol stacks ([[IPv4]] and [[IPv6]], [[Constrained Application Protocol]] (CoAP), [[OMA LWM2M|LwM2M]], [[MQTT]], [[802.15.4]], [[Thread (network protocol)|Thread]], [[Bluetooth Low Energy]], [[CAN bus|CAN]])
* A virtual file system interface with several flash file systems for non-volatile storage ([[FatFs]], LittleFS, NVS)
* Management and device [[firmware update]] mechanisms
 
===Configuration and build system===
The kernel offers several features that distinguish it from other small OSes:
Zephyr uses [[Kconfig]] and [[devicetree]] as its configuration systems, inherited from the [[Linux kernel]], but implemented in [[Python (programming language)|Python]] programming language for portability to non-[[Unix]] operating systems.<ref>{{Cite web |url=https://github.com/zephyrproject-rtos/zephyr/tree/master/scripts |title=scripts/ folder |website=[[GitHub]] |date=12 May 2020}}</ref> The RTOS build system is based on [[CMake]], which allows Zephyr applications to be built on [[Linux]], [[macOS]], and [[Microsoft Windows]].<ref>{{Cite web |url=https://docs.zephyrproject.org/latest/application/ |title=Application Development: Zephyr Project Documentation |website=Zephyr Project}}</ref>
 
===''West'' utility tool===
* [[Single address space operating system|Single address-space]]
Zephyr has a general-purpose tool called ''West'' for managing repositories, downloading programs to hardware, etc.
* Highly configurable
* Resources defined at compile-time
* Minimal error checking
* Development services
 
=== Security Kernel===
Early Zephyr kernels used a dual [[Microkernel|nanokernel plus microkernel]] design.<ref name="NanoMicrokernel">{{Cite web |last=Wasserman |first=Shawn |date=February 22, 2016 |url=https://mobile.engineering.com/amp/11530.html |title=How Linux's IoT Zephyr Operating System Works |website=Engineering.com}}</ref><ref name="Monolithic1">{{Cite web |last=Helm |first=Maureen |date=December 15, 2016 |url=https://www.zephyrproject.org/announcing-zephyr-os-v1-6-0/ |title=Announcing Zephyr OS v1.6.0 |website=Zephyr Project}}</ref><ref name="Monolithic2">{{Cite web |last=Wong |first=William G. |date=July 6, 2017 |url=https://www.electronicdesign.com/technologies/embedded-revolution/article/21805266/zephyr-a-wearable-operating-system |title=Zephyr: A Wearable Operating System |website=[[Electronic Design]]}}</ref> In December 2016, with Zephyr 1.6, this changed to a [[monolithic kernel]].<ref name="Monolithic1"/><ref name="Monolithic2"/>
A group is dedicated to maintaining and improving the security.<ref>{{Cite web|url=http://www.techrepublic.com/article/linux-foundation-announces-zephyr-project-an-open-source-iot-operating-system/|title=Linux Foundation announces Zephyr Project, an open source IoT operating system - TechRepublic|last=Wallen|first=Jack|date=2016-02-18|website=[[TechRepublic]]|publisher=[[CBS Interactive]]|access-date=2017-01-12}}</ref> Also being owned and supported by a community means the eyes of the world's open source developers are vetting the code, which significantly increases Zephyr security.<ref name=":0" />
 
The kernel offers several features that distinguish it from other small OSes:<ref name="docs.zephyrproject.org"/>
=== Single address-space ===
* [[Single address space operating system|Single address space]]
* Multiple scheduling algorithms
* Highly configurable and modular for flexibility, with resources defined at compile-time
* [[Memory protection unit]] (MPU) based protection
* [[Asymmetric multiprocessing]] (AMP, based on OpenAMP) and [[symmetric multiprocessing]] (SMP) support
 
===Security===
Combines application-specific code with a custom kernel to create a monolithic image that gets loaded and executed on a system’s hardware. Both the application code and kernel code execute in one shared address space.
A group is dedicated to maintaining and improving the security.<ref>{{Cite news |last=Wallen |first=Jack |date=2016-02-18 |url=http://www.techrepublic.com/article/linux-foundation-announces-zephyr-project-an-open-source-iot-operating-system/ |title=Linux Foundation announces Zephyr Project, an open source IoT operating system |website=[[TechRepublic]] |publisher=[[CBS Interactive]] |access-date=2017-01-12}}</ref> Also, being owned and supported by a community means the world's open source developers are vetting the code, which significantly increases security.<ref name=":0" />
 
=== Highly configurable ===
 
Allows an application to incorporate only the abilities it needs, as needed, and to specify their quantity and size.
 
=== Resources defined at compile-time ===
 
Requires all system resources be defined at [[compile time]], which reduces code size and increases performance.
 
=== Minimal error checking ===
 
Provides minimal run-time error checking to reduce code size and increase performance. An optional error-checking infrastructure is provided to assist in debugging during application development.
 
=== Development services ===
 
The development services offer several familiar services for development, including:
# Multi-threading services for both priority-based, non-preemptive cooperative threads and priority-based, preemptive threads with optional round robin time-slicing.
# Interrupt services for both compile-time and run-time registration of interrupt handlers.
# Inter-thread synchronization services for binary semaphores, counting semaphores, and mutex semaphores.
# Inter-thread data passing services for basic message queues, enhanced message queues, and byte streams.
# Memory allocation services for dynamic allocation and freeing of fixed-size or variable-size memory blocks.
# Power management services such as tickless idle and an advanced idling infrastructure.
 
==See also==
* [[Embedded operating system]]
 
==References==
{{Reflist}}
 
== External links ==
*{{Official website|www.zephyrproject.org}}
 
{{Real-time operating systems}}
{{Linux Foundation}}
{{Microkernel}}
 
[[Category:ARM operating systems]]
Line 101 ⟶ 84:
[[Category:Free software operating systems]]
[[Category:Linux Foundation projects]]
[[Category:Microkernel-based operating systems]]
[[Category:Operating system stubs]]
[[Category:Real-time operating systems]]
[[Category:Software using the Apache license]]
[[Category:IA-32 operating systems]]
[[Category:X86-64 operating systems]]
[[Category:MIPS operating systems]]