LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Measuring different values with different intervals

I have a program which is measuring temperatures every second (or how often I want it to) and writes this to a file. But now I want it to open a digital line to measure the current through a resistant and if the current is higher than a certain limit, the program should open another digital line. But I don't want it to open the digital line/measure the current so often because the resistant will get hot, so I want it to measure maybe every 15 minutes. How should I make the program measure these values in different intervals?

I am really a beginner in labVIEW, and i have no clue how to do this. If someone could give me any advice, even if it's only about where i can look to find a solution, I would be very greatful.
0 Kudos
Message 1 of 3
(2,697 Views)
Dear Mr. Potatohead 🙂

Are you aware that you can run two Labview vi's at the same time? This might be the simplest solution for you...especially when one function needs to run a lot more than the other. Otherwise, you can check out the Semaphore, Rendezvous, or Occurrence examples in the EXECUTION EXAMPLES of the help files. These all relate to starting a second vi or subvi when something happens. Good luck!

eric
Eric P. Nichols
P.O. Box 56235
North Pole, AK 99705
0 Kudos
Message 2 of 3
(2,697 Views)
On your front panel, you can have two numerics: one is the interval between temperature reads, the other is the interval between digital reads. If intervals are on the order of seconds (not milliseconds) you're probably better off checking the interval using Get Date/Time in Seconds rather than using Wait (ms). Add shift registers to your loop to save the last time read (one shift register for last temp read, another for last digital read). Each time through the loop, check if the current time (from Get Date/Time in Seconds on the Time & Dialog palette) is more than the specified interval from the last time read. If it is, take the reading and save the current time as the last time read to the shift register. Use separate case structures for the temperature
reading and the digital reading.
See the attached LabView 6.1 example.
0 Kudos
Message 3 of 3
(2,697 Views)