LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Hardware trigger for 6602

I would like to use a PCI-6602 (or other TIO device) to measure the
period on one pulse train and simultaneously measure the time between
a leading edge on this pulse train and the next leading edge of
another pulse train. So far this should not be a problem. But I want
to make sure both measurements start with the exact same pulse from
the first pulse train. I thought I would be able to use the same
hardware trigger to start both measurements but so far LabView DaqMX
tells me that I can't do that. So the question is can it be done and
if so how. Thanks to all you NI staff and others that monitor such
questions and provide help to the community.

TJW
0 Kudos
Message 1 of 5
(2,846 Views)

Hi TJW,

In order to start two tasks simultaneously, we will want to set the arm trigger. An example of this, although more complicated than you need, is Meas Angular Position-Buffered-Cont-Ext Clk-Arm Start Trig.vi (Help >> Find Examples… >> Hardware Input and Output >> NI-DAQmx >> Counter Measurements >> Position). This is a good example of how to start multiple tasks together, along with assigning the property nodes for the arm trigger.

David L.
Systems Engineering
National Instruments
0 Kudos
Message 2 of 5
(2,832 Views)
David,
Thanks for the pointer to the example. I initially got an error message when I tried it but that was just an oversight (forgot to change the polymorphic DACmx Timing to Implicit; duh) so if you see another message  from me about the error you can ignore it. This should do the job.
TJW
 
0 Kudos
Message 3 of 5
(2,811 Views)
Thanks David, but when I use the example you mentioned and change the
first task to measuring pulse width, the second task to measuring the
time between rising edges on two pulses, and eliminate the third task,
when the vi gets to the start task, an error "Invalid timing type for
this channel" is generated on each task. Are you sure this can be
done under DAQmx?

TJW


On Thu, 7 Jun 2007 19:10:07 -0500 (CDT), David L. <x@no.email> wrote:

>Hi TJW,
>
>
>
>
>In order to start two tasks simultaneously, we will want to set the arm trigger. An example of this, although more complicated than you
>need, is Meas Angular Position-Buffered-Cont-Ext Clk-Arm Start Trig.vi (Help
>&gt;&gt; Find Examples? &gt;&gt; Hardware Input and Output &gt;&gt; NI-DAQmx
>&gt;&gt; Counter Measurements &gt;&gt; Position). This is a good example of how
>to start multiple tasks together, along with assigning the property nodes for
>the arm trigger.
0 Kudos
Message 4 of 5
(2,781 Views)

Hi TJW,

The reason you are getting the DAQmx timing error is because performing 'period' and 'two edge separation' counter tasks both require either 'Implicit' or 'On-Demand' timing, not 'sample clock'. Attached is the example program, modified so that both counter tasks use implicit timing, along with the 'arm start trigger', assuring that the tasks will both start at the same time when the trigger occurs. Also, the picture below helps explain what clock mode is used for each type of trigger task.  (see picture and details at bottom of picture) This information can be found in the NI-DAQmx help (Start >> Programs >> National Instruments >> NI-DAQ), following the tree seen in the left-hand side of the picture.


Message Edited by David L. on 06-10-2007 10:20 PM

David L.
Systems Engineering
National Instruments
0 Kudos
Message 5 of 5
(2,772 Views)