LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to create a set/restet timer using LV 7.0

one of my applications involves using a set/reset timer. when the timer is reset it should display the elapsed time in minutes and the real time at which start occured in hh:mm:ss format.Could you kindly help me out with this application?
awaiting your reply,
SRIKANTH
0 Kudos
Message 1 of 3
(2,623 Views)
Since you are talking about minutes, you can probably use software timing with sufficient accuracy. Any desktop OS can produce timing uncertainties on the order of hundreds of milliseconds. If that is adequate for your needs, then a simple software timer will work.

Start with a while loop. Put the Set and Reset buttons inside. When Set is pushed, read the Get Date/Time in Seconds function. Put the value into a shift register. When the Reset button is pushed, read Get Date/Time in Seconds again and subtract the value stored in the shift register. Exit from the loop and convert the difference to the desired display format. The value in the shift register is the start time. It is a good idea to put a short Wait(milliseconds) function inside your while loop so
that other parts of the program can execute while the loop is watching for the Reset.

Lynn
0 Kudos
Message 2 of 3
(2,623 Views)
Hello Srikant

Please, refer to this link. There is a timing toolkit that can be of help to you
http://www.calbay.com/timing/timingtoolkithelp.htm
Hope it helps
Alipio
---------------------------------------------------------
"Qod natura non dat, Salmantica non praestat"
---------------------------------------------------------
Message 3 of 3
(2,623 Views)