What Is a Real-Time
Operating System (RTOS)?

Your guide to choosing an RTOS for your next embedded system project.

 
*Online purchasing available only in the following countries: U.S., Canada, Japan, Denmark, Finland, France, Germany, Italy, Spain, Sweden, UK

What Is an RTOS and How Does It Work?

A real-time operating system (RTOS) is an operating system with two key features: predictability and determinism. In an RTOS, repeated tasks are performed within a tight time boundary, while in a general-purpose operating system, this is not necessarily so. Predictability and determinism, in this case, go hand in hand: We know how long a task will take, and that it will always produce the same result.

RTOSes are subdivided into “soft” real-time and “hard” real- time systems. Soft real-time systems operate within a few hundred milliseconds, at the scale of a human reaction. Hard real-time systems, however, provide responses that are predictable within tens of milliseconds or less.

Taxonomy of operating systems

RTOS VS. OS

An RTOS is a type of operating system, but it is vastly different from the kind most consumers are familiar with. Operating systems in phones or personal computers are, comparatively, bloated with apps and features; they must be able to support anything the user might want to do today. An RTOS, on the other hand, is streamlined, meant to execute its tasks quickly and effectively. It is a fraction of the size, sometimes only a few megabytes (vs. more than 20 gigabytes), with a simple graphical interface, and it lacks many familiar features, such as a web browser.

Real-Time System Characteristics

5 Characteristics of an RTOS
  • Determinism: Repeating an input will result in the same output.
  • High performance: RTOS systems are fast and responsive, often executing actions within a small fraction of the time needed by a general OS.
  • Safety and security: RTOSes are frequently used in critical systems when failures can have catastrophic consequences, such as robotics or flight controllers. To protect those around them, they must have higher security standards and more reliable safety features.
  • Priority-based scheduling: Priority scheduling means that actions assigned a high priority are executed first, and those with lower priority come after. This means that an RTOS will always execute the most important task.
  • Small footprint: Versus their hefty general OS counterparts, RTOSes weigh in at just a fraction of the size. For example, Windows 10, with post-install updates, takes up approximately 20 GB. VxWorks®, on the other hand, is approximately 20,000 times smaller, measured in the low single-digit megabytes.
DIFFERENCES AND SIMILARITIES BETWEEN AN EMBEDDED SYSTEM AND AN RTOS

An embedded system is a computer that is embedded into a larger machine — for example, the microcontroller on a robotic arm. In noncritical systems with some timeline flexibility, developers can use an open source general-purpose OS (GPOS) such as Linux. Linux is full featured, flexible, and well known. In a critical system (whether that means safety critical or mission critical), developers opt for real-time operating systems. The characteristics that set an RTOS apart are often essential to success. For instance, a robotic arm in a factory needs to be predictable and reliable, and it must be able to stop immediately when employees enter its area of operation. Variability can result in wasted resources, quality-control issues, or injury.

A robotic arm must be able to stop immediately when employees enter its area of operation.

RTOS Use in Embedded Systems

Due to its benefits, a real-time operating system is most often used in an embedded system — that is, a system that operates behind the scenes of a larger operation. The RTOS usually has no graphical interface. Occasionally, multiple OSes are integrated simultaneously, to provide operational capability coupled with the usability of a general-purpose OS.

RTOSes are often in intelligent edge devices, also known as electromechanical edge or cyber-physical systems. This means that the device is both producing and operating upon data. So a car, for example, would be able to monitor its surroundings and act upon them instantaneously on its own. Such devices often couple artificial intelligence or machine learning, or both, with real-time components to increase the capabilities of the underlying structure.

An autonomous car needs to be able to monitor its surroundings and act upon them instantaneously on its own.

FEATURES AND ADVANTAGES OF AN RTOS

An RTOS is small, fast, responsive, and deterministic. This means that it will execute tasks quickly and efficiently, responding as expected every time. Due to the significance of its host device, the RTOS infrastructure is more secure and less likely to crash or fail. Finally, an RTOS is developer oriented, meaning that it continues to roll out updates that help users code more effectively.

Benefits and Risks of a Commercial vs. In-House RTOS

Some companies try to produce their own RTOS in house, tailor-made for their project, instead of buying a commercial off-the-shelf operating system. This has some advantages: The operating system is designed specifically for the use case, and the company understands its mechanics and inner workings. However, this approach is often more expensive and more time-consuming, and developers who are not used to working on operating systems take a great deal of time to produce one. Using a commercial system is faster, easier, and brings the benefit of an experienced technical team that can answer questions and provide support. An operating system is a tool, much like a hammer or a drill. While you could make one — one that you would thoroughly understand and that might fit your project better — it would take a lot of time, without guarantees of performance or capability.

WHY USE AN RTOS?

In applications that require reliable and repeatable actions, the RTOS is favored over its general OS counterpart. Especially in embedded or critical systems, where reliability and speed are essential, a real-time operating system is needed.

Disciplines That Impact Real-Time Systems

The RTOS industry is heavily influenced by developments in the computer hardware industry. When new developments, such as the use of multi-core technology, become common, OSes are updated to support them. Emerging technologies such as artificial intelligence, machine learning, and 5G are also under the scrutiny of the OS developer, since a changing industry means systems must support an array of use cases. OS architects must consider trends in software as well as hardware development. As the field changes and developer profiles pivot, updates must support new languages, new technologies, and new deployments.

Emerging technologies such as machine learning and 5G are under the scrutiny of the OS developer.

RTOS Architectures

Aside from the minute details, two prevailing design philosophies affect RTOS design: monolithic kernel versus microkernel. These systems are differentiated by their structure; whereas monolithic kernel systems run in a single space, microkernel systems compartmentalize different components of the architecture.

Microkernel Systems

In microkernel architecture, components are stored in separate “rooms,” which are independent from one another but share a similar space. A room can be renovated without impacting those around it. However, to get from one to another, you have to step through the doorway and head down the hall, which wastes time. Any action has to return to the kernel before it can move to the component it references, meaning some operations take much longer than necessary.

Monolithic Systems

In a monolithic system, there are no “walls” between the rooms, so you can step from one to another much more quickly. Rather than implementing a small kernel, monolithic kernels provide services of their own as well as regulating those of other areas. With exceptions, operations are executed in the kernel space, removing the recurrent need to return to the kernel and improving speed and performance. However, making a change in one area could have ramifications for the entire system.

Microkernel System Monolithic System
The kernel and operations are housed in separate spaces, with the kernel itself being bare (hence micro). Operation spaces are not given access to one another and must return to the kernel. Kernel and operation processes share the same space. Operations move more quickly, and the systems boast higher performance. However, updates may require an extensive overhaul.

Real-Time System Examples

RTOSes can be found in countless products around the world, with VxWorks alone powering more than two billion devices. Systems from car engines to deep-space telescopes to helicopter guidance systems to the Mars rovers use embedded systems that run a real-time operating system.

A&D Telecom Transportation Medical Manufacturing
  • Flight display controller
  • Engine turbine
  • Drones
  • Extraterrestrial rovers
  • 5G modem
  • Satellite modem
  • Base station
  • Functional safety systems
  • Emergency braking systems
  • Engine warning systems
  • Magnetic resonance imaging
  • Surgery equipment
  • Ventilators
  • Factory robotics systems
  • Safety systems
  • Oil and gas vibration monitors

The Changing World of Embedded and Real-Time Operating Systems

New Methodologies

Expectations for embedded systems cascade down to the operating systems that power them. Real-time operating systems must keep pace with innovation and embrace modern development practices. This means being compatible with the frameworks, languages, and methodologies embraced by the new generation of embedded system developers, while allowing no compromise in terms of security, safety, performance, or reliability.

Supporting Legacy Systems

Innovative advancements increasing performance, connectivity, and design cycles are starting to make even new products obsolete. This raises the question of how to handle legacy systems. It’s not financially viable to keep recoding embedded applications. System makers, on the other hand, would prefer to use existing code as much as possible, especially when investment has already been made to certify software.

New Hardware and Virtualization

Advances in multi-core–based hardware platforms have enabled the consolidation of embedded systems and applications. With a single chip now able to contain any number from 2 to 64 CPUs, it is possible to reduce the cost, size, and weight of the final shipped product.

Virtualization is also accelerating development of embedded systems. Multiple embedded systems can now run, in virtualized form, on a hypervisor on top of a single piece of hardware. This is critical for manufacturers who want to maximize their investment in existing IP while providing a bridge from legacy applications to new platforms.

Factors for Choosing a Commercial RTOS

The Benefits of a Commercial RTOS vs. Open Source

Aside from in-house RTOS options, developers can choose to use open-source or community-based operating systems. While these provide some of the benefits of a real-time operating system, they fall short in other key areas. Larger deployments often make use of boards costing hundreds, thousands, or even millions of dollars, which means developers are investing heavily in hardware. Problems encountered while implementing an open-source system could quickly push deadlines and stretch budgets. Open source systems also lack organized backing, which can result in missing documentation or unresolved glitches. A commercial system, on the other hand, comes with the benefits of an organized, professional engineering team that will help solve issues or provide explanations.

A commercial system comes with the benefits of an organized, professional engineering team.

Common Business Challenges Affecting Commercial RTOS Implementation

  • Leveraging the massive growth opportunity of IoT as soon as possible
  • Differentiating product offerings with leading-edge features and capabilities
  • Adding new features to products as market needs evolve, while leveraging the investment in the core operating system — all while minimizing risks to devices already deployed in the field
  • Keeping platform costs down
  • Reducing time-to-market and development risks for deploying real-time systems
  • Efficiently dividing engineering resources between sustaining existing products and developing new ones
  • Reducing risk for platforms requiring real-time safe and secure capability at medium to high levels of certification
  • Managing increasing complexity across multiple technologies, product lines, development organizations, and geographies

Need for Safety Certification

If there is a need for safety certification, leveraging a commercial RTOS can make it easier and more cost-effective to achieve, while reducing schedule risk. In an evaluation for safety certification, the commercial RTOS must provide certification evidence pages or safety profiles for the specific certification your business requires.

Hardware Support

Commercial RTOSes have an extensive range of board support packages (BSPs) to assist with board bring-up and design. These software kits make it quick and easy to use an RTOS with specific types of hardware. At Wind River®, we offer the most extensive range of BSPs in the embedded software industry. Each of our packages is tested and validated for seamless interoperability to help you accelerate your development process and innovate your design.

Your business needs, cost structure, and budget can all impact your decision.

Commercial RTOS Costs

While the cost of a commercial RTOS may be a big objection, one must also consider its overall benefits. These could be competitive advantage, time-to-market, cost savings, risk reduction, and peace of mind. It is important to develop and test the business value to determine whether these benefits outweigh the cost.

PAYING ROYALTIES FOR A COMMERCIAL RTOS

When considering a commercial RTOS, investigate the option of royalty payments through a production license (PL) model vs. an up-front charge. The PL model is shared risk in that it helps create a financial incentive to make your business successful. Your business needs, cost structure, and budget can all impact your decision.

COMPATIBILITY AND SUPPORT FOR NEWER VERSIONS

Long-term performance, security, and feature support are also factors in selecting a commercial RTOS. Some example areas to check include preserved API compatibility and POSIX® compliance. Learning how much the core OS kernel is expected to change in the near future can help you predict how much effort will be required to upgrade or roll back versions. There could also be migration considerations around networking and BSPs, and it is critical that the chosen option has the documentation and expert support necessary for your success.

How Can Wind River Help?

VxWorks: The Leading RTOS for Embedded Systems

VxWorks is the industry’s most trusted and widely deployed RTOS for critical embedded systems that must be safe and secure. It delivers a proven, real-time, and deterministic runtime combined with a modern approach for development. Regardless of the industry or device type, companies rely on the VxWorks pedigree of security, safety, high performance, and reliability.

BENEFITS AND HIGHLIGHTS
  • Credible and proven track record of 30+ years
  • End-to-end offering of engineering and sales support with a local presence
  • Support for modern development languages (C/C++ with Boost, Rust, and Python)
  • The only RTOS supporting IT-like application deployment with OCI container support
  • POSIX® PSE52
  • Extensive list of board support packages, with continuous optimizations to support the most advanced processors and systems-on-chip
  • Extensive portfolio of safety certification history, including 600+ programs to meet the most stringent industry safety standards
  • Flexibility in customizing your product with access to full source code

Complementary Solutions for Embedded Systems Design

At Wind River, our family of products for embedded systems expands beyond just our commercial VxWorks RTOS solution. VxWorks may be better suited for projects that require certification, have IP concerns, cannot use GPL code, and/or require specific customization support from our IP services. We also offer Wind River Linux if there is unsupported architecture in your development. All of our products are backed by our award-winning global customer support and IP services to help you meet your business and program goals.

IP Services Support and Maintenance Development Tools
VxWorks
Kernal
User Space
Networking
File Systems
Connectivity
Security
Frameworks/Languages
Linux
Yocto Project
ISO 9001:2015
BSPs
Upstream Model
Native
Multi-core Hardware

Wind River products and services work together to support differentiated system designs.

THINK WE MIGHT BE A FIT?

Speak with a Wind River expert to determine whether your business would benefit from our technical growth capability.

Contact us

Real-Time Operating Systems: FAQs

Common features of an RTOS include task scheduling, interrupt handling, inter-task communication and synchronization, memory management, and device driver management. An RTOS must provide deterministic and predictable behavior to ensure that tasks can complete within their deadlines.
An RTOS, or real-time operating system, is a specialized software system designed to manage and prioritize tasks in real-time systems, where tasks have strict timing constraints. It differs from traditional OSes in that it can guarantee timely response to events and tasks, making it suitable for mission-critical applications.
RTOSes are used in a wide variety of applications that have strict timing requirements, such as medical devices, industrial control systems, aerospace and defense systems, automotive electronics, and consumer electronics. It’s also commonly used in embedded systems, where reliability, safety, and performance are critical.
Task scheduling in an RTOS is typically priority based, where tasks are assigned priorities based on their urgency and importance. The scheduler uses a preemptive algorithm to select the highest-priority task that’s ready to run, ensuring that critical tasks can be executed on time.
Advantages of using an RTOS include predictable and deterministic behavior, which ensures that critical tasks are completed on time. It also provides better resource management, improved responsiveness, and reduced system overhead, resulting in better system performance.
Challenges associated with using an RTOS include the need for specialized expertise and experience to configure and optimize the system. The real-time behavior also adds complexity to the development process, and the system must be designed to handle unexpected events and errors to ensure that it remains reliable and safe. Additionally, the cost of an RTOS can be higher than that of a traditional operating system.
There is no “best” RTOS. Like any other operating system, each RTOS varies in its strengths and weaknesses, and its use will determine the most appropriate choice.
Unfortunately, few universities offer courses that cover the field of embedded engineering. Online resources and free SDKs (such as the VxWorks SDK) can be helpful tools for practicing implementation. In addition, Wind River offers courses that address intelligent systems challenges, which can increase individual human capital or help entire teams achieve their goals faster and more easily.
An RTOS processes data as it comes in, without needing to buffer or refresh applications. This supports faster, more accurate responses in systems with changing input environments. To accomplish this, the kernel is designed to be small and nonintrusive, and it stays out of the way of the operating system’s functions.
The kernel operates much like the conductor in a symphony. It controls and regulates the other functions, without working itself or getting in the way. However, in an RTOS, when no operation is executed, the kernel does nothing at all.
Task priority varies, but many RTOSes use a priority-based preemptive scheduling system, which executes the highest-priority items first. Other options include rate monotonic scheduling or Earliest Deadline First scheduling.
Raspberry Pi is favored for recreational and hobby use, due to its economical cost and friendly interfaces. However, like most other boards, it supports a wide variety of operating systems, including a number of RTOSes. We offer a free VxWorks SDK on GitHub for Raspberry Pi 3B/3B+ and Raspberry Pi 4B. This allows developers to create proof-of-concepts or prototypes for larger projects, or to simply familiarize themselves with a real-time operating system.
While most operating systems could be used in an embedded environment, embedded Linux differs from a standard Linux distribution in several ways. Rather than being designed for general use, embedded operating systems are built to execute operations, and their design reflects this. They boast an exponentially smaller size and lack large portions of graphical interfaces. There is no desktop and the system opens to a terminal, and therefore there are no apps or drivers unless specifically included by the developer.
Wind River Linux is designed for use in embedded systems that do not require the deterministic or safety-critical features of a real-time operating system. Best of all, it is free to download and install.
In the emerging field of 5G technology, RTOSes have made an impact due to their low-latency responses and their ability to take advantage of faster communications. RTOSes can also be found in devices that rely on machine learning, because the real-time stream of data can be operated upon as it comes in.
Wind River launched ROS2 for VxWorks in December 2019, which enables the use of the Robot Operating System in VxWorks builds.