LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

DAQmx Switch control won't let me choose multiple switches

More precisely, if I select via "Browse":

 

  • the relay k0, it gives "/PXI1Slot2/k0", that's good.
  • the relays k0 and k1, it gives "/PXI1Slot2/k0:98"

I/O Name filtering is set as: Switch Relays, Allow Multiple Names. Everything else disabled.

This morning, it was working well. The device is simulated. I tried to delete and add it again in MAX and restarted LV (2013).

 

Any help would be greatly appreciated!

LabVIEW 2013 SP1
Windows 7 64bit
Windows Server 2012 64 bit
Windows 8.1 32 bit
0 Kudos
Message 1 of 9
(3,025 Views)

Hi Baobob,

 

Are you able to manually type in "/PXI1Slot2/k0:1" and produce the desired behavior? If you create a DAQmx Switch control in a new VI with the same settings, does it produce the same behavior?

 

 

Regards,

Mike Watts
Product Manager - Modular Instruments
0 Kudos
Message 2 of 9
(3,003 Views)

Hello Mike, thank you for your answer,

 

Yes, if I allow undefined names (which I'd rather not) and type manually type the range, the switches behave as expected.

 

BUT, I just noticed that if I uncheck allow undefined values for a given control, save everything, exit and open again the project, undefined values are allowed again for that control (No asterix * shows up next to the VI filename when I modify the option).

 

And yes, I tried in a new VI, with both Modern and Classic styles.

 

Have a look at the attached gif.

 

Thanks!

LabVIEW 2013 SP1
Windows 7 64bit
Windows Server 2012 64 bit
Windows 8.1 32 bit
0 Kudos
Message 3 of 9
(2,991 Views)

Thanks for the additional information. I am currently attempting to reproduce your issue, but the additional information would be helpful to eliminate unknown variables. I am using LabVIEW 2013 and a simulated switch device, but the questions below will help me get closer to your system.

 

1) Do you get the same behavior if you select channels other than 0 and 1?

2) What switch module are you simulating?

3) What versions of NI-MAX, NI-SWITCH do you have installed on your computer?

 


As for the issue regarding saving settings, when you make the change to not allow undefined values, do you save the VI before exiting?  t does not look like you do based on the GIF, but you might be using the save hot key.

Regards,

Mike Watts
Product Manager - Modular Instruments
0 Kudos
Message 4 of 9
(2,965 Views)

Mike,

 

Here are the answers to your questions:

 

  1. Yes
  2. NI PXI-2575
  3. MAX 5.5 and... huh, NI-Switch isn't listed in my software list. I have never used an actual switch module yet, so I haven't realized that NI-Swicth a.) exists and b.) is needed. The problem must come from this. Let me install it and I'll get back to you.
LabVIEW 2013 SP1
Windows 7 64bit
Windows Server 2012 64 bit
Windows 8.1 32 bit
0 Kudos
Message 5 of 9
(2,961 Views)

Mike,

 

I installed NI-switch 4.8, restarted my PC and the issue is still here.

 

To answer your very last question, yes, i do save before to close the VI. But there doesn't seem to be much to save because as I wrote earlier, LV doesn't register the modification as something savable. However I just found a trick to save the modification: change whatever I need in the I/O Name Filtering dialog, make any other change to the VI (like moving the FP control) and save. After I close and reopen the VI, it would remember my I/O Name Filtering configuration.

 

But the main problem i.e. a range of switches turning to "/PXI1Slot2/k0:98" still exists.

 

Thanks

 

 

 

LabVIEW 2013 SP1
Windows 7 64bit
Windows Server 2012 64 bit
Windows 8.1 32 bit
0 Kudos
Message 6 of 9
(2,952 Views)

I reproduced your test system, including LabVIEW version, simulated device, drivers, etc. When I choose k0 & k1, similar to your GIF, I get k0:1 as a result. The only time that I get k0:98, is if I choose the device itself (no specific channel). Since this problem is not reproducible on my end, I do not believe that the issue is the result of a bug. I believe that something may have been corrupted in your software installation. However, I am not sure if it is on the NI-MAX end, or the LabVIEW end. You could try resetting your MAX configuration data, which can be done by completing the process outline in the attached link.

 

If this does not work, the next steps will be to uninstall and reinstall NI Software (LabVIEW, MAX, etc.). I hope this helps.

 

NI KnowledgeBase: What is the Process For Resetting the MAX Database?

Regards,

Mike Watts
Product Manager - Modular Instruments
0 Kudos
Message 7 of 9
(2,946 Views)

Mike,

 

What I think I am going to do is leave everything like this on this developement machine and I'll see if the same behavior happens after I deploy the application as an executable on the lab PC.

 

I will post again in this thread if anything new comes up.

LabVIEW 2013 SP1
Windows 7 64bit
Windows Server 2012 64 bit
Windows 8.1 32 bit
0 Kudos
Message 8 of 9
(2,937 Views)

Sounds good. I will wait for your response.

Regards,

Mike Watts
Product Manager - Modular Instruments
0 Kudos
Message 9 of 9
(2,923 Views)