Open topic with navigation
Debugging Applications in the RTSS Environment
RTX applications can be debugged using the familiar Microsoft Visual Studio development environment. You can debug:
- RTSS process – the executable code that performs your real-time tasks, which consist of one or more threads.
- RTDLL – A real-time dynamic link library that can be used with LoadLibrary. After the RTDLL is loaded, the GetProcAddress function is used to retrieve the addresses of the exported DLL functions. The process calls the exported RTDLL functions using the function pointers returned by GetProcAddress.
Running an RTSS Application in the Debugger
RTX provides a Visual Studio integrated base debugger and launch provider that is used by Visual Studio when debugging Real-time applications. RTSS applications are started by the RTX loader instead of the Windows loader. For this reason, when debugging RTSS applications in Visual Studio, the following options in the Debug pull-down menu (which would assume Windows control) are not supported:
- Attach to Process
- Detach All
- Break All
- Data Breakpoints
Build Configurations
Four configurations for creating applications are generated in Visual Studio when you create a project using the RTX Application template:
- RTSSDebug – Real-time application that has debug flags enabled
- RTSSRelease – Optimized Real-time application that does not contain additional debug information
- Debug – Win32-bit application linked to RTX that has debug flags enabled
- Release – Win32-bit application linked to RTX
NOTE: We recommend that you select the RTSSDebug configuration of the application you want to debug, as this configuration is set up to generate debug information.
Real-Time Debuggers
When you create a RTSS application with the RTX Application template, new debugger options are added to Visual Studio:
- IntervalZero Remote Real-Time Debugger – use to debug RTSS applications on a target system remotely. See Remote Debugging with Visual Studio for more information.
- IntervalZero Real-Time Debugger – use to debug RTSS applications. Note that this debugger is automatically selected when the RTSSDebug configuration of the project is selected.
Set Debugging Properties
Optionally, you can set debugging properties for the application you want to debug. You can:
- Choose to override default memory allocation behavior to allocate memory from the RTX local memory pool, which uses deterministically allocated memory.
- Set the ideal processor on which the main thread of the debugged process will run.
- Set the affinity mask that specifies the processor(s) on which the debugged process will run.
See Setting Debugging Properties in Visual Studio for more information.