Example Code

VI Timing using Functional Global Variable 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

Download All

Overview
This example is a functional global variable (FGV) within a loop that is called only once. Each time user call the subVI, user can input a enum state in order to start the timer, get the elapsed time.

 

Description
This example can use as subvi to get the time elapsed.

 
Requirements

  • LabVIEW 2012 (or compatible)


Steps to Implement or Execute Code

 

  1. Insert this vi as subvi in main VI. 
  2. This VI will show calculate the time elapsed.

 

Additional Information or References
VI Block Diagram

 1.png

 

 

 **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.

Comments
Alex5
NI Employee (retired)
on

Bonus tip: you can use this vi as a sub vi in a custom error line probe. Makes it super easy to place and remove.