rcX RTOS plugin for winIDEA is used to view rcX RTOS elements such as tasks as a list in dedicated window.
If not already installed put plugin “RTOS.rcX.dll” under Plugin directory in winIDEA installation directory.
Start winIDEA and load the plugin in Plugins/Options dialog by selecting “rcX RTOS” and clicking “<<” button.
Screenshot 1: Available plugins
Screenshot 2: rcX RTOS plugin will be loaded
Once loaded, plugin's main window showing tasks can be opened or closed by selecting rcX RTOS > Tasks under Plugins. Other rcX windows can be opened or closed from toolbar menu in task window.
There are two major types of objects which are tasks and other kernel objects. Tasks are displayed in main window while other kernel objects are displayed in object subtype window.
While memory is not accessible all windows will report “Can not access RTOS state” like shown on Screenshot 3. This is normal until debug session with download is not started. Object symbols could not be evaluated if after download the same message is still shown. Use symbol browser and verify their presence to confirm that symbols are available. Symbols differ in different versions of rcX RTOS:
-Version 2.0.x.x: “aptPrioTable”, “aptPrioTableEnd” and “ptCurTsk”
-Version 2.1.x.x: “g_ptCurrentTask” and “g_trXTaskList”
Symbol availability depends on code, compile tool and its settings, download file debug format, loader settings etc. To adjust download file options select download file and click “Properties” in Debug/Files For Download dialog. In Download File Options dialog click on “Advanced...” button to open dialog for setting advanced options.
NOTE: Select the rcX RTOS version running on target in plugin configuration: rcX RTOS > Configuration
After download (or reset) objects are in undefined state. This is indicated with “RTOS in undefined state” in all windows like shown on. Once current task is set the windows should display associated content.
The windows content is refreshed after CPU stops which means that while CPU is running, content is not refreshed. Instead last known data is displayed. Plugin uses winIDEA memory cashing when accessing memory. To speed up window refreshing enable cashing in Debug/Debug Options... dialog on Memory Access page.
Screenshot 4: Objects in undefined state
Screenshot 5 displays a sample task list. Note that currently active task row has light green background. For more information about displayed task properties please refer to rcX documentation.
Tasks can also be viewed in winIDEA dedicated Tasks window. This window is opened by selecting View/Tasks from winIDEA main menu. The preview is shown on Screenshot 6. Tasks window is a standard part of winIDEA and is meant as unified RTOS window. It is populated with data provided by RTOS plugin for specific RTOS. rcX RTOS plugin provides this data for rcX RTOS. Note that unified window doesn't show RTOS specific information as dedicated plugin window does. Some additional info in unified window can also be view by selecting desired task and pressing the “Task Properties” button.
Also note that task debug context is available for any task when is STOP mode. Context is entered by double clicking on desired task in Task window or selecting desired task and pressing the “Set Context” button also in Task window. This feature is not available from plugin windows.
NOTE: Only for rcX RTOS version 2.0.x.x.
Following object subtypes can be viewed in associated window:
To view a list of desired subtype objects click the corresponding button in main (task) window or select it from Plugin/rcX RTOS sub menu. All non-task objects have common properties “Name”, “Creator” and “Waiting Task”. Additionally they have other custom properties. For more information about object properties please refer to rcX documentation.
If no instances of window's object type is found “No objects found” is displayed in that window (Screenshot 7) otherwise instances are listed as shown in Screenshot 8. Object listing is bound to additional set of symbols that must be available. Refer to Viewing objects for more info about symbols. Each object subtype requires associated symbol. Symbols are: "tSemSntl" for semaphores, "tMtxSntl" for mutexes, "tQueSntl" for queues, "tDrvIntSntl" for interrupts and "tDrvUrtSntl" for UARTs.
From v. 9.10.110 rcX RTOS plugin also supports task aware profiling. When plugin loaded, 32 bit data under current task pointer symbol will be profiled. This data is actually a pointer to TCB of a current task. By profiling its values the time of tasks can be obtained. TCB addresses that current task pointer points to are mapped to task names from TCBs.
Due to TCB locations in RAM, mappings are only obtainable after the RTOS is initialized. This is not sufficient for profiler which needs the mappings when started and that can also be right after reset. Mappings are provided to profiler from previously build map stored in file “rcXTasks.lst”. The content of the file can be created automatically with selecting Plugins/rcX RTOS > Use current task for profiler when in STOP mode after the RTOS has been initialized and Tasks window shows application tasks. File is placed in workspace directory.
Screenshot 9: Task profiling preview 1
Screenshot 10: Task profiling preview 2
Profiler also shows “__startup__” task, which is not shown in Task window. The reason for this is invalidated RTOS symbol object after reset. rcX RTOS plugin forces pointer to current TCB to zero after reset. It remains zero until set by RTOS to point to one of the TCBs. This time is referred to as “__startup__”.