LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Cont Acq to File (scaled) results in unexpected behavior

I am writing an application based on the "Cont Acq to File(scaled).vi example". The DAQ card on my system is the PCI-MIO-16E-4. I am acquiring only 1-chanel with the following data acquisition parameters: Scan Rate = 30000, Buffer Size = 300000, Number of Scans to Read at a time = 1000. Since each scaled sample is 4 bytes and my scan rate is 30000 scan/sec, I would expect that with an hour of acquisition my file size would be approximately 432 MB (4*108000000 samples/hr). However my data file after an hour of recording only grows to about 1.2 MB. So i am assuming that i've lost lots of data. I am not getting a "buffer overflow" error and my "scan backlog indicator" averages about 2 during the entire hour...so i am
assuming that i am reading the data fast enough. Help
0 Kudos
Message 1 of 4
(2,752 Views)
Hi Lancer.
I can not figure out what is going on without code.
Please, post your code and I will test it in my DAQ card. Actually, using those parameters, you should have no problem for real time adquisition.

Alipio
---------------------------------------------------------
"Qod natura non dat, Salmantica non praestat"
---------------------------------------------------------
0 Kudos
Message 2 of 4
(2,752 Views)
Thanks for your response. I found the problem on my program...but it now leads to more questions. The problem was that the output from the "AI Read" (a 2-D array) was wired into the input of "Indexed Array" but instead of indexing column 0 (i needed to extract chan 0) i instead was indexing row 0. The output from the "index array" is wired into my "File Write". After making the correction, my data file is growing at the right size. Now my question is what was written to file when the row 0 was indexed instead of column 0(the data seemed to be the correct value but lots of missing data)?
0 Kudos
Message 3 of 4
(2,752 Views)
Hi Lancer.
Good job. You solved the problem.
Now, indexing row 0, you were saving 1 value out of 1000 ( one per scan read). The value is correct, but you were missing 999 values per reading.

Hope this helps.
Alipio
---------------------------------------------------------
"Qod natura non dat, Salmantica non praestat"
---------------------------------------------------------
0 Kudos
Message 4 of 4
(2,752 Views)