LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Timing help needed.

Hi. I have built a gaussian noise generator nad need some timing help. The VI needs to count time only when the signal is too low. Currently I have an Elapsed Time express VI instide a case structure. It begins timing when the signal drops just fine, but continues to count time until the program stops running even when the signal increases again. I'm not sure how to program an if and only if sort of situation for this. Any ideas would be wonderful, and I have attached the VI.

0 Kudos
Message 1 of 2
(2,105 Views)

My gut reaction is that you should not be using the "elapsed time.vi" to measure time.  You will get a very innacurate measurement. 

 

Instead, you should be looking at your raw data, and counting the number of samples that are below your threshold. 

 

But of course, if you are OK with innacuracy (which you might be ... depends on your application) then you should probably use a shift register to track when the value goes below your thrshold, and then add the elapsed time to the shift register.

 

You may also want to start here to learn more about structures.

http://www.medicollector.com
0 Kudos
Message 2 of 2
(2,064 Views)