Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

GPIB queries such as MEAS? and READ? take a long time (5-10 seconds)

GPIB queries, like MEAS? and READ?, seem to take an awfully long time.

I'm using the NI GPIB-USB-B cable to control and query an Agilent E4418B Power Meter remotely.

I see the slow behavior with the NI tools and my own test software. With the NI Measurement and Automation Explorer, I right click on the instrument and choose "Communicate with Instrument". After the NI-488.2 Communicator box pops up,  I send the MEAS? string and have to wait at least 5-10 seconds before I see anything in the string received box. The same is true with a READ? query, but the *IDN? query is quick and usually takes less than a second to respond. I'm not seeing anything unusual on NI Spy.

I'm at a bit of a loss as to why a simple MEAS? query would take so long. Am I missing any critical commands that might speed up the process? Has anyone else seen this kind of slow response with the GPIB-USB-B cable?

Thanks in advance,
Aubrey Pratt



0 Kudos
Message 1 of 9
(10,463 Views)

Hi,

I don't remeber well the origin of my problems with this instrument but at the end I decided to use the command "FETC?" to get the measured value instead of "MEAS?" because it worked really faster (maybe a matter of a different kind of memory used for the data access by the 2 commands).

I hope it will help you.

regards

CLD - Labview Certified Developer
0 Kudos
Message 2 of 9
(10,450 Views)
Thanks for the advice. I'm not sure why, but FETC? is much faster.
0 Kudos
Message 3 of 9
(10,449 Views)
You may want to review the differences between FETC? and MEAS?. I found a link to the programming manual below. It seems that FETC? just gets an existing measurement from the instrument, while MEAS? causes a new measurement to be taken.

http://cpliterature.product.agilent.com/litweb/pdf/E4418-90025.pdf
0 Kudos
Message 4 of 9
(10,427 Views)
Let me explain the generic concept of SCPI's READ/MEASure/FETCh commands.  Sorry but I am not familiar with the Agilent model you are using, but the concept is common for most of SCPI-based instruments that implement these command family.
 
Basically MEASure? and READ? do initiate a new measurement, which may require long time to complete measurement depending on instrument type.  On the other hand, FETCh? just queries measurement data *WITHOUT* initiating new measurement.  The measurement data that the FETCh? query returns is the cached data that was acquired at previous MEASure/READ or INITiate.  (INITiate command initiates a new measurement but does not query the data.) Therefore using FETCh? query without initating will cause a SCPI error.
 
For example,
 
READ? (or MEASure?)
initiates a new measurement then returns data
 
This is basically equivalent to
INITiate
FETC?
 
If the INITiate command initiates a measurement then generates multiple measurement data set such as VOLTage, CURRent, POWer, FREQuency, etc at once, you can send INITiate only once then query multiple data by multiple FETCh? queries like:
 
INITiate
FETCh:VOLTage?
FETCh:CURRent?
FETCh: POWer?
FETCh:FREQuency?
 
This only takes the time for once-time measurement as the new measurement is taken only once by INITiate.  If you used READ or MEASure instead of FETCh, it would take 4-time longer to acquire all the 4 items, plus could not operate simultaneous measurement for multiple items. 
 
Mind that INITiate command may require a sub node such as INITiate:SEQuence2 depending on the instrument, therefore you should reference to the operation manual for more about detail syntax for INITiate/FETCh/READ/MEASure. 
 
Makoto

このメッセージは 05-11-2006 12:48 PMに Makoto が編集しています。

Message 5 of 9
(10,423 Views)

Thank you very much for the clear and detailed explanation.

Regards

CLD - Labview Certified Developer
0 Kudos
Message 6 of 9
(10,410 Views)
Hi,

sorry but I do not agree, if the Meas? command takes 5 seconds for
ant06 it is because the metrology of the devices requires this.

you have to chage the measurement parameters to get a faster response.

Apart this the information you give is right.

FG

0 Kudos
Message 7 of 9
(10,399 Views)

Hi, maybe useful:

 

(page 94 of E4418 Programming Guide manual)

 

Command Used

In free run trigger mode, FETC? must be used to retrieve a result.

In other trigger modes, there are a number of commands which can be

used, for example, MEAS?, READ?, FETC? Note that the MEAS? and

READ? commands are compound commands i.e., they perform a

combination of other lower level commands. In general, the best speed

performance will be achieved using the low level commands directly.

 

 

CLD - Labview Certified Developer
0 Kudos
Message 8 of 9
(10,379 Views)
Page 213 of my 34401 DMM manual suggests that turning the autozero function off will more than double your reading speed for DC voltage resistance and DC current functions.  Page 214 has similar suggestions for collecting AC measurements.
0 Kudos
Message 9 of 9
(10,040 Views)