GPIB is a standardized interface that allows you to connect
and control multiple devices from various vendors. For many GPIB applications,
you can communicate with your instrument without detailed knowledge
of how GPIB works. Communication is established through a GPIB object, gpib
,
which you create in the MATLAB® workspace. For information about
creating the gpib
object, see Creating a GPIB Object.
You can write and read both binary and text data. For examples of both, see Writing and Reading Data.
binblockread | Read binblock data from instrument |
binblockwrite | Write binblock data to instrument |
clear | Remove instrument objects from MATLAB workspace |
clrdevice | Clear instrument buffer |
delete | Remove instrument objects from memory |
disp | Display instrument object summary information |
fclose | Disconnect interface object from instrument |
fopen | Connect interface object to instrument |
fprintf | Write text to instrument |
fscanf | Read data from instrument, and format as text |
get | Instrument object properties |
gpib | Create GPIB object |
instrhwinfo | Information about available hardware |
instrreset | Disconnect and delete all instrument objects |
propinfo | Instrument object property information |
set | Configure or display instrument object properties |
spoll | Perform serial poll on GPIB objects |
trigger | Send trigger message to instrument |
tmtool | Open Test & Measurement Tool |
fgetl | Read line of text from instrument and discard terminator |
fgets | Read line of text from instrument and include terminator |
flushinput | Remove data from input buffer |
flushoutput | Remove data from output buffer |
fread | Read binary data from instrument |
fwrite | Write binary data to instrument |
isvalid | Determine whether instrument objects are valid |
inspect | Open Property Inspector |
length | Length of instrument object array |
load | Load instrument objects and variables into MATLAB workspace |
methods | Class method names and descriptions |
obj2mfile | Convert instrument object to MATLAB code |
query | Write text to instrument, and read data from instrument |
readasync | Read data asynchronously from instrument |
record | Record data and event information to file |
save | Save instrument objects and variables to MAT-file |
scanstr | Read data from instrument, format as text, and parse |
size | Size of instrument object array |
stopasync | Stop asynchronous read and write operations |
instrcallback | Display event information when event occurs |
instrfind | Read instrument objects from memory to MATLAB workspace |
instrfindall | Find visible and hidden instrument objects |
instrhelp | Help for instrument object type, function, or property |
instrid | Define and retrieve commands that identify instruments |
instrnotify | Define notification for instrument events |
The GPIB object establishes a connection to an instrument via its GPIB interface.
The GPIB address consists of the board index of the GPIB controller, and the primary address and (optionally) the secondary address of the instrument.
Rules for read and write operations with GPIB and examples of writing and reading both text and binary data.
Enhance your instrument control communication using events and callbacks.
Send the GET (Group Execute Trigger) GPIB command to the instrument. This command instructs all addressed Listeners to perform a specified action.
Execute a serial poll where the Controller asks (polls) each addressed Listener to send back a status byte that indicates whether it has asserted the SRQ line and needs servicing.
Basic features of the General Purpose Interface Bus (GPIB).
Required versions of vendors' drivers.
GPIB Driver Limitations by Vendor
Known limitations with supported GPIB drivers.
Instrument Control Toolbox Properties
These properties are available in the toolbox.
Troubleshooting GPIB Interface
Try these tips if you have problems using the toolbox with the GPIB interface. Includes information about GPIB supported platforms, adaptor requirements, configuration and connection, and other interface-specific tips.