LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Misbehaving GPIB

Solved!
Go to solution

stubborn keithleys.JPG

I made this program to troubleshoot some problems I was having with another program and have discovered some really strange behavior, and if anyone has any ideas for a fix that would be awesome.

 

My program involves 2 Keithley 181s and I have to turn the filter and damping on and off at the correct times.  In this program (shown above) I have eliminated all other functions except for the handling of the keithley voltmeters.

 

The idea is that it turns on the filter/damping for keithley #1, waits 5 seconds, turns on the filter/damping for keithley number 2, and then it prompts me to tell me that the filter should be on.  It then repeats the process for turning the filters off:  It turns off damping/filters for keithley #1, waits a few seconds, turns off the damping/filters for keithley #2, and prompts me to let me know that they should be off, and just repeats the process over and over. 

 

The problem is that whichever keithley is designated to go first works just fine, but whichever is designated to go second switches to "talk" mode (and then switches out of talk mode once I address the other keithley) but it doesn't do anything, the filters/damping never turn on.  It can't be a problem with the driver (I dont think) because the driver that works the first one is exactly the same as the one that doesn't work for the second.  It can't be a problem with the keithley itself because I can switch the order, and whichever the program commands first always works, and whichever the program commands second never works, no matter which keithley I plug into it.

 

This is really giving me a headache here so any tips you may have would be awesome.

0 Kudos
Message 1 of 13
(2,771 Views)

If you put the two widgets on seperate GPIB buses, does it work?

 

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 2 of 13
(2,767 Views)

I'm not exactly sure what you mean.

 

The 2 sub.vis with the true/false boolean constants obviously have different gpib addresses...

Unless you mean the actual physical port that plugs into my computer, in which case I don't know, I only have 1.

0 Kudos
Message 3 of 13
(2,765 Views)

Can't debug a picture. Post the VI and subVIs. Be sure to include the global with the VISA Resource Names.

 

I'd also suggest swapping out both GPIB cables to see if there is a hardware problem.

 

And lastly, you have no visible error handling. Do you have automatic error handling turned on?

0 Kudos
Message 4 of 13
(2,762 Views)

Haven't posted an actual .vi up on these forums yet, hopefully they work for you.

 

I haven't tried switching the actual cables out yet, i didn't think it would be a hardware problem because I can either keithley work by just switching the addresses on he front panel, but I'll give it a shot.

 

Also no, there is no error handling here (this is not the actual program I'm trying to build, its just for troubleshooting).  But my error handling knowledge is minimal anyways.

Download All
0 Kudos
Message 5 of 13
(2,753 Views)

What are the actual VISA Resource Names that you are using? You did not set and save them in the main front panel.

 

I'm also a little confused about 'switching the addresses on the front panel'. You swap the addresses and then just rerun the program? If so, I would advise power cycling the instruments after doing the address change and redoing a scan for instruments.

0 Kudos
Message 6 of 13
(2,742 Views)

Sorry about that,

 

GPIB0::11::INSTR

 

and

 

GPIB0::5::INSTR

 

are the names as they appear on the front panel.

 

As for your confusion, see how there are 2 addresses, 1 for keithley REF and 1 for keithley DUT?  Only the device assigned to Keithley REF will work properly.  So, I can assign GPIB::5 to keithley REF and GPIB::11 to keithley DUT and only the keithley at GPIB::5 will work.  Or, I can assign GPIB::11 to keithley REF and GPIB::5 to keithley DUT and only the heithley at GPIB::11 will work.  (I am not changing the address assigned to the keithley itself, I am only swapping the text on the front panel)

0 Kudos
Message 7 of 13
(2,734 Views)
Solution
Accepted by topic author LarsUlrich

I took a couple of minutes to clean up your code. If this does not work, I would suspect faulty hardware.

Download All
Message 8 of 13
(2,716 Views)

Awesome, I'll check it out first thing tomorrow morning and see how it goes.

0 Kudos
Message 9 of 13
(2,710 Views)

Okay. I strongly suspect that the feedback loops/comparison in your subVI was the cause of the problem.

Message 10 of 13
(2,701 Views)