LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Conflict between the saved data and the sampling rate and samples to read using PXI 6070e

Hello, I am using PXI 6070e to read an analog voltage. I was sampling at 6.6 MHz and the samples to read were 10. So, that means it should sample 10 points every 1.5 um. The x-axis of the graph on the control panel was showing ns and us scale, which I think because of the fast sampling and acquiring data. I use "write to measurement file" block to save the data. However, the data was saved every 0.4 second and as 35 points data at the beginning of each cycle (e.g. 35 points at 0.4 sec and 35 at 0.8 sec, and so on) and there was no data in between. Can anyone help me how there are 35 reading points every cycle? I could not find the relation between the sampling rate and samples to read, to 35 points every 0.4 second!

 

Another thing, do I need to add a filter after acquiring the data (after the DAQ assistant block)? Is there anti-aliasing filter is built in PXI 6070e?

 

Thanks for the help in advance,

Alaeddin

0 Kudos
Message 1 of 6
(2,278 Views)

Care to share some of your code.  Otherwise we would be totally shooting in the dark.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 2 of 6
(2,276 Views)

Sure, Here is my code

 

Thank you

0 Kudos
Message 3 of 6
(2,274 Views)

I'm not seeing anything that points to this issue.  Your DAQ is set to continuous acquire.  I'm not sure if this is really what you want because your DAQ buffer will keep overwriting.  You probably just want to set to Read N Samples.

 

I'm not a fan of using the express VIs.  And since you are writing to a TDMS file, I would use the Stream to TDMS option in DAQmx.  If you use the LabVIEW Example Finder, search for "TDMS Log" for a list of some good examples.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 4 of 6
(2,265 Views)

You are expecting 10 samples every 1.5 us but your loop is taking a lot longer than that. You have at least a 100 ms wait in the loop and all of the code could actually be taking longer than that. I suspect you have a buffer overflow error but you don't have an error indicator wired up.

 

You cannot use continuous mode if your loop is slower than the time required to continuously read new samples from the buffer.

0 Kudos
Message 5 of 6
(2,264 Views)

Thanks for the help.. I am still not sure if I have to add a filter after the DAQ assistant block. Is anti alaising filter built in the card?

0 Kudos
Message 6 of 6
(2,248 Views)