Who is this for?

This is an introductory topic for software developers new to RTOS development.

What will you learn?

Upon completion of this Learning Path, you will be able to:

  • Understand the basics of RTX-based RTOS application development
  • Configure and manage an RTOS project in Keil Studio, including defining the memory map, selecting software components, and setting up debugging configurations for Cortex-M processors
  • Create and manage multiple threads within an RTX5 RTOS application

Prerequisites

Before starting, you will need the following:

Summary

AI-assisted

This summary was drafted with an approved AI-assisted workflow and reviewed by Arm contributors before publication. Human technical review remains part of the process so the final page reflects engineering rigor, accuracy, and Arm editorial standards.

Close
?
You’ll create, configure, and debug an RTX5-based application in Keil Studio for VS Code using the CMSIS-RTOS2 API. First, you’ll create a CMSIS Solution project, select required components in the Run-Time Environment, and add system startup so RTX5 can initialize the SysTick timer with SystemCoreClockUpdate() before starting the scheduler. Then, you’ll implement an app_main thread that launches multiple worker threads and builds the project using the CMSIS extension. Using the Cortex-M4 Fixed Virtual Platform as the target, you’ll run and step through the program and verify execution by observing periodic thread messages printed in the Debug Console.

Frequently asked questions

AI-assisted

These FAQs were drafted with an approved AI-assisted workflow and reviewed by Arm contributors before publication. Human technical review remains part of the process so the final page reflects engineering rigor, accuracy, and Arm editorial standards.

Close
?
Which target should I use if I don’t have hardware available?
Use the Cortex-M4 Fixed Virtual Platform (FVP) referenced in the steps. The procedure also applies to other devices supported by CMSIS-Pack.
How do I start a debug session in Keil Studio for VS Code?
Select the Debug icon or open the Run and Debug view, then choose the configured debug connection to launch the FVP. Use the standard debugging controls to step through your code.
How do I know the RTOS is running correctly?
After initialization, the Debug Console displays messages from your threads. Look for output similar to: [model] hello from thread 1/2/3.
Where do main.c and app_main.c come from?
main.c is created automatically in the Source Files group when you set up the CMSIS Solution project. Add app_main.c by clicking the + icon in the Source Files group.
Can I change the number or names of the threads?
Yes. The number and naming of threads created by app_main are flexible, so adjust them to match your application structure.
Next