LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

I need help with NIDAQmx I/O Controls

Solved!
Go to solution

Hello LabWindows/CVI Users

 

I'm trying to use LabWindows/CVI to develop a DAQ application that will use a USB-6289 device.  I can get an application running that will acquire the data I want.

 

However, I have an annoying problem:  the new physical channel functions in the NIDAQmx I/O Controls instrument file do not work properly for me.  I am wondering if I am missing something simple or if others are experiencing this same problem.

 

I am using the controls as they are used in all the DAQmx examples supplied with LabWindows/CVI.  In short, the string control is converted to a physical channel control.  When I pull down the ring menu, it is populated with all of the channels I expect to get.  However, I am unable to actually select any channels and have them appear in the control after the pull down ring is closed.  Also, the "browse..." and "filter..." items do not work at all.  In short, I must manually type my channels into the control as if it were still a standard string control.

 

This problem exists in my program as well as in all the examples supplied with LabWindows/CVI 9.0.

 

I have LabWindows/CVI 9.0.1 (375).  In MAX, I have 5 devices.  The first 4 are real devices which are sometimes present and sometimes not present.  The USB-6289 is device 3 when it is connected.  Device 5 is a simulated USB-6289. 

 

Any help would be greatly appreciated.

 

Bill

 

0 Kudos
Message 1 of 7
(4,165 Views)

Hi Bill,

 

I could not find the cause of your problem on top of my head, but can you check the following:

 

Those I/O controls are also available (used) in DAQmx library channel creation function panels (e.g: DAQmxCreateAOVoltageChan).

Are they behaving correctly?

S. Eren BALCI
IMESTEK
0 Kudos
Message 2 of 7
(4,154 Views)

Eren,

 

Thanks so much for your response.  As you suggested, I tried a few of the DAQmx library function panels and the channel selection controls work just fine there.

 

I should point out that they look different in the function panels.  When I use them in my own code, or run examples, the string control ends up with a downward pointing arrow at the left side of the string control.  Clicking on that opens the ring control list box.  However, in the function panels for the DAQmx library, a button with three dots shows up to the right of the string control.

 

This makes me wonder if the function panels are actually using the same NIDAQmx I/O Controls function library as is used by the LabWindows examples and my code.

 

Thanks

Bill

 

0 Kudos
Message 3 of 7
(4,141 Views)
Solution
Accepted by topic author Bill_Jacobs

Hi again Eren,

 

This is a follow up to my own recent post.  I have solved the problem but am left confused.  When I created the control on my panel, I simply created a standard string control.  In playing around in the UI editor I discoved a NIDAQmx I/O Controls submenu under the Custom Controls menu.   If I select a control out of there, and place it on my panel, everything works as expected.

 

I find it interesting that when editing the properties of either the custom control or the standard control, the standard Edit String dialog box is used.  This fact is part of the reason I am confused.  The other reason is that none of the supplied LabWindows/CVI examples work for me.  Do they work for anyone else under version 9.0.1?

 

Since I am getting my program to wortk now, I do consider the problem solved.  However, I still would like to know if the examples should work on my system.

 

Thanks

Bill

 

0 Kudos
Message 4 of 7
(4,136 Views)

Bill,

 

I don't know why your 9.0.1 examples aren't working, but I can answer your first question. The DAQmx I/O controls are CVI custom controls. You can learn more about CVI custom controls by searching the CVI help for "Custom Controls Overview" but, to make a long story short, these are controls that are built on top of some existing User Interface Library controls (in this case, they are built on top of the combo box custom control, which in turn is built on top of the string and menu ring controls). The CVI UI library knowns nothing of these custom controls, and neither does the UI editor. However, when you put one of these controls in the UI editor, the CVI code generation feature does generate some additional code into your program, meant to invoke the custom controls at run time. This is the step that you were missing.

 

Luis

0 Kudos
Message 5 of 7
(4,121 Views)

Hi again Bill,

 

I remembered now: The controls on the function panel (strings with '...' button) are not made of "custom controls" of CVI.

That's why they behave different. 

 

They are inputs with custom code.

You can also add customization to your function panels by assigning a DLL code module to them. That button with '...' displays when such a code exist for that parameter. See the CVI help for more on this issue.

 

I hope Luis corrects me if I am wrong again 😉

S. Eren BALCI
IMESTEK
0 Kudos
Message 6 of 7
(4,105 Views)
Nothing to correct Smiley Happy
0 Kudos
Message 7 of 7
(4,093 Views)