Jump to content
  • 0

DO resetting when using multiple software instances with ULx library


ReinhardV

Question

Hello,

being new to the forum, I am not sure whether my similar post as an answer will show up as an open question, I give it one more/last try in a new post:

 

I am using the USB-2408-2AO with a LabVIEW (2011) application (built exe) and the ULx library, which is all working fine.

Now we have the need to control several of those modules parallel from one computer and I decided to allow multiple instances of the exe, each connecting to another USB-2408-2AO. In principle this also works, but I have one big problem occuring when a newly opened instance uses the ULx library function (ULx Create Channel (...).vi) for the first time. At this moment the Digital Outputs of all connected USB modules are reset, which leads to unexpected failures in the corresponding measurements. This happens independently from the chosen device of the measurement channel to be created.

Afterwards, I can set all digital outputs of the connected USB devices as desired, but every time I start a new instance, the running measurements crash (as they need the DO turned on). And, to anticipate this, I also would not want a measurement to start if it was stopped before, so inverting the logic (pull-up / pull-down) is not a solution.

Is there a way to prevent the ULx functions from doing this reset to all the DIOs when called by an application the first time?

I might, of course, reprogram everything to be controlled by only one application, which is calling a new window for each USB module / measuring task, but that would be a huge mess, not only because I've made intense use of global variables that should refer to only one measuring task.

Anyway, I think it should be possible to work with two or more USB DAQ systems independently in two or more applications.

 

Thanks and best regards,
Reinhard

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

  • 0

Hello @ReinhardV.

With multiple USB-2408-2AO devices connected to one system, is the user required to select a device and digital lines when the custom executable is launched?  I can see this being an issue if you already launched one instance of the executable, selected the first device (Dev0 as default), and then launched the executable a second time which defaults to the first device (Dev0).  Unless you specifically indicate which device and lines to use for each instance prior to launching the executable, ULx will list all detected MCC devices.

I tested the ULx example to generate digital outputs (ULx Write Dig Chan.vi) with two different MCC daq devices.  I named and saved the example twice specific for each device with the device # and digital lines saved in the Channel Parameters field.  I launched one example for the first device and set the digital output 0 line HI.  Afterward I launched the second example specific for the second board and set its digital output 0 line HI.  I did not notice an issue with the first device when I started the second example.

image.png

 

Regards,

Fausto

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...