Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

How to install driver for instrument (sr530 lock in amp)

Hi,
 Am trying to communicate with a stanford research systems lock in amp (sr530) in LABVIEW 7.1. Interfacing through a pci gpib card. I have downloaded the driver and saved it in the library directory but still cannot communicate with it!
   The device is regestering an address in the measurement and annotation program but won't respond to the *idn? command. Have checked all the basics (cables, card, computer,code etc.).
                   Would appreciate any help as i am now officially LOST!  JP.
0 Kudos
Message 1 of 9
(7,908 Views)
Hi,
  where did you download the driver from?
You say Measurement and Automation Explorer can see the address, but the device doesn't respond to *idn? ?
MAX uses the *idn? to find out the device details initially, so you're saying it shows up ok in MAX, but MAX can't communicate with it either?
Have you got the programmers manual for the device? If so, is it a match to the ieee 488.1 standard, so it should respond to *idn? Some older equipement only understands *id and other variations.
If you have the programmers reference manual, you could try in MAX, right clicking the pci-gpib board and going to the interactive control window.
Type in there
ibfind GPIBX   (where X is the gpib address of the controller card i.e. usually GPIB0)
ibsic
ibsre 1
ibdev X,Y,Z,10,1,0    (where X is primary board index, Y is the primary address of the instrument, Z is the secondary address (usually 0), and the final 1 and 0 are the handshaking (EOI = end or identify handshaking line raised on last byte and EOS for sending a terminating character with comms))
ibwrt "*idn?" (check your programmers manual for the correct data to send i.e. *idn? might not be valid and don't forget the "")
ibrd 200
 
you can repeat the ibwrt and ibrd with different messages as required.
Once you've finished, type in
ibonl 0
to take the device off line (as far as the driver is concerned)
and then
quit
to close the interface.
 
You should see messages as you run each of these commands, giving you error information etc.
If you get a lot of errors, then quit the interactive control, and start up NI-SPY. Set it to capture (one of the toolbar buttons looks like an arrow) and then try the interactive control again. From NI-Spy, you can save the spy log, and then can you post it back here - might give us an idea of what's going on.
 
Thanks

Sacha Emery
National Instruments (UK)
 
 
 
// it takes almost no time to rate an answer Smiley Wink
Message 2 of 9
(7,893 Views)
Hi:

I've tried to communicate with the GPIB Interactive Control (NI 488.2 v1.70, LabVIEW 6.1), to the SR530 Lock In Amplifier, in that way:

: ibfind GPIB0

GPIB0: ibsic
[0120]   ( cmpl cic )

GPIB0: ibsre 1
[0160]   ( cmpl rem cic )
previous value: 1

GPIB0: ibdev
    enter board index: 0
    enter primary address: 23
    enter secondary address: 0
    enter timeout: 10
    enter 'EOI on last byte' flag: 1
    enter end-of-string mode/byte: 0
[8100]   ( err cmpl )
error: EDVR (0xe028002c)

GPIB0:

What does it mean??? How can I solve that problem so I can have communication with the SR530 Lock In Amplifier ???

Thanks a lot???



0 Kudos
Message 3 of 9
(7,835 Views)

Hi,

EDVR is returned when the board or device name passed to ibfind, or the board index passed to ibdev, cannot be accessed. The global variable ibcntl contains an error code. This error occurs when you try to access a board or device that is not installed or configured properly.

EDVR is also returned if there is an internal driver error.

EDVR (0)
Error Condition: Driver error.
Description: EDVR is returned when GPIB hardware is not configured properly, or the interface name or device name passed to the ibfind function is incorrect.
Possible Cause: Often EDVR errors are caused when you misspell the interface name of your board or the device name of your instrument. For example, the default interface name for National Instruments boards is GPIB0, but you may misspell it as GPIBO (with an "oh" instead of a zero). This error may also occur, if the board index passed to the ibdev function is incorrect. The board index is the number portion of the interface name for the GPIB board, but many people make the incorrect assumption that it is the primary address of the board. For example, I may install a PCI-GPIB board in my computer and give a primary address of 2. The default interface name for board is GPIB0, so it has a board index of 0, not 2.
Solutions:

  • Use the default settings for your GPIB hardware in the GPIB Configuration Utility (i.e., GPIB0 for the interface name and zero for the primary address).
  • Use the ibdev function instead of the ibfind function to open communications with your instrument (to avoid using its device name).
  • If you must use device names for your instruments, then make sure they are correctly configured in the Device Templates of the GPIB Configuration Utility (see your NI-488.2 User Manual for more details).
  • Use the unit descriptor returned from ibdev or ibfind as the first parameter in subsequent NI-488 functions. Examine the variable before the failing function to make sure its value has not been corrupted. (using the interactive control this shouldn't ever happen)

Looking at the srs website at the manual : http://www.thinksrs.com/downloads/PDFs/Manuals/SR530m.pdf

it's using the 1978 standard for 488. In 1987 this became 488.1, so the instrument is rather old and probably wouldn't respond to the *idn?

I also noticed from the example code - program example 4 page 50 (admitedly using basic) that very low level commands (bus level) are being passed to the card. This is mimicked with the driver from the ni website (which I assume you're using : https://sine.ni.com/apps/utf8/niid_web_display.download_page?p_id_guid=E3B19B3E959A659CE034080020E74...)

Have you spoken to Stanford about this?

Did you do GPIB0 or GPIBO (first is the number 0, the second is the letter O).

Is the GPIB address for the pci-gpib board actuall 0?

I'm talking to our guys in the US on this to get clarification on the error code you're seeing (0xe028002c) and I'll get back to you once I get a reply

Thanks

Sacha Emery
National Instruments

 

 

 

// it takes almost no time to rate an answer Smiley Wink
0 Kudos
Message 4 of 9
(7,826 Views)

Hi,

  I had a browse around the NI website and came across the following link :

http://zone.ni.com/reference/en-XX/manuals/322752A-01/07AppxC_01/

although it references for a e-net box, the error code is still the same for your setup :

EDVR Error Condition with ibcntl Set to 0xE028002C (534249428)

If a call is made with a board number that is within the range of allowed board numbers (typically 0 to 31), but which has not been assigned to a GPIB interface, an EDVR error condition occurs with ibcntl set to 0xE028002C. You can assign a board number to a GPIB interface by running the GPIB Configuration utility and selecting an interface name. Refer to Configuring the NI-488.2 Software Characteristics, in Chapter 4, GPIB Configuration, for information about how to configure NI-488.2.

Can you make sure your configuration in MAX for your pci-GPIB board looks like the attached screenshot (find the board in MAX, and right click it and then select properties).

Also can you run the troubleshooting wizard (disconnect any cables from the gpib board first)

Thanks


Sacha Emery

National Instruments

// it takes almost no time to rate an answer Smiley Wink
0 Kudos
Message 5 of 9
(7,823 Views)

It seems based on your IBIC output that you are able to communicate with the board, but for some reason trying to open a device handle is failing.  This is very odd--usually you can do both or neither.  Also, this doesn't seem to point to your instrument at all--you should be able to do an ibdev() without having anything connected to your GPIB controller.  Is there a specific reason you're using v1.7 of the driver?  v2.4 is the latest for Win2000/XP.  Do you have other NI hardware in this system?

Scott B.
GPIB Software
National Instruments

Message Edited by ScottieB on 10-13-2005 09:50 AM

0 Kudos
Message 6 of 9
(7,821 Views)
Can you communicate with the instrument at all? I have the same lock in and had problems. I added a capacitor to the gpib circuit and haven't had any issues.

Contact stanford research systems and they will send you a page on how to fix the problem.
Message 7 of 9
(7,811 Views)
Was talking to the guys in Stanford research systems. The problem was with the gpib circuit. The gpib card that im using is new and much quicker than the instrument so in order to slow the card read command i needed to solder an extra 260pF capacitor into the circuit. The guys at stanford research have the details and were very helpful.
0 Kudos
Message 8 of 9
(7,803 Views)

I have pretty much the same problem - my SR 530 lock-in amplifier gets recognized by Measurements & Automation Explorer, but it does not get detected by "NI Instrument Drive Finder". I use the GPIB connection and LabView 2012 version.

I I tried to follow the configuration steps described above:

 

ud0: infind GPIB0

GPIB0: ibsic

[160]   <cmpl rem cic>

previous value 1

 

GPIB0: ibdev

  enter board index: 0

  enter primary address: 23

  enter secondary address: 0

  enter timeout: 10

  enter 'EOI on last byte' flag: 1

  enter end-of-string mode/byte: 0

 

ud1: ibwrt "*IDN?"

[100]  <cmpl>

count:  5

ud1:  ibrd 200

[c100]  <err tomo cmpl>

error:  EABO

count:  0

0 Kudos
Message 9 of 9
(6,523 Views)