LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Need help with DAQ assistant

Hello there,

I am new to LabVIEW, so, I am not sure if something is wrong with my software or with the parameters I had given for my program. 

I am using DAQ assistant for data acquisition, collecting data from an accelerometer. I had configured my DAQ assistant to collect 1000 samples with a rate of 100 Hz, in N sample mode. So, I am expecting the program to collect 1000 samples in 10 seconds and stop the collection process. But instead I would get 1000 samples in 0.605 seconds and then the program would stop collecting data. 

I would like to know what the issue is here, so, it would be helpful if anyone could tell me what the issue is. 

(Find my code and images in the attachments) 

Download All
0 Kudos
Message 1 of 9
(2,651 Views)

It's a bad idea to try to collect 10 seconds worth of data.  It is too close to the default timeout of 10 seconds for DAQmx functions.

 

What DAQ device are using?  Not all devices can handle any given rate.  Some are only able to acquire at a limited set of rates.  So you might think you are acquiring at 100 Hz, but it will be coerced to something else like 166 Hz if that is the closest rate the device supports.

0 Kudos
Message 2 of 9
(2,635 Views)

I am using NI cDAQ-9174 for the data acquisition.

As I am new to LabVIEW,  I am not familiar with the ''time out'' parameter, so, if possible try to give me some details regarding this too.

And even though if it's acquiring data at 166 Hz, why is it taking only 0.605 seconds to get 1000 samples?

Even if I use 1000 samples with 1000 Hz rate, it would still do the same.

0 Kudos
Message 3 of 9
(2,631 Views)

In addition to what RavensFan said, you have two channels in the task and you're acquiring 1000 samples per channel, which is 2000 samples total.  Even if you were actually acquiring at 100Hz, this would take 20seconds to complete, not 10. 

aputman
------------------
Heads up! NI has moved LabVIEW to a mandatory SaaS subscription policy, along with a big price increase. Make your voice heard.
0 Kudos
Message 4 of 9
(2,628 Views)

I have faced the same issue with single channel, it would take only 0.605 seconds to acquire 1000 samples. (Look at the attachments)

And if you are saying that it would take 20 seconds to get 1000 samples from each channel, how does it work, will it take samples in series manner instead of parallel acquisition. If so, it would give me false data regarding the system.

Download All
0 Kudos
Message 5 of 9
(2,621 Views)

What module are you using in the CDAQ?  I looked up the NI 9234 acceleration module and the lowest rate it supports is 1.652 KS/s.  At 2000 samples, this would equate to 1.2 seconds (or 0.6 seconds per channel). 

aputman
------------------
Heads up! NI has moved LabVIEW to a mandatory SaaS subscription policy, along with a big price increase. Make your voice heard.
0 Kudos
Message 6 of 9
(2,619 Views)

I am sorry, I am not sure what you meant by ''module''.

0 Kudos
Message 7 of 9
(2,616 Views)

The cDAQ is a chassis that accepts modules for acquiring various signal types.  NI 9234 is an example of one that will acquire accelerometer signals.  Look at the specifications for the specific module that is used in your cDAQ to find the minimum sampling rate.

  2018-11-29_12-32-30.png2018-11-29_12-30-31.png

aputman
------------------
Heads up! NI has moved LabVIEW to a mandatory SaaS subscription policy, along with a big price increase. Make your voice heard.
0 Kudos
Message 8 of 9
(2,613 Views)

@vineeth2895 wrote:

...will it take samples in series manner instead of parallel acquisition. If so, it would give me false data regarding the system.


Again, this would depend on your device.  The device I reference above (NI 9234) has simultaneous sampling mode but not all devices support that.  

aputman
------------------
Heads up! NI has moved LabVIEW to a mandatory SaaS subscription policy, along with a big price increase. Make your voice heard.
0 Kudos
Message 9 of 9
(2,583 Views)