Saturday, September 25, 2010

GPIB Communication and Configuration

Summary: In this lesson, you will learn about GPIB communication and configuration.
The ANSI/IEEE Standard 488.1-1987, also known as General Purpose Interface Bus (GPIB), describes a standard interface for communication between instruments and controllers from various vendors, such as scanners and film recorders. It contains information about electrical, mechanical, and functional specifications. GPIB is a digital, 8-bit parallel communication interface with data transfer rates of 1 Mbyte/s and higher, using a three-wire handshake. The bus supports one System Controller, usually a computer, and up to 14 additional instruments. The ANSI/IEEE Standard 488.2-1992 extends IEEE 488.1 by defining a bus communication protocol, a common set of data codes and formats, and a generic set of common device commands.
GPIB instruments offer test and manufacturing engineers the widest selection of vendors and instruments for general-purpose to specialized vertical market test applications. GPIB instruments have traditionally been used as stand-alone benchtop instruments where measurements are taken by hand.
The GPIB is a 24-conductor parallel bus that consists of eight data lines, five bus management lines (ATN, EOI, IFC, REN, and SRQ), three handshake lines, and eight ground lines. The GPIB uses a byte-serial, asynchronous data transfer scheme. This means that whole bytes are sequentially handshaked across the bus at a speed that the slowest participant in the transfer determines. Because the unit of data on the GPIB is a byte, the messages transferred are frequently encoded as ASCII character strings.

GPIB Addressing

All GPIB devices and interfaces must have a unique GPIB address between 0 and 30. Address 0 is normally assigned to the GPIB interface. The instruments on the GPIB can use addresses 1 through 30. GPIB devices can be talkers, listeners, or controllers. A talker sends out data messages. Listeners receive data messages. The controller, usually a computer, manages the flow of information on the bus. It defines the communication links and sends GPIB commands to devices. The GPIB VIs automatically handle the addressing and most other bus management functions.

Data Transfer Termination

You can terminate a GPIB data transfer in the following three ways:
  • The GPIB includes a hardware line (EOI) that can be asserted with the last data byte. This is the preferred method.
  • Place a specific end-of-string (EOS) character at the end of the data string itself. Some instruments use this method instead of or in addition to the EOI line assertion.
  • The listener counts the bytes handshaked and stops reading when the listener reaches a byte count limit. This method is often used as a default termination method because the transfer stops on the logical OR of EOI, EOS (if used) in conjunction with the byte count. Thus, you typically set the byte count to equal or exceed the expected number of bytes to be read.


To achieve the high data transfer rate that the GPIB was designed for, you must limit the number of devices on the bus and the physical distance between devices. The following restrictions are typical:
  • A maximum separation of 4 m between any two devices and an average separation of 2 m over the entire bus
  • A maximum total cable length of 20 m
  • A maximum of 15 devices connected to each bus, with at least two-thirds powered on
For high-speed operation, the following restrictions apply:
  • All devices in the system must be powered on
  • Cable lengths must be as short as possible with up to a maximum of 15 m of cable for each system
  • There must be at least one equivalent device load per meter of cable
If you want to exceed these limitations, you can use a bus extender to increase the cable length or a bus expander to increase the number of device loads. You can order bus extenders and expanders from National Instruments.


Refer to the National Instruments GPIB support Web site for more information about GPIB.

Software Architecture

The software architecture for GPIB instrument control using LabVIEW is similar to the architecture for DAQ. The GPIB interface includes a set of drivers. These drivers also are available on the LabVIEW CD and the majority of the drivers are available for download at Always install the newest version of these drivers unless otherwise instructed in the release notes for either the GPIB interface or LabVIEW.


Use MAX to configure and test the GPIB interface. MAX interacts with the various diagnostic and configuration tools installed with the driver and also with the Windows Registry and Device Manager. The driver-level software is in the form of a DLL and contains all the functions that directly communicate with the GPIB interface. The Instrument I/O VIs and functions directly call the driver software.

Configuration Software (Windows)


(MAC OS and UNIX) Refer to the GPIB interface documentation for information about configuring and testing the interface.
MAX is the configuration utility for National Instruments software and hardware. It also can execute system diagnostics, add new channels, interfaces, and virtual channels, and view devices and instruments connected to the system.
Open MAX by double-clicking the icon on the desktop or by selecting Tools>>Measurement & Automation Explorer in LabVIEW.
The Configuration pane of MAX includes the following sections under My System:
  • Data Neighborhood: Use this section to create and test virtual channels, aliases, and tags to channels or measurements configured in Devices and Interfaces.
  • Devices and Interfaces: Use this section to configure resources and other physical properties of devices and interfaces and to view attributes of one or multiple devices, such as serial numbers.
  • IVI Instruments: Use this section to name an IVI virtual instrument, modify its properties, and swap IVI instruments.
  • Scales: Use this section to set up simple operations to perform on data, such as scaling the temperature reading from the DAQ Signal Accessory from volts to degrees Celsius.
  • Historical Data: Use this section to access databases and logged data.
  • Software: Use this section to determine which National Instruments drivers and application software are installed and their version numbers.
  • VI Logger Tasks: Use this section to create, modify, run, and view VI Logger tasks.
The example shows a GPIB interface in MAX after clicking the Scan For Instruments button on the toolbar.
Figure 1
Figure 1 (maxgpib.png)
The Remote Systems section in the Configuration pane allows you to view and configure remote systems, such as RT Series PXI Controllers. Configure the objects listed in MAX by right-clicking each item and selecting an option from the shortcut menu.

Content actions


No comments:

Post a Comment

Related Posts Plugin for WordPress, Blogger...

Popular Projects

My Blog List

Give support

Give support
Encourage Me through Comments & Followers