Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I check if an NI-9188 is reserved WITHOUT reserving it?

I'm building a DAQ system that will potentially run a mix of 9172s, 9178s, and 9188s.  I'd like to have it only include those 9188s that were reserved using MAX, while not grabbing every 9188 that was added to the System, in case the same chassis has been added to multiple PCs that will be running this application.  How can I do this?

 

Thanks,

Erik

0 Kudos
Message 1 of 5
(3,398 Views)

Hey Erik-

 

I'm glad to see you are grasping the concept of Reservation- it sounds like you're well on your way to developing a shared system of chassis.

 

My suggestion would be to try and execute a driver operation (like Self Test or Device Reset) on the chassis of interest.  If you have Added but haven't previously Reserved the chassis then you should expect to receive error -201388 "Network device is not reserved for this host."  You could use this as a signal that an Added chassis should be "hands off" to your application unless a user has manually Reserved it through other means (MAX, another application, etc).

 

Hopefully this helps-

Tom W
National Instruments
Message 2 of 5
(3,390 Views)

Tom,

 

That did the trick!  I'm not a huge fan of using error trapping but until NI adds a "Reserved" property to network-attached cDAQs, I'll use what's available.

0 Kudos
Message 3 of 5
(3,385 Views)

Tom,

 

Unfortunately now I'm stuck waiting for the 9188 to reset, and I keep increasing the pause, as so far it's still failing even with a pause of 90 seconds (!)   There HAS to be a better way!  Is there even a way to determine if it's done resetting (though 90 seconds is rediculous IMHO)?  Do I have to PING the darn thing?

0 Kudos
Message 4 of 5
(3,369 Views)

Hey Erik,

 

Try using the DAQmx Self Test Device VI rather than the Reset Device VI.  This should execute much quicker.

0 Kudos
Message 5 of 5
(3,350 Views)