Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Agilent 34970 Visa Timeout

Hello,

Tools:
Agilent 34970a with GPIB via USB converter
Labview 8.0


I came across a problem with the Agilent 34970 Advanced Scan.vi

Problem:  I need to increase the timeout because I get an error Visa Error 0xBFFF0015 (timeout expired before operation completion) from the Agilent 34970A.lvlib:Read Vi

Ideally I want to be able to use NPLC=100 ( by changing the default in agilent 34970a.lvlib:Conf Voltage.vi) ... this causes a delay between reading incremental channels.... If I have a total of 3 or less channels to read, I have no timeout errors when I set the NPLC=100 ... when reading 4 channels, I get the timeout.  Alternatively, if I change the NPLC to 20, I can use 4 channels with NO error.

Suggestions on how to use NPLC=100 and have more channels?

Thanks


jqm
0 Kudos
Message 1 of 7
(6,407 Views)
Have you increased the timeout? That's done with a VISA property node. I'd put it in the HP34970A Initialize function right before the existing property node that reads the interface type. Create a duplicate and select Properties>General Settings>Timeout Value. Right click again on it and select Change to Write. The timeout value is in milliseconds.
0 Kudos
Message 2 of 7
(6,407 Views)
Dennis,

What I did:
I opened up my modified Agilent 34970A Advanced scan example, then I opened up the Agilent 34970A.lvlib:Initialize.vi and opened up the block diagram as suggested.
I then copyied and pasted the Interface Property node and modified as suggested :  I saved and re-ran with NPLC=100 and I still get the error:

(I tried timeout values of 500, 1000, and 10000 ms )

-----------------------

Error -1073807339 occurred at VISA Read in Agilent 34970.lvlib:Standard Event Status.vi->Agilent 34970 Advanced Scan JQM Input Channel Testing 03-24-2006.vi

Possible reason(s):   VISA:  (Hex 0xBFFF0015) Timeout expired before operation completed.

--------------------

Again at this point if I go into the Agilent 34970A.lvlib:Conf Voltage.vi and modify NPLC from 100 to 20 everything works (even when adding the new timeout). 
Is there a particular timeout that I should be using?
Any suggestions?
I performed a NI Capture with the Timeout = 500, and NPLC=100 ... NOTE JUST RENAME FROM .ZIP to .SPY

Thank you for your time and patience.

jqm

0 Kudos
Message 3 of 7
(6,386 Views)
The 10 seconds may not be enough. When you run the scan manually with the settings you want, how long does the scan take? If you set a breakpoint at the VISA Read and wait (some fairly long time), does the Read work?
0 Kudos
Message 4 of 7
(6,383 Views)
Dennis,

When NPLC is set at 100 it takes approximately 2s per channel.
I did try to set the Initilize timeout up to 60s, however I still get the error within 15s!




When I set a breakpoint at the VISA Read (in my modified advanced scan.vi) I still get an error within 15s.

I dunno if this has anything to do with it, but when I put a probe at the breakpoint before the VISA read I get the following information:
Visa Resource Name Out > Transfer Settings Tab > Is UNSELECTED to have a Term Char on Read and the Termination Character is a xA....
I bring this up because plowing on the Agilent Site I did a search and found the following:

Why do I get GPIB timeout errors when trying to read data?


Non Agilent GPIB cards may not default with EOI (End Of Instruction) as the termination character. This can cause problems with instruments that use a line feed as the termination character. One thing that can happen as a result of this is that you get a timeout error when reading data out of an instrument. Commands sent to the instrument are fine but when you read data you get the data and a timeout happens.

This can be fixed by changing the termination character to the line feed character (backslash n). The IEEE488 standard is the line feed character for the termination character.

I dont think that this should apply as I am using the agilent USB-GPIB device (Agilent 82357A).....

Again... Thank you for your time

jqm
0 Kudos
Message 5 of 7
(6,380 Views)
I made a mistake. The initialize function already had a timeout function. I just didn't look at the VI closely enough. There is a case statement that sets either the serial port parameters or just sets the VISA timeout. If you are setting the timout right after the VISA Open, it's just getting set back to 10 seconds. Change it in the case statement and see if that works. Sorry, and I hope this works.
0 Kudos
Message 6 of 7
(6,376 Views)
All fixed!
Appears to be functioning fine now.
THANK YOU.

jqm
0 Kudos
Message 7 of 7
(6,372 Views)