Example Code

Using Elapsed Time VI to Measure Time Above a Thresholding Value

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

Overview

The following Example shows how to use the Elapsed Time VI to compare the amount of time that a set of data remains above or below a certain thresholding value.

Description

Because this example is using a random number generator as the data, we expect the amount of time below the threshold to follow basic statistical theory. For example, a threshold value of 50 for a range of data from 0 to 100, the amount of time spent below the threshold should be closed around 50%.

 

Requirements
LabVIEW Base Development System.

 

Steps to Implement or Execute Code
1. Select a Threshold value between 0 and the maximum value.
2. Select a maximum value.
3. Run the VI.


Additional Information or References

 Snippet 10742.png

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

Tejinder Gill
National Instruments
Applications Engineer
Visit ni.com/gettingstarted for step-by-step help in setting up your system.

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

Comments
fille
Member
Member
on

This is just what i am looking for but where can i download it, I already tried to rebuild it in labview but it doesn't work as it supose to.

Kind regards