12-29-2008 05:50 PM
I'm trying to read the relay(s) on a PXI2590 1x4 MUX switch so that I fire them only when necessary. I know the names of the relays are MUX01, MUX23 and MUX0123. If I INIT the switch, niConnect Channels, Wait for Debounce, and then Get Relay Position I get a proper reading (Closed or Open). I then call niSwitch Close .vi and the switch remains in this position.
However if I just call the INIT, niSwitch Get Relay Position and Close vi's seems to reset the switch to some other (default?) value. I've confirmed this behavior using an RF generator and spec analyzer.
Am I doing using these vi's improperly? Should I use the DAQmx driver for this switch instead?
LabVIEW 8.5.1
NI-Switch 3.70.49152
NI-DAQmx 8.7.1f2
NI-PXI-2590
Solved! Go to Solution.
12-30-2008 09:18 AM
Hello GovBob,
Correct me if I am mistaken. First you are calling NI-SWITCH Initialize (not initialize with topology, or initialize with options) and the 'reset device' boolean is unwired? (which means reset = true)
Then in one case: calling NI-SWITCH Connect channels, NI-SWITCH Wait for Debounce, NI-SWITCH Get Relay Position, then NI-SWITCH Close (close session, not close relay). Then physically measuring opens or shorts.
In the other case: calling NI-SWITCH Get Relay Position, then NI-SWITCH Close. Then physically measuring opens or shorts.
The results being the second case has all opens (ch0 is connected to com). This behavior is expected since the 'reset device' flag in any of the Initialize VIs is TRUE if left unwired. However, if you are physically measuring different values compared to what NI-SWITCH Get Relay Position is returning, then please submit your VIs and a list of steps and measured values for each step. Hope this helps!
-Jordan
01-05-2009 12:01 PM
Thanks for the reply. Yes the problem was the reset flag during the initialization. Sometimes I can't see the forest for the trees