Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

cDAQ task pause trigger routing

I have two continuous HW timed tasks that I would like to be able to start and stop using HW triggers.  I am current using a conventional digital start trigger usinga PFI line.  Unfortunately there does not seem to be a stop trigger so the next best thing would be to use the pause trigger.  I have a cDAQ 9174 and would like to use backplane signal routing to connect a counter output to my two task pause trigger inputs.  The counter output is prefered since I would like the tasks to stop (pause) when a edge counter reaches its terminal count.  I have looked at the advanced I/O Signal options and it appears that many backplane signals are available but I am stumped on the implementation, any help would be greatly appreciated.

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

Hi viScience,

 

What parts of implementation are you stumped by?  If it's pause triggers in general, here's a white paper.  If it's something more specific, can you give more details about what your current code is?  The more info/VIs you can give the better!

Ashley G.
Senior Applications Engineer | RF & Wireless Communications
0 Kudos
Message 2 of 8
(4,638 Views)

Its the part about cDAQ backplane signal routing.  It seems like it should be possible to internally route the output of a cDAQ counter to the pause trigger of a task without having to use an external PFI line.  That is what I cannot figure out.

0 Kudos
Message 3 of 8
(4,633 Views)

Edit:  Sorry, I just reread your post and realize you were asking for something different than I thought.

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

The DAQmx counter property "Ctr.OutEvent.OutputBehavior" will generate an event if the counter reaches it's max value from counting up or reaches 0 from counting down. This event can be exported to a PFI line as a pulse or toggle via the "DAQmx Export Signals (most signals)" VI and used as the reference (stop) trigger. To set up a start and stop trigger you will first set up the start trigger and then set up a second trigger as a reference trigger. You'll also need a DAQmx read property node configured for the "relative to" property set to "current read position." You will also need to configure the timing VI for a finite acquisition, however, using the "relative to" property set to "current read position" will allow you to read continuously. 

 

The following example shows how to configure a start and stop task. It's for a digital task but it will be the same for other task types. 

 

http://www.ni.com/example/30016/en/

 

Here's the help page for the Ctr.OutEvent.OutputBehavior:

 

http://zone.ni.com/reference/en-XX/help/370469AG-01/daqmxprop/attr174f/

 

This example will give you a general idea regarding how to set up the Ctr.OutEvent.OutputBehavior event:

 

http://www.ni.com/example/28288/en/

 

Regards,

Jayk

RF R&D
National Instruments
0 Kudos
Message 5 of 8
(4,612 Views)

Thanks for your reply.  I wonder if I could also use the task pause trigger instead of the stop trigger.   In both cases however the problem for me is that I only have one nibble of DIO available from a 9401 module.  The solution you outline would require a DI and DO bit from a single nibble which I do not think is possible, at least I cannot figure out how to do it.  That is why, in my original question I ask if there is a way to do the signal routing within the cDAQ backplane and not involve any PFI lines.

0 Kudos
Message 6 of 8
(4,607 Views)

Hi viScience,

I think the following KnowledgeBase is more what you are looking for, which is configuring an internal counter as a trigger:

http://digital.ni.com/public.nsf/allkb/ADFC4DD8C9690232862575B70079FBD4

I would like to point out that PFI can refer to backplane lines and not just specific pins on the device. You may also want to look into the DAQmx->Advanced->Signal Routing Palette for routing signals within our DAQ devices, as the functions available there allow you to route various connections. Which connections can be routed this way can be found in NI MAX by clicking on your device and then selecting the "Device Routes" tab. Just make sure to disconnect the connections when you are done!

Charlie J.
National Instruments
0 Kudos
Message 7 of 8
(4,599 Views)

Thanks for the reply.  Yes I did select the 'Include Advsnced Terminals'  on the IO pallete and could see many of these backplane signals (BTW, they are not labeled as internal PFI lines but rather generic functions such as /cDAQ/ai/pausetrigger.  I looked at the white paper and examples but do not see a clear example of how to specify the routing of say /cDAQ/cntr2internaloutput to /cDAQ/ai/pausetrigger.  I tried many ways but could not get it to work, I would typically get an error that the routing I specified is not supported or if I tried to use HW PFI lines then I would get an error telling me that I cannot have input and output on the same DIO nibble of my 9401, which is all the IO I have left.

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