08-04-2013 12:50 AM
Hello
The module that I am using has a minimum sampling rate of 1613 s/sec. I am using the write to measurement express vi for writing the acquired data. I need only 4 samples per second to be written into the TDMS file while I am doing a continuous acquisition. Can anyone tell me hoe to do that? If you provide an example vi that would be very helpful
Thanks
Solved! Go to Solution.
08-04-2013 03:42 AM
@wisjaf12 wrote:
Hello
The module that I am using has a minimum sampling rate of 1613 s/sec. I am using the write to measurement express vi for writing the acquired data. I need only 4 samples per second to be written into the TDMS file while I am doing a continuous acquisition. Can anyone tell me hoe to do that? If you provide an example vi that would be very helpful
You can set the sampling rate (of DAQ) to say 10000 samples/second (using DAQmx Timing.vi)and then in the DAQmx Read.vi set 'number of samples per channel' input to 2500 samples. So the code will read 2500 samples every 250ms and then you can take the mean of those 2500 samples.
Example is also attached.
08-04-2013 12:41 PM
moderator1983
I would like to thank you too much for your interest. In the example you sent, you will only be reading on the chart 1 sample every 250 ms. However, I want to be able to read all the acquired samples on the chart but to WRITE only 1 sample every 250 ms. Imaging that there is a (Write to measurement express vi wired into the data output line along with the chart. Is it going to be correct if I just remove the mean vi from the reading chart and wire it to the write to measurement express vi? Can you please just modify the example so that it can do this?
Regards
08-04-2013 12:58 PM
@wisjaf12 wrote:
In the example you sent, you will only be reading on the chart 1 sample every 250 ms. However, I want to be able to read all the acquired samples on the chart but to WRITE only 1 sample every 250 ms. Imaging that there is a (Write to measurement express vi wired into the data output line along with the chart. Is it going to be correct if I just remove the mean vi from the reading chart and wire it to the write to measurement express vi? Can you please just modify the example so that it can do this?
Yeah you're right, if you want to plot every sample, you can connect the array data directly to the chart and the output of Mean, you can connect to the write to measurement express vi.
08-04-2013 01:06 PM
moderator1983
Thank you so much that was really helpful
Best Regards