Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Sample Timing Type USB 6216

Solved!
Go to solution

I am using a USB-6216; I'd like to synchronize a hardware-timed digital output stream with a hardware-timed analog output stream.  I understand that there is no dedicated digital I/O clock on the USB-6216, but this (very helpful!) page suggests that on an M-series device, I can use one of the analog clocks - e.g. "ao/SampleClock" - to clock out digital data:

 

http://digital.ni.com/public.nsf/allkb/51754212AD10BDCE862573BD007BFDD2

 

However, when I try to configure a digital task to clock along with "ao/SampleClock" (or "Dev4/ao/SampleClock", or "/Dev4/ao/SampleClock") using DAQmxCfgSampClkTiming, I get an error suggesting that I cannot use a sample clock for digital output tasks on this device:

 

DAQmx Error: Requested value is not a supported value for this property. The property value may be invalid because it conflicts with another property.
Property: DAQmx_SampTimingType
Requested Value: DAQmx_Val_SampClk
You Can Select: DAQmx_Val_OnDemand

 

I'm specifically trying to synchronize digital output and analog output, but the above page links to a very similar example doing the same thing for input:

 

http://zone.ni.com/devzone/cda/epd/p/id/4488

 

This example uses the same approach:

 

DAQmxErrChk (DAQmxCfgSampClkTiming (taskHandleDig,"/Dev4/ai/SampleClock",rate,DAQmx_Val_Rising,DAQmx_Val_FiniteSamps,sampsPerChanToAcquire));

 

When I run this with my USB-6216 (code unmodified other than changing the device name), I get exactly the same error.

 

Does the page above that talks about using this approach for M-series devices not apply to the USB-6216?  If so, what terms should I be looking for in specifications to understand whether this is supported or not?

 

Thanks!

 

-Dan

 

 

0 Kudos
Message 1 of 8
(4,723 Views)

Hi Dan,

 

This appears to be a limitation of the device.  The USB 6216 is a software timed device and can only run in On Demand mode.  Here is a similar forum post to this one:

 

http://forums.ni.com/t5/Multifunction-DAQ/Why-can-I-not-perform-continuous-sampling-of-port-0-on-USB...

 

Nick

 

Applications Engineer
National Instruments
0 Kudos
Message 2 of 8
(4,697 Views)

Thanks.

 

So on the page that talks about using the analog sample clock to drive digital I/O, which M-series devices is it referring to?  How would I know before buying a device whether it can do this?

 

Thanks!

 

-Dan

 

Message 3 of 8
(4,695 Views)

Dan,

 

You will want to check the Specifications page.  A device will need to be "hardware" timed, instead of just "software" timed.

 

Another way you can be sure to check is to use Measurement and Automation Explorer (NI MAX) to simulate a device, then create a task to try a type of sampling that you are interested in.  Here is an article on how to do this:

 

http://www.ni.com/white-paper/3698/en/

 

Nick

Applications Engineer
National Instruments
0 Kudos
Message 4 of 8
(4,677 Views)

Thanks... I think I was a little confused by the fact that the page I linked to above is specifically about the case where you have a hardware-timed analog path with a dedicated clock but you don't have a dedicated digital clock on an M-series device.  That sounds *exactly* like my situation, and the digital lines are not described as "software-timed" in the specs, but now I see that "static" means "software-timed" and that some other devices specifically say "hardware-timed".  All is clear now (though FWIW, if the term "static" just means "software-timed", it would be great to see that terminology rev'd for a clearer comparison with "hardware-timed").

 

Thanks!

 

-Dan

 

0 Kudos
Message 5 of 8
(4,674 Views)

Actually one more question... some devices refer to the digital I/O as "clocked"... is this another word for "hardware-timed"?  

 

The 6281, for example, says "clocked":

 

http://sine.ni.com/nips/cds/view/p/lang/en/nid/209153

 

...but the 6341 says "hardware-timed":

 

http://sine.ni.com/nips/cds/view/p/lang/en/nid/209069

 

What's the difference?

 

Thanks!

 

-Dan

 

0 Kudos
Message 6 of 8
(4,673 Views)
Solution
Accepted by topic author dmorris

As far as timing goes, digital I/O lines on NI's Multifunction DAQ devices fall into one of three categories:

 

I.  Software-timed only

      • "Legacy" multifunction devices (E Series, B Series)
      • bus-powered USB M Series (621x).
      • 6008/6009

 

II.  Hardware-timed with no internal timing engine (you'll see this referred to as "correlated" in some places on NI's website).

      • M Series (622x, 625x, 628x)
      • "Legacy" cDAQ (9172)

 

III.  Hardware-timed with an internal timing engine.

      • X Series
      • current-gen cDAQ

 

I have no explanation for the inconsistent terminology used across various NI marketing pages, "hardware-timed" and "clocked" are synonyms in my book.  

 

It would have been nice to have more of a distinction in product naming between the 621x and the 622x/625x/628x M Series devices.  I'd imagine a good deal of documentation was written referring to general "M Series" devices before the 621x came into existence and now is misleading and needs an update (they have been out for years though so that's not exactly an excuse...).

 

 

Best Regards,

John Passiak
Message 7 of 8
(4,664 Views)

Super-helpful.  This is exactly what I needed.  Thanks!

 

 

0 Kudos
Message 8 of 8
(4,654 Views)