RTOS DETAILS View

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

RTOS DETAILS View

RTOS DETAILS View

RTOS DETAILS View

The RTOS DETAILS view shows various information about RTOS Tasks/Threads. The view appears in the bottom pane, once a debug session is started, and disappears after debugging ends.

The view is independent of the debug probe being used, as it only uses GDB commands to receive information from the target.

The supported RTOSes are:

FreeRTOS 

Zephyr 

 

FreeRTOS Usage

The RTOS DETAILS view will display the following for FreeRTOS projects. However, the project must be configured properly.

  • TCB#: Task Control Block. configUSE_TRACE_FACILITY needs to be set to 1.
  • Task Name: Name of task. configMAX_TASK_NAME_LEN needs to be greater than 1.
  • Task Handle: Address of the task handle.
  • Task State: Current task state. Rows are also colored based on the state.
  • Priority: Task actual priority and task base priority.
  • Stack Usage: Graphical view of current stack usage, peak usage and total size for the task. Hovering over the cell reveals more information about the stack. configRECORD_STACK_HIGH_ADDRESS needs to be set to 1.
  • Runtime: Task runtime with percentage value. configGENERATE_RUN_TIME_STATS needs to be set to 1.

Note: The Runtime view needs a patch to FreeRTOS to access runtime counters. See Erich Styger's blog for explanation and patch.  

 

For the FreeRTOS portion of this article, I'll be working with the frdmrw612_freertos_sem example project obtained from the FRDMRW612 SDK.

To configure the settings on this project, open the FreeRTOSConfig_Gen.h file. In the FreeRTOSConfig_Gen.h file, use Ctrl+F to quickly find and set the defines highlighted in red above. Save the file.

config-file-open.gif

 

Once the settings have been configured, build the example and flash the board. The RTOS DETAILS View is available in the bottom pane. To view the data, suspend the target and the view will detect the RTOS type and read information about the tasks/threads. Every time the target stops (suspended or stepped), the RTOS DETAILS view will refresh with updated information.

rtos-details.gif

 

RTOS DETAILS view has the following capabilities:

  • Resize columns by dragging their edges.
  • Sort columns by clicking on them.
  • Hover over each cell and header to get more information.
  • Color rows by task/thread state.
  • Display warning icons when missing certain RTOS configurations. The warning icons can be hovered for more help on how to solve the issue.

 

 

Zephyr Usage

The RTOS DETAILS view will display the following for Zephyr projects.

  • Name: Name of the thread. CONFIG_THREAD_NAME needs to be enabled.
  • Handle: Address of the thread handle.
  • Priority: Priority of the thread.
  • State: Current task state. Rows are also colored based on the state.
  • Stack Usage: Graphical view of the stack delta offset, current usage and total size for the thread. Hovering over the cell reveals more information about the stack. CONFIG_THREAD_STACK_INFO needs to be enabled.

 

For the Zephyr portion of this article, I'll be working with the philosophers example project obtained from the Zephyr 4.1.0 SDK.

To configure the settings on this project, open the prj.conf file. Add the highlighted items above and save the file.

zephyr-rtos-views.gif

 

Next, build the project and flash the board. The RTOS DETAILS view will appear on the bottom pane during a debug session as it did for the FreeRTOS example. Expect the behavior to be similar with only a change in the columns.

nxp-rtos-details-zephyr.png

Labels (1)
No ratings
Version history
Last update:
‎04-30-2025 09:12 AM
Updated by: