ClockConnection vs TriggerConnection in Data Acquisition Toolbox

4 views (last 30 days)
The matlab documentation on clock connection and trigger connection of the data acquisition toolbox didn't make it very clear to me the major difference between the two types of synchronization.
It seems that a trigger can only come from one source, but a clock not necessarily. Can any expert clarify on this?
I'd like to read out a digital input signal when an external trigger edge is registered by the PCI card (NI PCI-6221, supported by Matlab, my version is 2014a). I'm upgraded my Matlab to 2014a such that it supports clocked digital I/O like in the following example,
But unfortunately I haven't made it to work so far. There are a few errors. The major one is that "A channel that does not support clocked sampling was added to the session", and therefore I cannot set the s.Rate to anything different from the default value of 0. The example in the previous link showed that one can do that... To be more specific, I'm using a PFI port to read the digital input and PFI0 to register the trigger (from a delay generator attached to the connector block). The two ports are distinct and the my device works using the inputSingleScan() after setting up the session and channels.
I'm very grateful for any helpful suggestions!

Answers (0)

Categories

Find more on Simultaneous and Synchronized Operations in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!