From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Digital I/O

cancel
Showing results for 
Search instead for 
Did you mean: 

usb6501 multiple device

I have written a large application under Visual Studio 2005 c# using some Ni-DAQ-mx fonctions to control a USB6501 device. The USB 6501 is part of a data aquisition system and is embedded with some of my other hardware. A few interface containing the USB 6501 and my hardware have been created. Now if I am trying the other interface onto my computer, only the original interface is working....
First and somewhat suprising, everytime I am plugging onto my computer a new interface, the computer tells me "Found new hardware: USB 6501" Usually, most company allow the plug&play of their USB device using the detection on the software base driver and not of the unique USB number.It is even more pleasant when a company lets the user decide what to do.
If I proceed with the default installation, the computer tells me the hardware is now ready to use. However, nothing is working... Only the original interface seems to fit into the computer.... This is of course a real concern since the interfaces will be used in several computers, and any computer can receive any interface.
It is like changing the tires in your car. The car can received any tires of the same size, and any tires produced can be mounted on any cars right ?  In my case, changing tires makes the car stop...... Do I need to buy a new car everytime I need new tires ?
 
Thank's for your support.
 
 
 
0 Kudos
Message 1 of 3
(3,247 Views)

I would need to add that the way the software is written related to the Dev devices as shown below:

For the input

  myTaskJ12.DIChannels.CreateChannel("Dev1/port0/line0:7", "J12",ChannelLineGrouping.OneChannelForAllLines);

                    readDataJ12 = myDigitalReaderJ12.ReadSingleSampleMultiLine();

 

as well as for the output
            try
            {
                using (Task digitalWriteTask = new Task())
                {
                    //  Create an Digital Output channel and name it.
                    digitalWriteTask.DOChannels.CreateChannel("Dev1/port2/line3", "LedJ1", ChannelLineGrouping.OneChannelForEachLine);
                    DigitalSingleChannelWriter writer = new DigitalSingleChannelWriter(digitalWriteTask.Stream);
                    writer.WriteSingleSampleSingleLine(true, !boAff);
                }
            }
            catch
            {
            }

 

So basically, how do I get rid of this Devx, so the software always read whatever device is present? I would prefer to do this procedure automatically instead of renaming the devices with MAX

Terry,

 

0 Kudos
Message 2 of 3
(3,241 Views)

Hi,

Try the DAQsystem.devices property out of the NationalInstruments.DAQmx class library to get a list of installed devices on the system. At least you will get the information which devices are available and you can define the appropriate Task names.

I hope this helps.

Bets Regards,

Evrem

NI Switzerland

 

0 Kudos
Message 3 of 3
(3,223 Views)