Keil Logo

RTOS-aware debugging

Learning Platform

Using a real-time operating system (RTOS), significantly simplifies development and maintenance of complex embedded applications with multiple parallel tasks. However, due to increased complexity and the use of 3rd-party software components, it can become challenging to analyze the operation of RTOS-based programs using classic code debug techniques.

Keil RTX5 integrates multiple mechanisms that provide full visibility into RTOS operation and thus speed up debugging of potential problems and assist in program optimization.


RTX RTOS Watch Window

Keil RTX5 supports Component Viewer and provides all key information about current RTOS state.

Detailed status information

RTX5's system configuration, its operation status and details about all allocated objects are displayed in the RTX RTOS window in µVision. The data is updated at run-time and is easy to browse, understand and analyze.

Always available

The RTX RTOS view is available when RTX5 is used in the project and doesn't require any special configuration. It works with all Cortex-M targets and with any debug adapter.

Stack usage analysis

Application developers can observe in real-time the actual stack usage for individual threads. The stack watermarking feature even shows the current maximum stack usage. This allows to optimize the RAM usage and avoid stack overflows.

Object memory usage counters

The maximum memory usage for each RTX5 object is displayed which enables fine-tuning of memory resources.

rtx_rtos_watch_all

Event Recorder Support

RTX5 is annotated with more than 170 events for use with the Event Recorder.

The System Analyzer view in µVision graphically displays thread operation over time.

Event details which include accurate timestamps are provided in the Event Recorder window. You can filter the events to capture and display only the target events of interest.

The logging functionality enables post-execution analysis and test automation.

RTX5 documentation explains how to add Event Recorder visibility in RTX RTOS.

rtx_rtos_event_recorder

RTOS Thread Statistics

The Event Statistics for RTX5 threads becomes automatically available in µVision when Event Recorder is enabled.

At run-time, it displays how many times each thread has been put in a particular state as well as minimum, maximum and average thread execution times in each state.

RTX5 Event Statistics can be saved in a log file for analysis and post-processing as part of a test automation framework.

rtx_rtos_event_statistics

Thread Events in System Analyzer

µVision's System Analyzer window gives developers a graphical view on the program operation over time at it displays the status of each thread. Use the cursor and markers to execute in-depth timing analysis directly in the window.

When trace is used, all interrupts are displayed in the System Analyzer. This provides a time-synchronized view on the RTOS-related exceptions such as SysTick, SVCall and others, but also any interrupts used by the application.

Finally, voltage and current consumption values are also available in the view when using a ULINKplus debug adapter.

rtx_rtos_system_analyzer


3rd-Party Tools Support

Keil RTX5 is supported by Percepio's Tracealyzer that visualizes the runtime behavior of embedded software with over 25 graphical views and complements the debugger's low-level perspective with the big picture.

  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.