Remote Debugging

With LabWindows/CVI, you can use one computer to debug an application that is running on a different computer. For example, you can debug an application on a target computer with a specific hardware or software configuration that would be inconvenient or impossible to recreate on the local development computer. The debugger, which is on the local computer, and the debuggee, which is on the target computer, communicate over a TCP/IP connection.

Note Note  You do not need to follow the steps in this topic to debug RT applications.

Use the LabWindows/CVI Remote Debugger utility to set the TCP/IP connection settings from the target computer and the New Remote Debugging Target dialog box to set the connection settings from the local computer.

Complete the following steps to debug an application remotely:

  1. Create a debuggable DLL or executable from a LabWindows/CVI project.
  2. Copy the DLL or executable to the target computer.
    Note  Instead of copying the file, you can share on the local computer the folder containing the application. If you do this, it is not necessary to copy the executable to the target computer each time you rebuild it.
  3. Verify that the LabWindows/CVI Runtime and any support files the executable requires at run time are installed on the target computer.
  4. Copy the LabWindows/CVI Remote Debugger utility, RemoteDebugger32Bit.exe or RemoteDebugger64Bit.exe depending on the configuration you are debugging, from the LabWindows/CVI bin folder to the target computer. Run the utility on the target computer. You must leave the utility running during the remote debugging session.
  5. Use the Name/IP address of the CVI environment option on the LabWindows/CVI Remote Debugger utility to specify the network address of the computer that is running LabWindows/CVI. You can enter a machine name or an IP address. Use the Network port of the debug session option to specify the network port on which LabWindows/CVI accepts network connections from debuggees.
  6. On the local computer, select Run»Select Execution Target for Debugging»New Execution Target to open the New Remote Debugging Target dialog box, which you use to configure settings for a new target computer. The port number you specify for the target must match the port number you specified in the LabWindows/CVI Remote Debugger utility.

    You also can select an existing target from the Run»Select Execution Target for Debugging submenu.
  7. On the local computer, specify the absolute path to the application you are debugging on the target computer in the Program name field of the Specify Executable and Command Line dialog box. The path must be a valid absolute path on the target computer.
  8. On the local computer, select Run»Debug to debug the DLL or executable. LabWindows/CVI attempts to connect to the debugger on the target computer and attempts to launch your application. If the connection succeeds, you can debug the application running on the target computer from the local computer. The debugging features that are available for standard local debugging are available for remote debugging.

    If the connection does not succeed, LabWindows/CVI displays an error message.

Complete the following steps to disable remote debugging and debug a local application:

  1. Open LabWindows/CVI on the local computer and load the project from which you created the DLL or executable you want to debug.
  2. On the local computer, select Run»Select Execution Target for Debugging»Local desktop computer.
  3. On the target computer, click Disable remote debugging in the LabWindows/CVI Remote Debugger utility.


Not Helpful