Example Code

Acquire Waveforms and Resample them using LabVIEW

Products and Environment

This section reflects the products and operating system used to create the example.

To download NI software, including the products shown below, visit ni.com/downloads.

    Software

  • LabVIEW

Code and Documents

Attachment

Description

1. Overview

This example shows how to acquire waveforms in one loop, while reading those same waveforms and resampling them for display in a different loop.

 

2. Description

Using a producer-consumer architecture. The example shows a producer loop that generates (or acquires) waveforms and sends them to the consumer loop by using a Queue. In the consumer loop, the program resamples the waveforms according to the selected decimate rate to later show them in a chart.

 

3. Requirements

  • NI LabVIEW Professional Development System 2012 or compatible.


4. Steps to Implement or Execute Code

  1. Download and Run the VI.
  2. Select a decimation rate.
  3. Observe how the waveform appearance changes as you change its sampling rate.
  4. Press the stop button when done.

 

5. Additional Information or References

 

Acquire waveforms and resample Screenshot.PNG

 

**The code for this example has been edited to meet the new Community Example Style Guidelines.**

Stephen B

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.