03-26-2010 03:19 PM
Hi
I would like to collect N-samples of data (for example 10) and average those values and then place the averaged value in a graph as well as dumped to a file. What is the best way to do this that maintains a fast sampling rate?
Thanks!!
03-26-2010 03:29 PM
1. Acquire 10 samples.
2. Pass data into a queue. Have parallel while loop dequeue. This is producer/consumer architecture.
3. In consumer loop, dequeue and write to file.
What kind of sampling rate are you looking for?
03-26-2010 04:13 PM
03-26-2010 04:17 PM
So write to a file at once/second then? That isn't too bad. I don't have any sample code. But it is not that complicated.
What part are you stuck on? It sounds like you may never have used LabVIEW before. I would recommend you start here. How to Learn LV
03-29-2010 11:44 AM
Here are a couple of links you may find useful.
The first is an example of how to acquire and write to a TDMS file using producer consumer.
The second is an example on how to acquire, graph and average data
You can take parts from both examples and combine them to suit your requirements.
Hope this helps!