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.

Switch Hardware and Software

cancel
Showing results for 
Search instead for 
Did you mean: 

Change Topology without Closing Reference

Solved!
Go to solution

Hello All,

 

 Wondering if I should be able to change the topology of a MUX (reinitialize) without closing the reference?  I have a application that loops through the basic initialize, connect, disconnect sequence for the NI-Switch functions, and the topology changes for each loop.  I think my reference is getting lost, because it becomes invalid after several loops.  Do I need to close the reference before I reinitialize with the new topology?  I would prefer to not have to close it every time, because I have "cleanup" steps that close all of the references outside of the loop. Working with PXI-2527, LV 2013 and TS 2013.  Thanks in advance.

 

GSinMN    

0 Kudos
Message 1 of 3
(5,950 Views)
Solution
Accepted by topic author GSinMN

Hekki GSinMN,

 

This KnowledgeBase Article should answer your question. The last line reads, "When changing the topology, you have to close the present session if one is open, and reinitialize the card with the new DriverSetup selected."

Jonathan L.
Technical Support Senior Group Manager
National Instruments
0 Kudos
Message 2 of 3
(5,935 Views)

Thanks for the response Jonathan.  I suspected as much.  So this means I will need to change my cleanup to account for sessions that have already been closed.  So how can I tell if a session is still open/valid, before I try to close it?  I've tried by checking to see if the session number is "0", but that doesn't seem to work every time.  (I think this is a TestStand question, so I will post it there as well).  Thanks again. 

 

GSinMN

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