Embedded RTOS - tools and community support
March 27, 2024

If you use an RTOS on a daily basis, it's natural that it is your first option when undertaking a new project. However, if you're just starting out or thinking about trying something new, it's worth paying attention to the community support and tools available. We believe that it is these two aspects that are key when choosing an RTOS to work with on a project: the tools and the support offered by the community and the manufacturer. Below is an overview of these elements in different systems.

RTOS tools

When choosing an RTOS, it is worth paying attention to tracking tools. They allow us to get a good look at what exactly is happening in our application - we can easily check if the shuffles executed in the order we wanted, or if the execution times or periodicity of our shuffles match. So let's take a look at what is available among our RTOS.

embOS - SystemView

Segger, along with its RTOS, provides a dedicated tool, namely SystemView. Since both come from the manufacturer, the integration is not complicated.
In short, you need to:
+ add the SystemView header files to the application,
+ select the details of the target platform in the configuration,
+ specify the timing source and start tracing.

Data saved to the structure given at initialization, so after the program is executed, it should be retrieved from there and saved in .SVDat format. The whole thing is clearly described in the documentation for SystemView: https://www.segger.com/doc/UM08027_SystemView.html#SystemView_on_the_target

SystemView in its glory

The GUI presents itself clearly and legibly and allows you to get information:

  1. Timeline - contains events such as shuffle expropriation, interrupt or semaphore release;
  2. Visualization - the most important part of the tool; it shows in an accessible way everything described on the axis above;
  3. Information - basic information about the system and applications;
  4. CPU consumption - shows graphically the occupation of working time by each shuffle;
  5. Statistics - information on each shuffle individually.

FreeRTOS - SystemView

FreeRTOS does not provide its own tracing tool. Nevertheless, it can be integrated into SystemView, which has already been described. This is possible with a dedicated patch from Segger: https://wiki.segger.com/FreeRTOS_with_SystemView
Make sure that the version of the patch agrees with the version of FreeRTOS you are using. The integration itself depends on the IDE used. Other than that, the other steps to obtain a data file for use in SystemView are analogous to those for embOS.

Zephyr - SystemView

With Zephyr, the situation is similar to FreeRTOS - SystemView support can be added to the application. The documentation describes how to enable this option by editing the configuration file, but does not mention that the CONFIG_TRACING_BACKEND_RAM=y option is also useful. The description of post-mortem analysis is quite sparse and if you want to view the waveforms in real time then you need J-Link.

ThreadX - TraceX

Microsoft, like Segger, provides its own tracing tool. TraceX is a ThreadX module, so since the RTOS itself is heavily modular, it does not require separate integration. To enable buffer creation for tracing, you need to enable this functionality in the configuration file and specify the clock source (e.g. DWT for Cortex-M4). Detailed instructions are included in the documentation: https://learn.microsoft.com/en-us/azure/rtos/tracex/chapter5
As with SystemView, the data is saved in the appropriate structure, and after export, it must be saved in .trx format.

TraceX from Microsoft

The GUI can be downloaded from Microsoft's website and offers similar information to SystemView:

  1. Visualization - unfortunately, unlike SystemView, the axes cannot be easily moved, zoomed in and out; besides, the size of each item in the Y-axis is not proportional to the time it took;
  2. Shuffle information;
  3. CPU consumption;
  4. Stack consumption;
  5. Statistics.

RTOS community support

FreeRTOS

Main community forum: https://forums.freertos.org/
Forum organization

5 categories in the forum (Announcements / Kernel / Libraries / Partners / CommunityMedia).
‍Activity in theforum
More than 70 queries in the above categories and more than 400 responses last month (as of 03.2024).
There are thousands of threads on the forum regarding the FreeRTOS kernel (10,494 threads) and hundreds regarding libraries (767 threads).
Others
Books about FreeRTOS, such as:
+ Building real-time embedded systems using FreeRTOS;
+ FreeRTOS - A practical approach with Arduino;
+ Beginning STM32: Developing with FreeRTOS, libopencm3 and GCC;

Zephyr

The main forum of the community (discord platform): https://discord.com/invite/Ck7jw53nU2
Organization ofthe forum
Division into categories and channels within these categories.

The forum contains 12 categories (including Zephyr / Architecture / Subsystems / Tooling/Bluetooth / Vendors / Third-party) within which we can find more than 150 channels for conversation. Example list of channels for Bluetooth category: ble / ble-audio / ble-mesh / ble-llcp / hci / qualification.
‍Activityon the forum
More than 1,000 messages last month (as of 03.2024).
Other
Channel on YT: The Zephyr Project (136 videos).

ThreadX

Here we have a problem. Due to the migration of ThreadX from under the wings of Microsoft to the Eclipse Foundation - the old forum on Microsoft's site has frozen. The new one does not exist yet. It is now possible to sign up for the developers' mailing list (221 subscribers as of 15.04.2024). We are now left with the microcontroller manufacturers' forum, where we can find threads about ThreadX.

embOS

Segger forum:https://forum.segger.com/index.php/Board/11-embOS-related/?s=bcc1df586c32666977bf3af2415937f7a065edb0
‍One
thread this year. A dozen in 2022.
Segger bets on Wiki: https://wiki.segger.com/embOS

A knowledge base with more than a dozen articles in the areas of: General / Architecture & IDE / embOS project configuration / third-party support.

In our opinion, Segger has put everything on "Ticket Support".
You fill out a form with 8 questions (from the questioner's danuch to the product serial number) and voilà!
The entry threshold is high, although it must be said that support responds quite efficiently (in most cases up to 48h).

Summary

When it comes to integrating the tracing tool with the RTOS, it is easiest with ThreadX and embOS - they have dedicated tools. FreeRTOS and Zephyr manage themselves, through patches to SystemView.
When it comes to tracing tools, in our opinion SystemView is definitely ahead of TraceX. It is clear and intuitive. Among other things, it allows easy manipulation of the axis with a shuffle view. TraceX, unfortunately, assigns the same large rectangle on the axis to each event, making it hard to tell at a glance which task takes how much time. Besides, you also have to manually recalculate and enter the time base. Oh, a minor quibble.

In terms of community support, Zephyr and FreeRTOS fare best. ThreadX currently falls far short of these two (currently lacking a forum and knowledge base available to the general public).
The commercial solution - which is embOS - is difficult to compare with the others here. Through the project support ticket system, only a fragment of support and knowledge is widely available - on the wiki and the rarely attended forum.