Using NI-DAQmx Simulated Devices to Develop without Hardware

Reported In

Reported In shows products that are verified to work for the solution described in this article. This solution might also apply to other similar products or applications.

Driver

NI-DAQmx

Other

NI-DAQmx Simulated Devices

Issue Details

I would like to develop or program my DAQmx code without having my hardware physically present or installed and I want to test my code and parameters to see if I get any errors, etc. What are NI-DAQmx Simulated Devices and how do I use them?

Solution

Using NI-DAQmx 7.4 or above, simulated devices can be used to develop and run an application without data acquisition (DAQ) hardware present in the machine.

Developing for Different Hardware Configurations

With simulated devices, you can develop applications for different systems or for different hardware configurations. Once the devices installed in the target system have been simulated on your development system, you can program them as if they were installed locally. Later, when you deploy to your production system the developed LabVIEW VIs will run on the installed hardware.

To develop VIs for another system or hardware configuration, please follow the instructions below:

On your development system, simulate the devices that are installed in the production system. Refer to the Simulated Devices tutorial for expanded details on creating simulated devices.

Note: For simulating C Series modules like the NI-9201 or NI-9234, you will need to simulate the cDAQ chassis the module will be in first. Then configure the simulated cDAQ chassis to have your desired modules.

Figure 1: Configuring a Simulated cDAQ Chassis

Rename the simulated devices to the same names as those on your production system. Using the Measurement & Automation Explorer (MAX), navigate to your simulated device and rename it (Figure 2):

Expand My System in the left tree.

Expand Devices and Interfaces.

Expand NI-DAQmx Devices.

Right click on each simulated device and select Rename.

Change the name of the device to the same name as on your production system.

Figure 2: Renaming the device in MAX

Write your LabVIEW VIs using the MAX names for your devices.

Deploy to your production system.

Devices Are Fully Simulated

A simulated device behaves similar to a real one (except for analog input, which is a simple sinusoid on simulated devices). If you try to perform an operation that isn't supported by the real version of that hardware, you will receive appropriate errors when executing a DAQ application with that simulated device.

For example, if you specify a sample rate of 1.5MS/s for a simulated PCI-6251 (which has a maximum sample rate of 1.25MS/s for one channel) you will receive the following error:

Error -200077: you have requested a sample rate that exceeds the maximum rate of that device.

For more information on NI-DAQmx Simulated Devices, refer to the NI-DAQmx Help and the Measurement & Automation Explorer Help for NI-DAQmx or see the Related Links below.

NI-DAQmx Help

Open NI-DAQmx Help Start»Programs»National Instruments»NI-DAQ»NI-DAQmx Help

Additional Information

Devices That Cannot Be Simulated

Certain NI-DAQmx devices cannot be simulated in MAX. In many cases it may be possible to simulate a similar device in place of a device that cannot be simulated. However, it is very important to keep in mind that the simulated device may have features not available on your own device.

Also, note that traditional NI-DAQ (Legacy) does not support the simulated device feature.