designfeature By Dan Strassberg, Senior Technical Editor

NOTHING GOOD LASTS FOREVER, BUT IEEE 488’S SLOW DECLINE IS MAKING THE VENERABLE INSTRUMENT-INTERFACE STANDARD SEEM IMMORTAL.

ike the character in the famous Monty Python sketch, IEEE 488 is Lnot dead yet. The decades-old stan- dard’s longevity is in question, however, and you probably have good reason to care about its fight for life.Whether you design test-and-measurement instru- ments, develop or implement systems that incorporate test-and-measurement products that others design, or simply use such products in your lab or test fa- cility, the methods that instruments use to communicate with each other and with host matter a lot. The communications medium’s physical im- plementation, protocol, and instru- ment-specific command sets strongly influence instruments’ and systems’ speed and cost and the time EEs must spend programming and test applications. In 1977, the IEEE adopted the structure and that it named IEEE 488. Some others call it GPIB (general-purpose instrumenta- tion bus). The bus’s original name was HPIB (Hewlett-Packard instrumenta- tion bus). HP, which, in 1999, spun off its electronic test-and-measurement business as Agilent Technologies, was the largest manufacturer of such equip- ment, a market position that Agilent still IEEE 488: enjoys. Even before the early 1980s ush- ered in the widespread availability of PCs, large numbers of minicomputers (remember them?) were in use control- ling instruments and processing the data they generated. Until the advent of the HPIB, no stan- not dardized methods existed for interfacing instruments with computers. It’s only a slight exaggeration to say that no two in- struments interfaced in the same way. The RS-232 serial-communication standard and the Centronics parallel- interface did a decent job of dead standardizing the side of the interface and even motivated some stan- dardization on the instrument side. (RS- 232 ports became popular on slower in- struments.) Still, because it was rugged yet?and relatively speedy, was designed for www.edn.com June 12, 2003 | edn 49 designfeature instrument interfacing, and was backed by several of Agilent’s latest instruments ATAGLANCE HP’s clout, IEEE 488 remained for more support USB 2.0 and, because USB 2.0 is than two decades the industry’s primary ୴ Most test-and-measurement-industry backward-compatible, they support USB standard for enabling instruments and observers believe that IEEE 488’s days are 1.1 as well. Another external serial bus, computers to talk with one another. numbered, but that the number will be well FireWire, also known as IEEE 1394, no Even so, IEEE 488’s early era was no in excess of 3000 days. longer appears to figure significantly in bed of roses. Although the standard did the future of instrument interfacing, even a good job of defining the communica- ୴ The two top contenders for the instru- though it is technically superior to USB, tions hardware, it initially gave short ment-interfacing standard of the future are including USB 2.0. The reasons are pri- shrift to interfacing’s software aspects. and USB. You can find one or both marily political. More than a decade elapsed before the in many instruments. Thanks to a more efficient protocol evolution of the necessary software stan- and in spite of a raw bit rate 20% lower dards, particularly SCPI (standard com- ୴ The industry is hard at work to ensure than USB 2.0’s, FireWire—even in its ini- mands for programmable instruments). that the switch to new communication pro- tial implementation—is faster than USB It took still longer to develop standard in- tocols will be nearly painless. Existing instru- 2.0. Subsequent versions of FireWire will strument drivers, whose existence re- ment-control routines should work without be still faster. Moreover, unlike the host- lieved test-system designers of a great deal modification with the computer-standard centric USB, FireWire, with its peer-to- of application-specific programming. protocols. peer topology, seems tailor-made for test- and-measurement systems that include SEEMINGLY TORPID PACE ୴ Don’t be fooled by the new protocols’ both a host computer and instruments The idea that the electronics industry high nominal bit rates; instrument interfac- such as modern oscilloscopes and logic includes a segment that marks its evolu- ing usually involves short messages. In such analyzers, which contain their own com- tion in decades rather than months must service, IEEE 488 can be significantly faster puters. (By enabling several computers to seem bizarre—even unthinkable—to than protocols that at first appear to be share control of the bus, the new OTG younger EEs whose experience stretches much faster than IEEE 488. (On The Go) extension of USB 2.0 back only as far as the go-go days of the should at least partially overcome late 1990s. However, this seemingly tor- FireWire’s advantages in applications pid pace is keeping IEEE 488 alive, even necessary. Scopes that offer communica- that embody multiple computers that if not in the most robust health, and will tion ports other than IEEE 488 are be- can act as hosts.) But, whereas manufac- continue to do so for years to come. coming increasingly common. The result turers need not pay royalties to use USB To many observers, though, propelled of the need to intermix old and new in- in their products, using the patented by ubiquitous computer-interconnect struments will be increasing numbers of FireWire technology requires royalty standards, IEEE 488 appears to have en- instrumentation setups that also intermix payments. The royalty situation togeth- tered the end game. It may not go quiet- communication protocols (Figure 1). er with the influence of a few large com- ly—powerful forces will keep it alive for The current and most likely future panies that back it has enabled USB to years, but many in the industry see its leader in replacing IEEE 488 is Ethernet. leap ahead of FireWire in test-and-meas- demise as inevitable.A decade from now, USB will also play a major role; indeed, urement applications. on test floors and maybe even in some REMOTE REMOTE LOCAL design labs, you’ll still see instruments UNIX-BASED CONTROLLER WINDOWS-BASED CONTROLLER WINDOWS-BASED CONTROLLER with IEEE 488 connectors and cables, but USER USER USER you’ll probably have to look APPLICATION APPLICATION APPLICATION Figure 1 around for a while to find them. VISA VISA The main reason that IEEE 488 will LIBRARY LIBRARY survive for so long is that, for years to come, many instruments with IEEE 488 VXI-11 VXI-11 ASCII GPIB CLIENT CLIENT ports will continue to perform useful SERIAL WINDOWS-BASED ETHERNET work for their owners. Instruments such OSCILLOSCOPE LAN GPIB-LAN ADAPTER as benchtop DMMs measure quantities WINDOWS-SIDE EMBEDDED-SOFTWARE SIDE ETHERNET WITH VXI-11 GPIB OF INSTRUMENT OF INSTRUMENT such as volts, amperes, and ohms, which LAN HARDWARE RS-232 USER will not change in 20 years—or ever. Sure, HARDWARE APPLICATION newer DMMs will be faster, more accu- VXI-11 rate, and less expensive and will measure VISA VXI-11 LIBRARY lower currents and higher resistances, but CLIENT if you own a DMM that meets your needs ASCII VIRTUAL SOFTWARE SERIAL GPIB and still reliably meets its specifications, GPIB GPIB CONNECTION you require a strong incentive to replace NON-WINDOWS-BASED it. On the other hand, some types of in- INSTRUMENTS struments, such as oscilloscopes, change The software architecture of a system that incorporates IEEE 488 and RS-232 interfaces can more rapidly. Signal speeds continue to appear daunting, but, with modern development tools and instrument drivers, application devel- increase, making wider bandwidth scopes opment is generally less difficult than this diagram suggests (courtesy Tektronix).

50 edn | June 12, 2003 www.edn.com designfeature IEEE 488

The most obvious reasons for turning derstanding instrument I/O: perfor- IEEE 488 connectors and cables. to computer-standard interfaces in place mance and protocols”). In fact, in typi- Industry groups and software vendors of IEEE 488 for instruments are cost, cal instrumentation applications, which are hard at work on the infrastructure size, cable length of instrument net- involve short messages, IEEE 488, rather problem. They aim to make customers’ works, and increasing difficulty of in- like the tortoise that won the race with libraries of control routines work with- stalling specialized controllers the hare, can prove faster than protocols out modification through the PC’s USB in newer PCs. Here, “PCs” refer not just that are nominally hundreds of times as or Ethernet port and the corresponding to , but also to the new breed of fast. Besides speed, the most important ports of instruments that lack IEEE 488 small desktop machines in “sealed” en- reasons for staying with IEEE 488 are the interfaces. Moreover, several companies closures. Greater speed, an apparent ad- existence of such a large infrastructure now offer external adapters, which let vantage of the newer interfaces, is often supporting it, instruments’ long service PCs that provide only USB or Ethernet an illusion, however (see sidebar,“Un- lives, and the physical ruggedness of ports and lack IEEE 488 ports control in- UNDERSTANDING INSTRUMENT I/O: PERFORMANCE AND PROTOCOLS By Joe Mueller, Agilent Technologies With alternatives to IEEE 488 The USB implementers’ forum the system sends more short RPCs (remote-procedure becoming available for instru- has recently completed defining transactions than long ones. In calls): These calls enable func- mentation, understanding the the USBTMC (USB Test and these cases, the time to do a tions called in one computer to impact of selecting new I/O Measurement Committee) short transaction is a better pre- execute in a remote computer. approaches is sometimes diffi- instrument protocol. When you dictor of the I/O performance. Computer systems commonly cult. Although most engineers use it with the USB488 protocol, The 10-byte-turnaround test use RPCs as building blocks for are aware of the convenience USBTMC provides comprehen- measures how long it takes to high-level protocols and distrib- and cost benefits of computer- sive IEEE 488 emulation. send a 10-byte query and then uted systems. For test and mea- standard I/O, it is also important Table A shows typical perfor- read a 10-byte response. This surement, RPCs relieve you of to understand how an I/O mance of several interfaces test shows the software and dealing with the complexity of approach will affect system implemented in typical instru- protocol overhead to set up a SCPI or creating external instru- throughput and the impact of ments communicating with a transaction. Even when the ment drivers. With RPCs, your various protocols on a system. high-speed computer. Hardware messages are hundreds of program calls a high-level func- Formally, protocols are the limits the IEEE 488 values, which bytes, the time to set up the tion that executes in the instru- conventions that you establish will not improve significantly transfer is usually greater than ment, eliminating the need to on both ends of the interface to over time. On the other hand, the actual data-transfer time. create a driver to translate func- accomplish a task. For these pur- the Ethernet values scale with The total time to query a large tion calls into SCPI commands. poses, the most important issues the speed, so new block is roughly the turnaround File-system protocols: These are the types of tasks the system high-speed devices will be a fac- time plus the number of bytes protocols provide a way for an performs. Today, the major pro- tor of five to 10 times as fast on transferred divided by the trans- instrument to present its internal tocols for instrumentation are both the transfer-rate and 10- fer rate. data as files on your computer. those that transmit ASCII strings, byte-turnaround benchmarks. In spite of the cost and speed When you use this technique, or SCPI (standard commands for The USB performance will also benefits of computer-standard measurement data and screen programmable instruments). scale, but less dramatically than I/O, the availability of additional images from the instrument are IEEE 488 intrinsically supports Ethernet. protocols provides another com- simply files that you can copy ASCII communication. The two pelling reason for engineers to from the instrument to the your primary protocols for network- TRANSFER RATE CAN MISLEAD move away from IEEE 488. computer. based instruments are VXI-11, Many I/O-performance evalu- Some protocols of particular Although all of these proto- which provides thorough emula- ations focus on the maximum interest to test and measure- cols are available, many instru- tion of such IEEE 488 capabilities transfer rate. Transfer rate is ment are: ments still lack them. As these as device clear and serial poll; obviously important when you Browser interface (http): At and other protocols become and TCP/IP (Transfer Control try to estimate how long it takes first, you may not understand more common and I/O perfor- Protocol/Internet Protocol), or to transfer large blocks of data, why you might want an instru- mance increases, instruments “sockets,” which provides only such as an oscilloscope trace. ment to produce a Web page. will increasingly move to com- ASCII communication. However, in many applications, However, a couple of exciting puter-standard I/O. applications are copying an TABLE A—TYPICAL TRANSFER RATES OF SEVERAL I/O image of the instrument’s Author’s biography APPROACHES WITH TYPICAL INSTRUMENTS front panel directly into a Joe Mueller is a fellow at Agilent Interface Transfer rate 10-byte turnaround time report, or being able—from Technologies (Loveland, CO). IEEE 488 500 kbytes/sec 600 msec home or from around the He has an MSEE from the USB (USBTMC-USB488) 10 Mbytes/sec 700 msec world—to check the status University of Illinois—Urbana/ 100-Mbps Ethernet (VXI-11) 1 Mbyte/sec 2 msec of an experiment running Champaign and is the president 100 Mbps Ethernet (TCP/IP) 4 Mbytes/sec 600 msec in a lab. of the IVI Foundation.

52 edn | June 12, 2003 www.edn.com designfeature IEEE 488 struments whose only interface is include their own Ethernet interfaces, or an IEEE 488 port. The compatibil- the system must include an adapter that ity that the software libraries and communicates with the host via Ethernet port adapters make possible is ex- and with the instruments via IEEE 488 or actly what you need to economi- USB. This adapter can be small and is cally and quickly build instru- usually less expensive than a PC. mentation systems that mix Bear in mind, though, that if your test communication protocols. equipment generates a lot of network Using an instrument as a Web traffic by sending large amounts of data server is one aspect of 21st-centu- The 33220A function/waveform generator is one of the to the host, it may be inappropriate to ry instrument interfacing that no- first instruments from Agilent Technologies to incorpo- share the Ethernet LAN with other users. body could have envisioned when rate a USB 2.0 interface. Despite the seemingly huge bandwidth of HPIB’s developers invented the 100-Mbps and 1-Gbps Ethernet LANs, bus. Web-server technology is particu- the sensors still constitute overkill. you may find that your test setup must larly well-suited to instruments that con- For test instruments, an advantage of have a control computer close to the in- nect to Ethernet networks and that use an Ethernet connection over a USB or struments, and, to keep traffic on the TCP/IP (Transfer Control Protocol/In- IEEE 488 connection is Ethernet’s much shared network manageable, the control ternet Protocol). greater allowable cable length. Ethernet computer must reduce the data before In one sense, some proponents of LANs—even using gigabit-per-second transmitting it to the host. Web-based test and measurement have Ethernet technology—can span thou- made more of this technology than is jus- sands of feet. USB and IEEE 488 are lim- TURNABOUT ISN’T ALWAYS FAIR PLAY tified. It’s true that Web-server technol- ited to tens of feet. Although the shorter When you use USB as your instru- ogy has become so compact and inex- cables are usually adequate for linking mentation bus, a feature that at first ap- pensive that individual sensors costing no units mounted in several adjacent equip- pears to be a USB advantage can turn more than a few hundred dollars each can ment racks, the IEEE 488 and USB ap- into a complication if you configure your transmit Web pages that users can view proaches can fail if the computer that system differently from the way USB’s via the browser software of any Web-en- controls the test setup is system architects envi- abled PC. Still, the approach quickly be- not adjacent to the in- sioned. In the absence of comes unmanageable in applications that strument racks. not yet widely available involve more than a few sensors. Engineers have often OTG capabilities, USB is a Applications involving hundreds and solved this problem by host-centric bus. If one of even thousands of sensors are common. assigning the instru- your instruments is built on To aggregate the multiple device outputs ment-control functions a PC, as are today’s highest into a Web page that portrays the data in to a computer near the The National Instruments performance digital oscillo- a form that users can understand, these test equipment and us- TNT5002 combines IEEE 488 scopes and logic analyzers, applications need software that can’t re- ing Ethernet to link this control with a PCI interface. the instrument can act as side within individual sensors. If more control computer to the the host PC for your com- than a few users are to view the data, the more distant host, which might perform puter-controlled test setup. But, if you best arrangement is to let the computer data reduction and provide the user in- want to use a separate computer as the that controls the test setup aggregate the terface. Now, however, you can often host, the host can’t use USB to commu- data and serve the Web page. Thus, eliminate the separate control comput- nicate with the computer-based instru- though inexpensive, servers embedded in er. To do without it, the instruments must ment, because such an instrument’s USB port is the wrong type. The developers of FOR MORE INFORMATION... USB, including USB 2.0, intended it to For more information on Ethernet, USB, or IEEE 488 hardware or software products for instrument interfac- have one computer per bus, and that ing, go to www.edn.com/info and enter the reader service number. When you contact any of the following computer had to be the host. manufacturers directly, please let them know you read about their products in EDN. To make the PC-based instrument act Adept Scientific Dataq Instru- Fluke Corp Keithley Instru- National Instru- as a USB peripheral and not a host, you Inc ments www.fluke.com ments Inc ments need hardware that isn’t commonly www.adeptscience. www.dataq.com Enter No. 307 www.keithley.com www.ni.com available—an I/O adapter card that con- co.uk Enter No. 304 Enter No. 310 Enter No. 312 Enter No. 301 ICS Electronics tains a USB-peripheral connector and Data Translation www.icselect.com LeCroy Corp Tektronix Inc peripheral controller—and you need to Agilent www.datx.com Enter No. 308 www.lecroy.com www.tektronix.com modify the BIOS firmware on the com- Technologies Enter No. 305 Enter No. 311 Enter No. 313 puter-based instrument’s PC mother- www.agilent.com IOtech Inc board. For many PC-based instruments, Enter No. 302 Dewetron Inc www.iotech.com www.dewamerica. Enter No. 309 a more convenient approach exists, how- Capital Equip- com ever. If the instrument’s PC ment Corp Enter No. 306 SUPER INFO NUMBER contains an Ethernet port, as many do, www.cec488.com For more information on the products available from all of the you can use that port for communication vendors listed in this box, enter no. 314 at www.edn.com/info. Enter No. 303 with the host and you can use the PC-

54 edn | June 12, 2003 www.edn.com designfeature IEEE 488

based instrument as the test setup’s con- trol computer. You can’t, however, use this elegant approach if the manufactur- er designed the PC-based instrument’s embedded software to make the instru- ment a closed system, which performs only the primary instrument functions. One vendor designed its older PC-based scopes in exactly this way. National Instruments’business started with IEEE 488 interfaces and grew to in- clude what is probably the industry’s widest array of data-acquisition and modular-instrumentation hardware as well as a broad assortment of data-ac- quisition and test-and-measurement software. LabView is the company’s best- known software package and probably its best-known product. Nevertheless, de- spite all of the other businesses it has en- tered, NI continues to supply IEEE 488 interfaces and gives no indication that it will curtail its efforts in this area any time soon. In fact, it has just introduced an IEEE 488-interface IC, which it will use in its own hardware products and will re- sell to companies that continue to design IEEE 488 interfaces into test-and-meas- urement products. By combining IEEE 488 and PCI connectivity as well as IEEE 488 transceivers in one chip, the TNT- 5002 helps instrument manufacturers simplify instrument design. On a pc board, the chip occupies less room than do the traditional three or four chips, thus making instruments easier and less expensive to manufacture. The chip uses a 3.3V PCI core, supports both 3.3 and 5V signaling, and complies fully with re- vision 2.2 of the PCI local-bus specifica- tion. A development kit containing 24 chips costs $600.˿

Author’s biography Senior Technical Editor Dan Strassberg has been providing EDN’s coverage of in- struments that inter- face via IEEE 488 for almost 16 years. You can reach him at [email protected].

Reference 1. Rowe, Martin, “Map the route to USB instruments,”Test and Measurement World, May 2003, pg 41.

56 edn | June 12, 2003 www.edn.com