06-02-2009 06:16 PM
Hi,
I am trying to write a seemingly simple program but I keep getting myself confused when it comes to the channel names!
I want to generate a pulse train using one of the counters, e.g. ctr0. Then, I want to internally connect the output of that counter to another channel (PFI) so that then I could graph the output pulse train (from ctr0). I would like to do this without physically using wires to connect one pin to another in the connector box. I get an error trying to do this. I have attached a screen shot of the part that seems to be creating the problem.
Can someone please help me see what I am missing when it comes to counter (source/out) channels and/or the "DAQmx Connect Terminals.vi"?
Thanks.
P.S. I am using PCI 6251 with the SCB-68 breakout box, Labview 7.1.
06-03-2009 02:40 PM
Hi DanceWiz,
To internally route counter signals, you will need to use DAQmx channel property nodes. This KnowledgeBase shows how to accomplish said routing.
06-05-2009 02:45 PM - edited 06-05-2009 02:51 PM
Hi David,
Thanks for your reply. I read and tried to implement the KnowledgeBase article that you said but ran into a couple of problems:
i) The article mentions that "Routing the output of one counter to the source of another counter should be done using property nodes and/or DAQmx Signal Routing" but it only shows one example of how to use the property nodes, and nothing about how to use the DAQmx Signal Routing, which is what I would prefer to use (DAQmx Connect Terminals.vi).
ii) The channel property node method/example that they talk about only works for counters (not PFIs, which is where I am trying to connect the output of counter 0).
When I use the DAQmx Connect Terminal.vi to do this, I get the following error:
Error 200022 occurred at DAQmx Start Task.vi
Measurements: Resources requested by this task has already been reserved by a different task.
Device: Dev1
Terminal: PFI0
Task name: _unnamed Task<14>
I am attaching a copy of the code that I have written using DAQmx, and also a .jpg of the same code trying to use the property node.
Thanks
P.S. I am using Labview 7.1, and NI PCI-6251.
06-08-2009 04:09 PM
Hi DanceWiz,
The issue with using the connect terminal vi is that it reserves the terminals that it connects. As such, you are receiving error 200022. To achieve the functionality you desire, property nodes must be used. Implementing the counter output and digital input tasks as displayed below should work. The CO.Pulse.Term property node sets the CO task output to PFI0, while the DI.Tristate property node (when set to false) enables the reading of the digital line even though it is used in the CO task.
06-09-2009 10:05 AM
Hi David,
When I try this, I still get an error, plus the output is a sawtoothed train. The error that I get is the following:
Error -89137 occurred at DAQmx Start Task.vi
Possible reason(s):
Specified route cannot be satisfied, because it requires resources that are currently in use by another route.
Property: CO.Pulse.Term
Destination Device: Dev1
Destination Terminal: PFI0
Required Resources in Use by
Source Device: Dev1
Source Terminal: PFI12
Destination Device: Dev1
Destination Terminal: PFI0
Task Name: _unnamedTask<36>
I have attached a .jpg copy of the vi and of its output. Thanks again for your help.
06-10-2009 08:28 AM
Hi DanceWiz,
First, reset the device in MAX. Then, set up the write and read portions of your task like this: