LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

multicard latency issue while sampling

I am currently using the

cdaq 9172
with
NI-9401
NI-9211
NI-9205

We are trying to sample 2 channels on 9211 at about 1khz of only a single sample each. In addition, 9205 is being sampled at 1khz with 100 samples.

Running labview 8.2

When trying to graph all of this data, alot is being lost.

We are running this on a 3.2 Ghz windows xp machine with 1 gig of memory.

Typically, the channel being sampled on 9205 takes control and samples at the desired rate, and all outputs are observed. The 9211 seems to have a lower priority and barely samples at all (mostly 0 points).

Message Edited by hanssjosef on 04-21-2007 01:29 PM

0 Kudos
Message 1 of 9
(3,239 Views)
Hey hanssjosef,

Thanks for contacting National Instruments support.  What version of DAQmx are you using?  Also are you using the DAQ Assistant or the DAQmx API VI's?  The 9205, and 9211 should be using the same timing engine, and thus sampling at the same rate.  This sounds like this may be more of a software problem.  If you could provide more information on how you are coding this, that would be helpful.

Regards,
Kenn North
Principal Product Manager - Search, Digital Analytics
http://ni.com/search
0 Kudos
Message 2 of 9
(3,206 Views)
-Kenn
 
I am using the DAQ assistant, but I am unsure of what version of DAQmx I am running. How can I find that out?
 
Attached is our VI we have created thus far.
 
The Load cell uses channel A0 on the 9205, and the two heaters are using two channels on the 9205.
 
-Joe
0 Kudos
Message 3 of 9
(3,193 Views)
Hey Joe,

So I have made a small example of how to accomplish a read on two modules in the same chassis.  I have included two Create Channel vi's so that you can control the min and max for each channel seperately.  Your vi is using two DAQ assistants, which should give an error since you are trying to run the tasks on the same chassis.  This example could be exapanded to include the digital writes you making to the 9401 in the same while loop.

Let me know if you have further questions.

Regards,

Message Edited by Kenn N on 04-23-2007 05:25 PM

Kenn North
Principal Product Manager - Search, Digital Analytics
http://ni.com/search
0 Kudos
Message 4 of 9
(3,186 Views)

Thank you for the sample. It has us going in the right direction now. We are still experiencing some difficulties though, with the same problem, but less latency.

We have tried seperating the two input sources, but it is not working. Any ideas?

We are ultimately looking to sample the 9211 and 9205 at different rates to work out latency.

 

Message Edited by hanssjosef on 04-24-2007 04:28 PM

0 Kudos
Message 5 of 9
(3,178 Views)
Hey Joe,

Glad to see you are getting closer.  However, your main issue is trying to create to Analog Input tasks on the same chassis.  This cannot be done.  You must sample at the same rate for all modules as their is only one timing engine.  This is why the example I posted had two create channel vi's, you can specify different voltage ranges and such, but the sample clock is shared across the modules. 

Let me know if you have further questions.

Regards,
Kenn North
Principal Product Manager - Search, Digital Analytics
http://ni.com/search
0 Kudos
Message 6 of 9
(3,167 Views)
Does the DAQmx Timing block that all three channels are connected to constitute as being one timing engine? If not, is there a means of having two different sample clocks (e.g., one clock that is shared by two thermocouples, and another attached only to a analog input) so we can sample at different rates?
 
The thermocouple (9211) is scanning at a slower sampling rate than the analog inputs (9205). Since there connected to the same sample clock, is there a way to prioritize the modules such that the 9211 isn't holding us back?
0 Kudos
Message 7 of 9
(3,165 Views)
Hey Joe,

There is only one timing engine.  In fact if I run your program I get an error that the hardware is reserved.  Both modules will latch data at the same time at the same rate with the same clock.  There is no way around this.  The only way to run them at different rates is to use two seperate chassis.

Regards,
Kenn North
Principal Product Manager - Search, Digital Analytics
http://ni.com/search
0 Kudos
Message 8 of 9
(3,152 Views)
We have been able to resolve the issue. Attached is a copy of our file, with proper control of the bus.
0 Kudos
Message 9 of 9
(3,135 Views)