05-07-2010 06:00 PM
Hello I am trying to read in a temperature from a thermocouple and display it on a waveform chart and simultaneously I would like to write the data to a file at a significantly lower frequency. Currently I am sampling the DAQ at every .01s and I would like one sample to be written to the file every 2s. I was thinking of toggling the enable to the relay every 2s, but I am not sure how to go about doing that and I wouldn't be surprised if there is a standard way of doing this but I haven't been able to find it.
Thank You,
Miguel
Solved! Go to Solution.
05-07-2010 06:24 PM
If you are sampling every .01s and you want to write one sample every 2s, what about all the other samples taken? Do you just wish to discard them? So you will read 200 samples in 2 seconds. But you only want to write one sample. You can do this if you don't mind losing the other 199 samples.
You could use the elapsed timer function and wire the elapsed time output to a case structure. Put your write function inside the True case. Nothing in the false case. Be sure the set the timer to reset automatically. So every two seconds, the case will be true, and the write function will be called.
05-10-2010 12:24 PM
Thank You, yeah I don't need to keep the other 199 samples so this works.
-Miguel