Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Programatically detect channel type error (says invalid task when I pass channel into reference input)

Solved!
Go to solution

Hi All,

 

I am having some problems collecting data with a VI that I have put together using LabVIEW 2010 and DAQmx 9.5. My DAQ device is a PXIe-6341 in a PXIe-1071 chassis. I have a single VI that iterates through all of the tasks and checks which channels are in each task. The channels are then passed into a Channel Property Node to check for channel type. This allows me to programmatically adjust which DAQmx read I use to read the data from the buffers.

 

I am getting error code -200428 claiming that the task I am passing into the Channel Property node is invalid. It then gives me the CHANNEL name as the invalid task. Am I wrong in assuming that I can pass channel's into the reference input of a DAQmx property node? I know the task and the channel within the task are setup correctly because I can see the voltage on the digital output terminal.

 

Any help with this would be greatly appreciated.

 

Best Regards,

Ryan

0 Kudos
Message 1 of 2
(2,656 Views)
Solution
Accepted by topic author rehelmin

Channel property types are weird.

 

You need to wire the task into the upper left input of the channel property node, not the channel.

 

Then, choose the property "Active Channel", and add another property to the node which is chanType.  Wire your channel into the first and get the chantype out of the second property.

 

ActiveChan.jpg

Message 2 of 2
(2,637 Views)