User`s guide
44 Agilent VISA User’s Guide
3 Programming with VISA
These are raw I/O functions and do not intermix with the
formatted I/O functions. See “Using Non- Formatted I/O” in
this chapter for details. See the VISA Online Help for more
information on how data is converted under the control of
the format string.
Formatted I/O Functions
As noted, the VISA formatted I/O functions are viPrintf,
viQueryf, and viScanf.
• The viPrintf functions format according to the format
string and send data to a device. The viPrintf function
sends separate arg parameters, while the viVPrintf
function sends a list of parameters in params:
viPrintf(vi, writeFmt[, arg1][, arg2][, ...]);
viVPrintf(vi, writeFmt, params);
• The viScanf functions receive and convert data according
to the format string. The viScanf function receives
separate arg parameters, while the viVScanf function
receives a list of parameters in params:
viScanf(vi, readFmt[, arg1][, arg2][, ...]);
viVScanf(vi, readFmt, params);
• The viQueryf functions format and send data to a device
and then immediately receive and convert the response
data. Hence, the viQueryf function is a combination of the
viPrintf and viScanf functions. Similarly, the viVQueryf
function is a combination of the viVPrintf and viVScanf
functions. The viQueryf function sends and receives
separate arg parameters, while the viVQueryf function
sends and receives a list of parameters in params:
viQueryf(vi, writeFmt, readFmt[, arg1]
[, arg2][, ...]);
viVQueryf(vi, writeFmt, readFmt, params);