Skip to content

Releases: open-vela/docs

openvela trunk-5.4

06 Feb 06:53

Choose a tag to compare

openvela trunk-5.4

[ English | 简体中文 ]

I. Overview

openvela has been dedicated to introducing support for more chips, enhancing system real-time communication capabilities, and significantly improving system robustness, storage functionality, and debuggability. This release focuses on enhancements around the following core themes:

  • Hardware Ecosystem Expansion: Added support for Infineon AURIX™ TC4, Flagchip MCU, and QEMU-R52 SIL platforms**, broadening the scope of platform applicability.
  • System Kernel Hardening: Achieved collaborative operation of SMP and PM, introduced MPU-based thread stack protection and RPC framework refactoring**, making the system safer and more stable.
  • Key Capabilities Integration: Added SocketCAN and Ethernet protocol stacks; introduced the highly reliable NVS2 storage solution**.
  • Developer Experience Optimization: Provided low-overhead FDX real-time tracing tools and multiple LVGL application examples, lowering the barrier for development and debugging.

II. Major New Features & Enhancements

1. Platform Support

  • Added support for Infineon AURIX™ TriCore™ TC4 chips
  • Added support for Flagchip MCUs
  • Added Cortex-R52 core support under QEMU platform, supporting Vector SIL platform
  • Resolved compilation issues for nuttx boards, better supporting native nuttx boards platforms

2. Kernel & Security

  • Power Management (PM) & Symmetric Multi-Processing (SMP): Achieved simultaneous enablement of SMP and PM functions, and completed functional verification on the qemu-armv8a platform, covering basic PM functions and ostest base cases.

  • RPC

    • Framework Refactoring: Refactored the RPC framework to possess greater versatility, enabling cross-core communication capabilities for other VirtIO devices.
    • Functional Enhancements for Rptun/Rpmsg: Introduced a multi-priority mechanism to meet the real-time needs of automotive scenarios, and fixed issues from functional safety code scans.
  • Memory Management Enhancements: Implemented Task-independent Heap space, now supported by libraries like libdbus.

  • Binder Message Mechanism: Integrated Binder server/client fds into the libuv event loop, handling messages via callbacks, achieving unified management with other modules.

  • Added Rpmsg Battery & Gauge drivers.

  • Inter-thread Isolation Protection Mechanism: The kernel now supports thread stack protection based on the hardware Memory Protection Unit (MPU). When a thread experiences a stack overflow, this mechanism triggers a hardware exception, preventing it from corrupting other threads' stack spaces or critical data.

  • Code Quality: Completed multiple static code issue fixes, improving the overall quality of the code base.

3. Communication

  • Added SocketCAN and Ethernet Support: Introduced a CAN communication framework following standard Socket APIs. Users can now use standard interfaces like socket(), bind(), send(), recv() for CAN message transmission and filtering.
  • WebSocket Function Enhancement: Added default certificate support for the WebSocket Feature, simplifying the secure connection establishment process.

4. Storage

Added NVS2 (Non-Volatile Storage v2): Integrated a brand-new, highly reliable NVS2 storage solution. This storage solution is deeply optimized for embedded Flash media, supporting wear leveling, power-loss safety, and data encryption.

5. Debugging & Diagnostics

Added FDX-based Real-time Trace Function: Implemented a low-intrusion real-time tracing tool based on the FDX (Fast Debug eXchange) protocol. It can capture and export high-precision system events, such as task switching, interrupt response, semaphore operations, etc., with extremely low system overhead.

6. Application Examples

  • Added Breakout Game: A touchscreen breakout game developed based on openvela and LVGL, which has implemented basic game logic, added image assets, and implemented impact sound effects.
  • Added Virtual Pet application: An interactive demo program based on the LVGL graphics library, simulating the process of raising a digital pet. Users can care for the virtual pet through operations like feeding, giving water, exercise, and rest to improve its mood and level.
  • Snake Game: An automatic Snake game implemented using the LVGL graphics library.
  • Electronic Wooden Fish: Based on the openvela nxaudio service and the upper-layer LVGL UI framework, implementing a complete interaction link containing responsive layout and secure resource management, realizing an application showcase with smooth animation effects, secure resource management, and a good user experience.

7. Development

Ubuntu Environment VS Code Plugin Support: Support installing openvela VS Code plugin in Ubuntu environment, achieving full-process support from project creation, compilation and building, system debugging to application development, significantly improving development efficiency. (openvela VS Code Plugin Usage Guide)

8. Emulator Runtime Parameter Extensions

  • emulator.sh adds -keep parameter support:

    If emulator.sh supports multi-instance configuration, you can access an instance with a specified name via the -keep parameter (creating it if it doesn't exist), and relevant contexts will not be deleted when that instance exits.

    # Usage
    cp cmake_out/vela_goldfish-arm64-v8a-ap/nuttx* cmake_out/vela_goldfish-arm64-v8a-ap/vela_* cmake_out/vela_goldfish-arm64-v8a-ap/advancedFeatures.ini nuttx/
    
    ./emulator.sh vela -keep -no-window
    
    # Test example: create a test file in /data directory and write content
    nsh> echo test > /data/test
    nsh> echo "openvvela qemu keep test" >> /data/test
    nsh> quit
    
    # Exit emulator and re-enter, the previously written content is still preserved
    ./emulator.sh vela -keep -no-window
    nsh> cat /data/test
    test
    openvela qemu keep test
  • emulator.sh adds support for using Hostfs function, default support using 9pfs, effect as follows:

    goldfish-armv8a-ap> df -h
        Filesystem      Size      Used  Available Mounted on
        binfs             0B        0B         0B /bin
        fatfs           255M       78M       177M /data
        romfs          1152B     1152B         0B /etc
        hostfs            0B        0B         0B /host
        procfs            0B        0B         0B /proc
        v9fs            878G      626G       252G /share
        romfs           512B      512B         0B /system
        tmpfs             6K        1K         5K /tmp

    Usage:

    # Usage
    cp cmake_out/vela_goldfish-arm64-v8a-ap/nuttx* cmake_out/vela_goldfish-arm64-v8a-ap/vela_* cmake_out/vela_goldfish-arm64-v8a-ap/advancedFeatures.ini nuttx/
    
    ./emulator.sh vela

openvela trunk-5.2

18 Sep 07:46

Choose a tag to compare

openvela trunk-5.2

[ English | 简体中文 ]

I. Kernel

Processor Architecture Support

The openvela kernel provides broad hardware platform compatibility, offering a solid foundation for a diverse range of embedded devices.

  • CPU Architectures: Comprehensive support for mainstream and specialized processor architectures, including:

    • ARM
    • ARM64
    • RISC-V
    • x86 / x86-64
    • Xtensa
    • MIPS
    • Tricore
    • Renesas
    • Sparc
    • Z16
    • Z80
  • Multi-core Processors (SMP): Built-in support for Symmetric Multiprocessing (SMP) delivers efficient processor scheduling and parallel processing capabilities to meet the demands of high-performance applications.

Core System Features

The openvela kernel is based on the NuttX RTOS, inheriting and enhancing its core strengths, which are primarily reflected in the following areas:

  • Standards Compliance

    • POSIX Compliant: NuttX emphasizes POSIX standards compliance, ensuring good portability and standardized interfaces.
    • ANSI Standard: Supports the ANSI C standard, providing developers with standard programming interfaces.
  • Scalability

    • From 8-bit to 64-bit: NuttX is scalable from 8-bit to 64-bit microcontroller environments, adapting to various embedded system requirements.
    • Modular Design: The kernel features a modular design, making it easy to extend and customize.
  • Real-time Capabilities

    • Real-time Scheduling: Supports real-time scheduling algorithms to meet the requirements of real-time systems.
    • Priority-based Scheduling: Supports priority-based task scheduling to ensure that high-priority tasks are executed first.

For more information, please refer to the Kernel Development Overview.

Task and Scheduling Management

openvela uses threads as the smallest scheduling unit and provides a flexible task model with multiple scheduling algorithms.

  • Task Models: Supports three modes: kernel threads, user threads, and user tasks (i.e., processes with independent address spaces).
  • Scheduling Algorithms:
    • Priority Scheduling
    • First-In, First-Out (FIFO)
    • Round Robin

For details, please see Thread and Process Management.

Thread Synchronization Mechanisms

To ensure data consistency and safe resource access in multi-threaded environments, the system provides a rich set of synchronization primitives.

  • Semaphores
  • Mutexes
  • Spinlocks
  • Atomic Operations
  • Interrupt Disabling/Enabling
  • Scheduler Locks
  • Pthread Mutexes

For detailed usage, please refer to Resource Synchronization Mechanisms.

Inter-Process Communication (IPC)

The system offers a variety of efficient inter-thread and inter-process communication mechanisms to support complex task collaboration.

File System

openvela integrates a powerful Virtual File System (VFS) and supports over 20 mainstream and embedded-specific file systems.

  • Supported File System Types (File System):

    • FAT-like: fatfs
    • Journaling/Flash-friendly: littlefs, smartfs, spiffs, yaffs, uffs, nvs
    • Read-only: romfs, cromfs, LROFS
    • In-memory/Virtual: ramfs (binfs), tmpfs, procfs, rootfs (VFS)
    • Special-purpose: zipfs, archivefs, nfs, hostfs, unionfs, userfs
  • Storage Driver Framework: Provides standard MTD (Memory Technology Device) and Block Device driver frameworks, simplifying adaptation to storage media like NAND/NOR Flash and SD/eMMC cards. (Storage Driver Framework Guide)

Debugging Tools

A comprehensive set of debugging tools is provided to assist developers with troubleshooting and performance analysis.

  • Crash Dump Analysis
  • GDB Remote Debugging
  • Performance Profiling Tools

For more tools, please consult the Debugging Tools documentation.

II. Subsystems

Connectivity Subsystem

Audio/Video Subsystem

Processes audio and video data through a unified Media Framework, providing standardized API interfaces for upper-layer applications.

For details, please see the Media Framework.

Graphics Subsystem

The Graphics Subsystem provides full-stack support for building fluid and visually appealing user interfaces. Its core components include:

  • Driver Adaptation Layer: A standardized interface layer that supports various input (touchscreens, keys) and output (displays) devices. (Driver Adaptation)
  • Graphics Rendering Library (LVGL): Deeply optimized and functionally extended based on the open-source LVGL library, supporting both CPU rendering and GPU hardware acceleration.
  • Vector Graphics Engine: A lightweight API implementation that supports the SVG Tiny v1.2 standard, meeting diverse vector graphics drawing needs.
  • UIKit: Contains high-level components and management suites. (uikit)
  • Window Manager: Provides complete window lifecycle management, layer management, and event dispatching functions.

III. Hardware and Emulator Support

Emulator Support

Experience openvela quickly on a PC using the openvela Emulator.

  • Supported Emulators:

    • goldfish-armeabi-v7a-ap
    • goldfish-arm64-v8a-ap
    • goldfish-x86_64-ap
  • Quick Start

Development Board Support

openvela supports a range of mainstream development boards. For a detailed list, please refer to the Development Board Support List.

IV. Application Examples

We provide a rich collection of Native and Quick App examples to help developers get started quickly.

Native Apps

These examples demonstrate how to use openvela's system services and subsystem features.

  • Music Player: Demonstrates audio playback, playlist management, and background services.
  • Smart Band: Demonstrates sleep monitoring, heart rate monitoring, music playback, and a stopwatch.
  • Cycling Computer: Demonstrates GPS positioning, real-time data display, and activity track recording.
  • Calculator: A basic example of UI and logic interaction.
  • Relation Calculator: Demonstrates complex conditional logic and algorithm implementation.
  • Whack-a-Mole: Demonstrates a game loop, random number generation, and animation effects.

To see the complete list of native apps, visit the Native App Examples Repository.

Quick Apps

  • Xiaomi Band Weather App: Provides a clean and intuitive display of the seven-day weather forecast.
  • Music Player: Demonstrates a basic music player, including music playback, volume control, and playlist viewing.
  • Calendar: Demonstrates a basic calendar.

More Quick App examples are continuously being added. To see all examples, please visit the Quick App Examples Repository.