Debugging Measurements from External Applications in InstrumentStudio
- 已更新2026-07-23
- 閱讀時間為 4 分鐘
Debugging Measurements from External Applications in InstrumentStudio
Use the debug mode in InstrumentStudio to monitor and control devices that are in use by an external application.
Overview
You can use debug mode to monitor and troubleshoot devices that are in use by an external application, such as LabVIEW, TestStand, or a C, C++, .NET, or Python application.
In debug mode, InstrumentStudio does not communicate directly with hardware. Instead, it connects to device sessions that are owned by the external application.
This behavior allows you to inspect and modify device configuration while the external application is running.
For information about how measurement plug-ins execute and return data, see Understanding Measurement Plug‑In Execution.
How Debug Mode Works
When you use debug mode, InstrumentStudio connects to an existing device session created by an external application.
What InstrumentStudio does:
- Reads data from the session
- Displays configuration and measurement results
- Optionally allows limited control of the session
What InstrumentStudio does not do:
- Start or own the session
- Control when measurements execute
- Override all device operations
The external application remains the owner of the session and controls execution.
Using Debug Mode
A device opened in Debug mode starts in Monitor mode. In Monitor mode, you can observe device behavior and measurement activity without modifying the device configuration.
To modify supported device settings, switch to Control mode by clicking Control. To return control to the external application, click Monitor or resume execution in the external application.
To debug a device used by an external application, complete the following steps.
- Start the external application and open the device session.
- Open InstrumentStudio.
- Create or open a panel for the device.
You can use the Debug command on the Home screen to locate devices that are available for debugging.
When InstrumentStudio detects that an external application owns the device session, the panel enters Monitor mode.
In Monitor mode, you can:
- Observe device behavior.
- View configuration values.
- View measurement results when available.
To modify supported device settings, complete the following steps.
- Pause execution in the external application if necessary.
- Click Control.
- Inspect or adjust the device configuration.
InstrumentStudio transitions to Control mode.
To return control to the external application, click Monitor or resume execution in the external application.
What Data You Can See
The data available in debug mode depends on how the external application interacts with the device.
InstrumentStudio can display:
- Device configuration values
- Session state
- Measurement results that the external application reads or fetches
In most cases, measurement values update only when the external application calls a read, fetch, or measure operation.
For some supported devices, InstrumentStudio may display live updates. See Live Measurement View.
When Debug Mode Behaves Differently
Debug mode behavior depends on the external application, device configuration, and operation mode.
You may observe the following behavior:
- Measurement values do not update continuously
- Some controls are unavailable or read-only
- Changing settings may affect execution in the external application
- Control is limited when the external application actively manages the device
These behaviors occur because the external application owns the device session.
Limitations and Unsupported Scenarios
Debug mode does not support all device types, configurations, or operation modes.
Examples include:
- Sweep mode for some SMU panels
- Script or sequence modes for certain waveform generators
- Streaming or list configurations for RF signal generators
For a complete list of device-specific limitations, see Limitations of Debug Mode.
Performance Considerations
Enabling monitoring or control may affect application performance.
- Monitoring may increase communication between InstrumentStudio and the session
- Control mode may interrupt or alter the execution flow
- Debugging active measurements may reduce throughput
Use debug mode only when you need to inspect or troubleshoot behavior.
Troubleshooting
If debug mode does not behave as expected, check the following:
| Possible Cause | Action |
|---|---|
| No active session | Ensure the external application has opened the device session. |
| Session is not accessible | Verify that the device session supports shared access. |
| Data does not update | Ensure the external application is calling read, fetch, or measure operations. |
| Limited control or read-only settings | Verify that the external application is not actively controlling the same settings. |
The following sections provide additional information about debug mode workflows, configuration options, troubleshooting, and device-specific limitations.