Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

gating a counter

Hello,

I'm using a PCI-6251 card and labview 8.0 with DAQmx. I'm trying to count edges that arrive randomly during a gated period which begins with an external pulse.

I am trying to use the Gen Dig Pulse Train-Finite-Retriggerable.vi to gate the edge counter, but I keep getting an error message when the VI gets to the start task of the pulse train generator (error - -89137 occurred at DAQmx Start Task.vi:8).
Possible reason(s):

Specified route cannot be satisfied, because it requires resources that are
currently in use by another route.
Property: CO.CtrTimebaseActiveEdge
Source Device: Dev1
Source Terminal: 80MHzTimebase
Destination Device: Dev1
Destination Terminal: Ctr1Source

Required Resources in Use by
Source Device: Dev1
Source Terminal: PFI3
Destination Device: Dev1
Destination Terminal: PFI9
Task Name: _unnamedTask<11

Any help with how to fix this would be great. Thanks.



0 Kudos
Message 1 of 4
(3,625 Views)
0 Kudos
Message 2 of 4
(3,620 Views)

Hi,

This connection is being routed through sub-systems that are in use in your application. If you open Measurement & Automation Explorer (MAX) and select your PCI-6251 under NI-DAQmx Devices, you can select the Device Routes tab. If you hover your mouse over the intersection of the PFI3 and PFI9 connections, you'll notice that it is using Counter 0 to make this connection. Since this is being used by your application, you will not be able to make this route. Can you use PFI9 or another PFI line that is not in use by the counter instead as your sample clock?

However, one thing to keep in mind is that finite counter generation will use two counters, so you will need another counter to perform the counter input. Do you have another counter from another board available? Otherwise, I have some questions help you with this. Why do you generate this pulse train? From the VI you sent, your pulse train only consists of one pulse. Can you use the trigger used in your pulse generation as the sample clock?

Regards,

Missy S.
Project Engineer
RoviSys
0 Kudos
Message 3 of 4
(3,587 Views)
Thanks for your help. I was able to fix the error message by resetting the device.

The timing vi in the pulse train generation should have been set to continious samples, not finite. Sorry. Same for the timing in the edge counter.

John
0 Kudos
Message 4 of 4
(3,573 Views)