Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

how to use GPIB-USB-B to communicate with SR530

Does anyone out there have any experience using  an NI GPIB-USB-B to communicate with a Stanford Research SR530 lock-in amplifier? I think I have the GPIB-USB-B installed correctly, and the SR530 seems to sense that I am sending it signals (based on LED responses), but I cannot get any sensible response or output from the instrument. I'm fairly experienced with Labview, but I have very little GPIB experience. Any help/advice would be greatly appreciated.
-Adrian
0 Kudos
Message 1 of 9
(6,733 Views)

Hello Adrian,

How are you sending the commands to the GPIB-USB-B?  Have you tried using the Instrument Driver for the SR530?  In case you have not used an Instrument Driver before, they are sets of software routines that control a programmable instrument. Each routine corresponds to a programmatic operation such as configuring, reading from, writing to, and triggering the instrument. Instrument drivers simplify instrument control and reduce test program development time by eliminating the need to learn the programming protocol for each instrument.   You can search all of the preconfigured instrument drivers, or just download the SR530 driver.  It comes with an example program that should help ensure that everything is setup properly as well.

I hope that gets you started!

Micaela N
National Instruments
0 Kudos
Message 2 of 9
(6,717 Views)
Hi Micaela,
Thanks for the response. I have downloaded the SR530 driver from NI, and tried to use the SR530.vi contained therein to communicate with the instrument. I also tried simply using the GPIB write and GPIB read functions in my own simple VIs to exchange information with the instrument. Unfortunately, neither seemed to work.
-Adrian
0 Kudos
Message 3 of 9
(6,715 Views)

I should mention that I have also attempted to communicate with the SR530 via the NI Measurement & Automation Explorer, with similar results. I queried with *IDN? and several instrument specific commands, but in all cases writing resulted in an error LED flashing on the device, while reading invariably resulted in a EABO error, probably due to time out.

-Adrian

0 Kudos
Message 4 of 9
(6,704 Views)

Hi Adrian,

It sounds like the SR530 may not be in the right mode.  You may have already done this, but double check the switches on the dip switch sets on the back of the instrument.  For GPIB interfacing with the Instrument Driver, switches #4 and #6 on SW 1 must be down (setting device address to 23 and RS232 echo on) and switch #1 on SW2 to set RS232 baud rate to 9600.  All other switches should be up.

Make sure that the settings for your SR530 match those mentioned in the help for the SR530 VI, you can view this either by opening SR530 VI and selecting File >> VI Properties >> Documentation or by turning on Context Help -> Ctrl-H and hover over the SR530 VI icon. 

Unfortunately, the  *idn? command is not recognized by the SR530, only those command listed in the User's Manual will work.   I didn't see any identification command when I glanced through it. 

One more thing you can try is capturing and saving the GPIB commands sent and received using NI-SPY.  To start a capture open Measurement and Automation Explorer, select your GPIB instrument under Devices and Interfaces and the in the right hand panel you'll see the NI-SPY icon on the top of the panel.  Click on it, and then click the blue arrow to start a capture, then run the SR530 Example VI. 

Micaela N
National Instruments
0 Kudos
Message 5 of 9
(6,674 Views)

Hi Micaela,

I think I have everything sorted out now. I spent some time chatting with the amplifier manufacturer; they explained that since the instrument was made (1991), GPIB has sped up significantly and that this causes the problems I was having. Fortunately, there is a relatively easy fix to this problem which simply involved soldering an extra capacitor onto the main board. Now, everything seems to be running smoothly (both the VIs downloaded from NI and my own VIs). Thanks for all your help on this issue, though- I really appreciate it.

-Adrian

0 Kudos
Message 6 of 9
(6,668 Views)
Adrian,
 
I'm glad you got everything sorted out!  Good luck with the rest of your application.
Micaela N
National Instruments
0 Kudos
Message 7 of 9
(6,660 Views)

I have the same problems with my SR530. Could you please tell me where and what capacitor should be soldered on the main board.

Thanks,

Ali.

0 Kudos
Message 8 of 9
(5,297 Views)

Hi,

It seems that this post is old now but I have the exact same problem. Did someone solve this problem? Could someone give me the drivers for the sr530 and tell me where to put the capacitor?. 

Thanks in advance.

 

0 Kudos
Message 9 of 9
(5,117 Views)