Tuesday, January 30, 2024 - 08:17
  • Share this article:

Embedded systems found in vehicles, machines, and appliances have long depended on real-time operating systems (RTOS). With the ongoing digital transformation of society, their utilisation is on a steady rise. What exactly is a RTOS? Unlike the operating systems powering your smartphone or laptop, an RTOS does not prioritise peak performance. Rather, its main objective is to deliver guaranteed latency. This means that it is designed and built to ensure that mission-critical and highly time-sensitive applications – such as the microcontroller operating brakes in an automobile; or the propulsion subsystem controlling the thrusters on a spaceship – operate exactly when they need to, and in the most reliable fashion possible. 

The challenges such critical operations pose are compounded by the inherent limitations of the devices on which they run. Because they often operate autonomously and quickly in small packages, these devices grapple with significant constraints on processing power. Consequently,  any application they run must be extremely small, while still delivering critical functionality. 

The industries relying on existing RTOS solutions understandably approach the adoption of new alternatives with caution, given the high stakes involved in case of failure. Yet, this cautious approach also inadvertently curtails the scope for innovation in this domain.

ThreadX: Open Source, Proven Technology, Safe and Secure

There are a number of both proprietary and open source real-time operating systems (RTOS on the market. ThreadX is already well-known among them for its focus on small code size and high performance. However, its competitive advantages extend far beyond these attributes.

Eclipse ThreadX is a real game-changer for real-time embedded systems, thanks to four key attributes:

  1. It’s a mature operating system that’s been around since 1997. Device makers place a lot of value on stability and predictability in release cycles. 
  2. It’s open source. This is very important because the available commercial options are invariably expensive, which in turn makes it costly for companies to build their offerings around.
  3. As part of the Eclipse Foundation, ThreadX benefits from vendor-neutral governance. Even for companies willing to invest in expensive commercial solutions, they have little to no ability to influence the development and advancement of those solutions. With limited competition, there’s little opportunity to shop around for better or different characteristics.
  4. ThreadX has numerous, difficult-to-acquire security and safety certifications. Getting those certifications is both expensive and time consuming, with a long auditing process that also requires extensive documentation. It’s important to note that no other open source RTOS offers this level of certification today, which greatly increases industry confidence. 

This combination of attributes makes ThreadX truly unique. While other RTOS offerings may possess some of these qualities, be it open source, well-established pedigrees, or multiple certifications, none can match the combined attributes of ThreadX.

The ThreadX Structure Further Enhances Usability

All this said, the relevance of all these attributes would be moot if the RTOS itself wasn’t useful. To understand how ThreadX delivers on the promise of a game-changing RTOS, it’s important to understand the various components and how they all fit together. 

Beginning with the ThreadX kernel – it’s both small and flexible. The ability to shrink the kernel to as little as 2 kilobytes is a huge advantage and makes it usable in all sorts of resource-constrained environments. Plus, every cent you save on the actual hardware powering your device means either additional margin or more room in the budget to improve the  product. 

Next, you have the filing system, FileX. It supports the FAT12, FAT16, and FAT32 formats with a 9 kilobyte footprint, further emphasising its small and flexible nature. It also supports wear levelling for flash storage, where data is distributed as evenly as possible, extending the functional lifespan of the chips. 

ThreadX also offers USBX, providing support for the ubiquitous USB standard. It also supports both host mode and device mode, even simultaneously if needed, allowing ThreadX to be used in USB devices such as mice and keyboards; or in hosts to which such devices would be connected. 

The inclusion of NetX Duo provides ThreadX with a robust network stack supporting both IPv4 and iPv6, along with IPsec and TLD/DTLS for encrypted communications. Whether you have ethernet, Wi-Fi, or cellular connectivity, NetX Duo has you covered. It also provides implementations for many very useful protocols, such as MQTT. 

For enterprises looking to build functionality on top of their applications, GUIX serves as a framework for constructing user interfaces atop ThreadX.  While many applications may not offer user interfaces due to processing power demands, GUIX facilitates their creation in cases where they would be useful. In particular, GUIX offers an extensive collection of widgets developers can leverage. Part of GUIX is GUIX Studio, a design tool developers can use to build their user interfaces. With Studio, developers can generate GUIX-compliant code, facilitating the efficient implementation of the UI for integration within the final application.

Finally, there is the TraceX component, which provides a graphical view of real-time events and behaviour. This is a crucial tool for developers to evaluate the performance of their code and debug it as necessary, which is of fundamental importance for the safety-critical applications for which ThreadX is so well-suited.

It’s also worth noting that while the components are designed to function together, they all work independently as well. Users can employ some or all of them according to their needs, either building their own functionality on top of the ThreadX kernel or using another kernel of their choice.

In short, the full ThreadX package represents a battle-tested, mature technology that’s already been deployed in roughly 12 billion devices, including the Mars Reconnaissance Orbiter (MRO) probe. Its versatility makes it an excellent fit for any embedded device or application.

Join the Working Group to Drive the Future and Harness the Power of ThreadX

The initial project proposal released in December of 2023 has been officially approved, and the project is currently in the provisioning phase as we migrate the code, trademarks, and security documentation. We’re expecting that process to be done by the end of Q1, and our first release to come before that. The working group is still in the process of being developed, a process we’re hoping to have completed by the end of Q1 2024. Integral to the value proposition of ThreadX is the fact that joining the working group will be a tremendous accelerator for any enterprise looking to integrate ThreadX into market offerings. Enterprises aiming to certify their products for safety-critical applications will need a safety manual that incorporates the safety manuals of each subcomponent in the stack. Working group members will have access to the ThreadX safety manual, which will significantly accelerate the certification process. 

Participate in a Project on the Cutting Edge

If you’re interested in contributing new features to ThreadX, then you should join the ThreadX developer mailing list

Or, if you’re just curious at the moment and want to follow the evolution of the ecosystem, consider signing up for the general ThreadX mailing list.

And, of course, if you want to be part of the working group, now is the time to get involved. You can contact me directly or drop a line in the ThreadX mailing list. 

About the Author

Frédéric Desbiens

Frédéric Desbiens

Frédéric Desbiens is a program manager for Embedded, IoT and Edge Computing at the Eclipse Foundation.