Example Code

Generate Voltage Output From a File

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.

    Hardware

  • Data Acquisition (DAQ)

    Software

  • LabVIEW

    Driver

  • NI DAQmx

Code and Documents

Attachment

Overview

This example shows how to generate a voltage output from a file that contains the timestamp (in seconds) and the voltage values.

 

Description

This example shows how to generate a voltage output from a file that contains the timestamp (in seconds) and the voltage values. This example is meant for files with varying intervals between each timestamp.

 

Requirements

Software

  • LabVIEW 2012 or compatible
  • NI-DAQmx 9.5.5 or compatible

Hardware

  • NI Multifunction DAQ Device

 

Steps to Implement or Execute Code

  1. Configure the parameter for the right channel and device.
  2. Connect your hardware appropriately.
  3. Run the VI.

 

Additional Information or References

 

Generate Voltage from File.png

 

 

This example is not meant for deterministic signal generation. You will notice that each iteration of the loop will take about 1-2ms longer than the calculated time delay.

 

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

 

 

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