Overview
This example explain how to use two different rates to read data from a DAQ device (waveform format) and write these data to a file in the HD.
Description
Using a Producer/Consumer structure, DAQmx reads data from the card buffer at one rate, and this information is written in a file slower (3 times slower in this example, but same structure can be use to write XX times slower just modifying few things). The example “Producer/Consumer pattern :: Read Double data from a device and write these data to TDMS file at two different rates.” write information 11 times slower.
Note that DAQmx also supports writing to TDMS directly from the API.
Requirements
Software
- LabVIEW 8.2 or compatible
- DAQmx 8.3 or compatible
Hardware
- Most supported DAQ devices
Steps to Implement or Execute Code
- Select a single channel from a DAQ device in the control “Physical Channel” inside Channel Parameters group.
- Set the Max and Min value for this channel, the “Sample Rate” and the number of “Samples to Read” per iteration.
Additional Information or References

**This document has been updated to meet the current required format for the NI Code Exchange.**