From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

stopping two while loop simultaneously and timestamp issues

Hello,

I have a few problems and most of the examples in the forms are not available to me as I use labview 7.0 and am inexperienced in programming.

 

First -  I would like to stop 2 while loops simultaneously using one stop button on the front panel.

Second - Make the time stamp from the Tick Count (ms) display a value in hours minutes seconds milliseconds.

 

I am currently obtaining data from 4 channels of a thermocouple and yanking specific measured values from an oscilloscope. My oscilloscope sputters out value at an approximate freq of 1 Hz while I am getting 4 channels at 4 Hz from my thermocouple. I am currently writing this data using the write characters to file after building an array and converting it to a spreadsheet string. This works. I do not know how to include my second requirement of a timestamp after I format it into a string into this file.

 

I’ve attached a picture of what the major portion of my VI looks like. Looking forward to some assistance.

Thanks

Adi

0 Kudos
Message 1 of 4
(2,524 Views)
Try this thread for stopping the loops.
 
 
There is a Get Data/Time in Seconds function that returns a timestamp.
0 Kudos
Message 2 of 4
(2,505 Views)
As explained in the on-line help, you cannot convert the tick count to a real-world date or time. It's essentially the number of milliseconds since the pc was booted. If you were to set your DAQmx Read to return waveform data, you would automatically get timestamp information included. Outside the loop, you could use the tick count to get a start time and then inside, subtract this from the current tick count. You could also use Get Date/Time in Seconds. To stop one loop from another, the easiest thing is to wire a local variable of a single stop Boolean to the termination terminal of the second loop. Your stop button has to be a non-latch type of mechanical action.
0 Kudos
Message 3 of 4
(2,502 Views)
Thank you both this works perfectly.
0 Kudos
Message 4 of 4
(2,472 Views)