Example Code

NI-FGEN: Output a Digital Pulse at the Start of Generation

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

  • Modular Instrumentation

    Software

  • LabVIEW

    Driver

  • Other

Code and Documents

Attachment

Overview

This example will show the user how to output a digital pulse at the start of a generation. 

 

Description

This could be used to synch up an external device. It is set to output the pulse to the PFI lines and the user can change this to internal outputs as well.

 

Requirements

Software:
  Labview 2012 (or compatible)
  NI-Fgen driver which is compatible with your hardware and version of LabVIEW
Hardware:
  NI Fgen device

 

Steps to Implement Code

1. Open the shipping example Fgen Basic Standard Function.vi which can be found in the NI Example Finder.

2. Drop down a Fgen Property Node and place it before the Initate Generation VI.

3. Now, select the property Started Event Output Behavior and Started Event Output Terminal.

4. Assign a pulse to the first property and you can find the value for the second property in Measurement & Automation Explorer under Device Routes.

 

Additonal Notes

You can easily modify this code to work with NI Scopes, and HSDIO cards.

 142.png

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

 

Applications Engineer
National Instruments

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