LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Help Explaining Flow Meter VI

Solved!
Go to solution

After much tinkering I appear to have worked out an effective VI for use with a pelton/turbine type flow meter. The flow meter outputs a stream of pulses that

are being counted on the counter line of my 6501. Unfortunately this eureka moment has happened somewhat by chance and I am hoping someone 

would be kind enough to explain step-by-step or in very basic terms for the beginner (me) how the VI is operating, thank you.

 

Regards,

Ger

0 Kudos
Message 1 of 3
(2,982 Views)
Solution
Accepted by topic author GOB82

Ger,

 

Welcome to the Forums and to LabVIEW. 

 

If you have not already done so, please work through the online tutorials for Getting Started With LabVIEW. The answers to some of the questions you may have are probably in there.

 

A brief description of your VI:

1. The overall structure is a For loop. This runs for the number of iterations wired to the N terminal, in your case 5.

2. The loop timing is determined by the longest time required for any part of the code inside the loop to execute. On the first iteration the DAQ Assistant configures the counter and starts the measurement. On all subsequent  iterations it simply reads one count. On those iterations the 25 ms Wait will dominate.This VI runs about 40 iterations per second (for 5 iterations).

 

This means that the program will run about 5*25 ms = 0.125 s and then stop. If you are running it for more than 1/8 second by using the Run Continuously button, STOP. That is intended for certain kinds of troubleshooting only.  

 

3. The waveform chart and the Flow rate meter will only display the last value from the five iterations. (This also suggests that you are using Run Continuously) 

 

4. The shift registers in this VI do nothing. The upper shift register calculates the cumulative count from the flow meter, but the result is never used. The lower shift register has nothing wired to the left terminal inside the loop. It could be replaced by a terminal.

 

Suggestions:

 

1. To avoid the use of Run Continuously replace the for loop with a while loop. Add a Stop button on the front panel and wire it to the Stop it True terminal in the loop. Move the Waveform Chart and Flow Rate terminals inside the loop.

2. Check your pulse to flow rate algorithm. The time interval for the count must be considered.  For example if the counter records 25  pulses in 25 ms, that represents 1000 pulses per second. This is not what your VI will show.

3. Look at the Examples for code which uses counters.

 

Lynn

Message 2 of 3
(2,974 Views)

Great, thank you very much for the explanation and the suggestions, much appreciated.

0 Kudos
Message 3 of 3
(2,929 Views)