02-08-2007 05:19 PM
02-08-2007 05:26 PM - edited 02-08-2007 05:26 PM
Wire a TRUE to the "To UTC" input of "seconds to Date/Time". If you don't, there will be an offset depending on your timezone setting. 🙂
(You probably also want to add a small delay inside your loop. Since you are only interested in seconds, a 1000ms delay would be plenty. Right now you are remeasuring the time every nanosecond or so, consuming all CPU resources for nothing useful. :o. )
Message Edited by altenbach on 02-08-2007 03:29 PM
02-08-2007 06:04 PM - edited 02-08-2007 06:04 PM
(A) To place a 1000ms wait inside the loop, then place a simple indicator at the [i] terminal. Set the indicator to relative time format with HH:MM:SS. Voila!(B) If you need s, m, h in seperate indicators, just do a few simple calculations(C) If you don't trust the loop delay, maybe because you do complicated calculations that might take longer than a second in the same loop, Get the elapsed time from the tick count difference.
Message Edited by altenbach on 02-08-2007 04:05 PM
02-08-2007 07:42 PM
That was embarassingly simple to fix - duh! You suggest good alternatives - I use the counter as a part of a larger program where a user can measure, record and chart the temperatures of thermocouples. We can have anywhere from 1 to 100 thermocouples - if reading just 5 TC's the scan goes very quickly, but if you are reading 90 TC's it takes much longer to scan - That's why I like taking the difference of the actual clock time.
Thanks - Paul