Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

NI hardware USB-6215

Hi,

I am using NI hardware, USB6215 as an interface to received analog data (voltage 0 to 10V ) from machine output channel (output Angle data , 0 to 10V).

I use NI Max application software (test panel) to test the input voltage through analog input Channel 0, terminal selection using RSE.

i found that the data input to NI hardware is normal (data increase gradually).

In Labview program, i use DAQ assistance. I found the output data from DAQ, data pin is abnormal because the data increase not gradually, sometime have a big jump.

It means that something wrong in NI hardware or DAQ .

Can anybody can advise me how to find out the root cause. 

 

Thank you.

Best regards.

 

 

0 Kudos
Message 1 of 4
(1,501 Views)

99% of the time, the problem is not in the hardware but in the software developed to acquire from it. Almost any experienced LabVIEW developer would recommend keeping away from DAQ Assistant and learning to use the DAQmx drivers.

 

This is a good starting point for learning DAQmx drivers (skip the DAQ Assistant part) - https://www.ni.com/en-us/support/documentation/supplemental/06/learn-10-functions-in-ni-daqmx-and-ha...

 

Also, it is a best practice to attach the code to the discussion so others can easily understand and even debug than imagine the implementation based on your descriptions in words.

Santhosh
Soliton Technologies

New to the forum? Please read community guidelines and how to ask smart questions

Only two ways to appreciate someone who spent their free time to reply/answer your question - give them Kudos or mark their reply as the answer/solution
0 Kudos
Message 2 of 4
(1,473 Views)

Hi, Santhosh

 

I tried to used DAQmx to extract machine data. Attached the program code for your reference.

can you advice me why i can't get the data even there is no error shown when i run the program.

thank you.

0 Kudos
Message 3 of 4
(1,444 Views)

...but I'll bet you there's an error shown when you *stop* the program.   Your code *is* generating an error that you don't see until you click stop to end your loop and populate your error indicator.

 

Your first problem is trying to run 3 separate simultaneous AI tasks on a device that will only support 1.  The solution is to put your 3 channels into just 1 common task.  Just chain the channel config calls one after another to add them to the same task.  Here's how you could adjust your own code's config to do it:

 

Kevin_Price_1-1664285880537.png

 

 

That brings us to your second problem -- trying to keep up with a 2000 Hz acquisition while only reading 1 sample at a time in a software loop.  A better plan is to read ~ 1/10 sec worth of samples, i.e. 200 at a time.  You'll need to select a multi-channel multi-sample version of DAQmx Read, then you can specify the # samples to read at a time.

 

 

-Kevin P

ALERT! LabVIEW's subscription-only policy came to an end (finally!). Unfortunately, pricing favors the captured and committed over new adopters -- so tread carefully.
0 Kudos
Message 4 of 4
(1,424 Views)