Zephyr 3.4 released

Zephyr 3.4 is now released . Project Zephyr is a scalable real-time operating system (RTOS) that supports multiple hardware architectures, is optimized for resource-constrained devices, and is built with security in mind. Zephyr OS is based on a small kernel designed for resource-constrained systems: from simple embedded environmental sensors and LED wearables to complex smart watches and IoT wireless gateways.

According to the announcement, this release demonstrates the widespread use of Zephyr in various types of applications. For example, more and more companies are using Zephyr to build embedded controllers – microcontroller-driven applications that enable computers to handle low-level system tasks – and some improvements in the new version 3.4 can help simplify development in this area: such as Added support for new APIs and drivers for NVMe drives, SMBus peripherals, and real-time clocks.

Zephyr 3.4 also introduces several improvements to its built-in testing framework (Twister), making it possible to write more comprehensive test cases than in previous versions. Now, developers can use popular third-party testing frameworks, such as pyTest, GoogleTest, and RobotFramework, to write end-to-end test cases that run on real or emulated hardware, and can connect to, for example, IoT servers for testing.

Added peripheral support

Auxiliary Text Display

Secondary displays are text-based displays that display text, numbers, or alphanumerics with a simple interface. You'll generally want to interact with these displays by sending characters, not pixels. The new  Auxiliary Text Display API  can get you there. There are already drivers for common secondary displays (from Hitachi, Noritake, Jinghua, etc.). Sample code can be found here .

NVMe disk

NVMe (Non-Volatile Memory Express non-volatile memory fast access interface) is a high-performance storage protocol designed for NAND flash memory (such as: solid-state drive SSD, M.2 card, etc.).

NVMe controllers and disks are supported since version 3.4, and are fully integrated with Devicetree for configuration and customization.

Real Time Clock

A real-time clock is a low-power, usually battery-powered device that keeps track of time in real time, and the RTC continues to function when the main system is turned off. Zephyr 3.4  adds support for RTCs  , providing a consistent, hardware-independent way to interact with them.

In addition to basic clock getting or setting interactions, the API also supports setting an alarm or calibrating the clock, if these functions are supported by the underlying hardware. Drivers are already available for popular RTC chips such as NXP PCF8523 and Motorola MC146818.

Reserved memory area (Retained memory)

The new Retained memory API enables applications to read and write data to certain reserved memory areas (for example, uninitialized portions of RAM), or to devices that retain information when the device starts. These APIs are useful when one does not want to use non-volatile storage, for example, to share information between different applications or within a single application, or to not lose state information after a device restart is a good choice.

SMBus

SMBus (System Management Bus System Management Bus) is a two-wire bus derived from I²C. It is often used for communication between motherboards and low-bandwidth devices, such as obtaining information from temperature sensors, battery fuel gauges, etc.

Starting with Zephyr 3.4, the new SMBus subsystem allows developers to manipulate SMBus controllers and devices within their applications.

input subsystem

The input subsystem allows input devices to send input events to applications through the API

It provides a higher level abstraction for handling input events like key/button pressed, touchscreen pressed etc. This decouples the GUI from the underlying hardware input, making GUI development easier.

This new subsystem also provides a great opportunity for developers to investigate how Zephyr's built-in state machine framework can be used to handle more complex interaction scenarios.

reserved memory area subsystem

To complement support for reserved memory zones , a new reserved memory zone subsystem has been integrated with the device tree, making it easy to configure and customize how data is preserved, including creating multiple partitions, verifying data integrity via checksums, or handling devices Special cases for restarting, such as making it run a different application.

Twister testing framework improvements

Twister, Zephyr's own testing framework, is widely used internally (dogfooding) to ensure that Zephyr itself is fully tested. In fact, for every pull request submitted to the Zephyr repository (assuming it has code changes), our CI task triggers Twister and runs thousands of unit tests.

Zephyr 3.4 adds many improvements to Twister, making it more suitable for complex, end-to-end, functional testing. Developers can now use popular third-party testing frameworks such as pyTest, GoogleTest, and RobotFramework to write tests that run on real or simulated hardware, and can connect to networks such as IoT servers.

Zephyr SDK update

It is recommended to update to the latest version of Zephyr SDK (0.16.1) . One of the main advantages of the Zephyr SDK is that it gives you one-stop access to all toolchains and host tools, which is very convenient for your daily Zephyr development.

The size of the SDK has grown over the years, and this latest version has been reduced in size as it now uses tar.xz (Linux/macOS) and 7zip (Windows) for packaging instead of the previous .tar.gz and .zip half (so the download speed becomes 2 times faster ).

Snippets

Newly added " snippets " help simplify all common setups (e.g. configuration files, Devicetree overlays) that may need to be reused across various projects.

A typical usage scenario is to package all your favorite debugging options (e.g. enabling shell, custom log levels, etc.) into a snippet so you can easily detect applications that need to be troubleshooted, also changing hardware defined levels ( For example, to enable Zephyr shell via USB interface).

Here are other noteworthy API introductions

Memory Barriers

A new API for data memory barriers has been introduced . Data barriers are essentially a way to kindly tell your processor: "Hey, I know you like to reorder tasks for efficiency, but these specific memory operations need to happen in the exact order I gave them!". This is especially useful in symmetric multiprocessor (SMP) scenarios, but may also be required in multithreaded applications or when accessing hardware asynchronously.

The new barrier API provides a more consistent way to implement synchronization fences across all processor architectures.

New features in Bluetooth 5.4 (but not just Bluetooth 5.4!)

Bluetooth Core Specification Version 5.4 was released on February 7 this year, and this new Zephyr version already supports all the new features of this standard version, namely:

  • Encrypted Advertising Data (EAD) , which allows data to be advertised securely in Bluetooth LE advertising packets;
  • Periodic Advertising with Responses (PAwR) , a feature that allows Bluetooth low energy devices to communicate energy-efficiently and bidirectionally in massive one-to-many topologies. Combined with EAD, this could be very useful for applications such as electronic shelf labels;

Other notable changes to Bluetooth include support for:

  • Common Audio Profile (CAP) unicast;
  • Telephony and Media Audio Profile (TMAP) — Bluetooth is especially popular for all things telephony, so it's good to see initial Bluetooth LE Telephony and Media Audio Profile (TMAP) support has been added ;
  • Mesh  - Added support for latest working drafts of Mesh 1.1, Mesh Binary Large Object Transfer Mode 1.0, and Mesh Device Firmware Update Model 1.0 Experimental support.

New development board and driver

  • Compared with the previous version, it supports more than 30 new development boards , including Arduino GIGA R1 WiFi, Seeed Studio's Wio Terminal and XIAO BLE, ESP32-S3 development kit, etc.
  • With the addition of drivers for dozens of sensors (environmental sensors, inertial measurement units, current sensors, etc.), Zephyr now not only natively supports over 150 sensors, but is often tightly integrated with the Zephyr stack, for example leveraging its power management features.

See the update announcement for details .

Guess you like

Origin www.oschina.net/news/246229/zephyr-3-4-released