Set Up and Debug an Instrument Control System

Publish Date: Aug 05, 2011 | 1 Ratings | 5.00 out of 5 | Print

Table of Contents

  1. Measurement & Automation Explorer
  2. NI-VISA
  3. NI-488.2
  4. Additional Resources for Set up and Debug
  5. Resources for Owners of Hybrid PXI/LabVIEW/NI TestStand and Instrument Control Systems

This document details how to troubleshoot your instrument control applications with NI Measurement & Automation Explorer (MAX), NI-VISA, NI-488.2, and NI-488.2 driver utilities. For detailed step-by-step instructions for setting up and debugging your instrument control system, visit Getting Started with Instrument Control .

1. Measurement & Automation Explorer

MAX, also known as the configuration manager, presents a unified system view of measurement hardware and software. With MAX, you can define channel names to organize signals or specify scaling functions to convert digitized signals to measurement quantities. The key benefit of the configuration manager is the integration with NI application development environments (ADEs) such as LabVIEW, LabWindows™/CVI , and Measurement Studio, helping you easily combine multiple measurements into a single application without tedious programming. Without these configuration tools, you would spend needless time configuring these measurement functions programmatically.

Figure 1. Measurement & Automation Explorer (MAX)

Back to Top


The Virtual Instrument Software Architecture (VISA) is a standard for configuring, programming, and troubleshooting instrumentation systems.

NI-VISA is a driver software architecture developed by National Instruments to unify communication with GPIB, VXI, PXI, serial (RS232/RS485), Ethernet/LXI, USB, and/or IEEE 1394 instruments and simplify your instrument control programs. The VISA API accesses these instruments through OS calls and the NI-488.2 or other driver software, as shown in Figure 2.

Figure 2. VISA Structure

VISA offers the following benefits:

  • Interface independence, whereby VISA uses the same methods to communicate with instruments, regardless of the interface type. For example, the VISA command to write an ASCII string to a message-based instrument is the same for serial, GPIB, and VXI. With this feature, you can use a single API to work with different instruments.
  • An object-oriented architecture that can easily adapt to new instrumentation interfaces as they are developed in the future. You can easily include new interfaces.
  • Built-in functionality for instrumentation programming in a very compact command set.

Figure 3. NI-VISA Interactive Control

NI-VISA development licenses are included with National Instruments products such as development environments and GPIB hardware.

Back to Top

3. NI-488.2

NI-488.2 is the National Instruments GPIB driver. The NI-488.2 driver provides numerous features that increase development productivity and improve driver usability. Many of these features are unique to NI-488.2 and are not available with any of the lower-cost GPIB products on the market.  The following are some of the features of NI-488.2.

  • Common Driver – NI provides a common GPIB driver that handles NI GPIB controllers for PCI, PCI Express, PXI, PCMCIA, USB, Ethernet, and ISA (PnP). You can easily port an application from one platform to another without having to rewrite software.
  • Driver Localization – NI-488.2 is localized in Japanese, Korean, and simplified Chinese. Localization simplifies board installation, driver operation, and programming because the installation instructions and software are in your native language.
  • Technical Support – NI provides complimentary world-class support through extensive online support options. Giving you timely and accurate answers to your questions is essential to guaranteeing that your projects run smoothly and on time.
  • Multiple Interface Capability – NI-488.2 is one of the few drivers on the market that lets you install and use more than one interface on the same system. For example, you can install an NI PCIe-GPIB at GPIB0 and an NI GPIB-USB-HS at GPIB1 for controlling multiple instruments independently of each other for applications that require more predictable instrument response. Because the driver provides this feature, developing such applications is fairly straightforward – you can replace a GPIB controller with another type of GPIB controller without any software changes.
  • Utilities – NI-488.2 provides several utilities that greatly improve development productivity.

NI-488.2 Utilities

NI-488.2 Communicator

You can use the NI-488.2 Communicator to verify that you can establish simple communication with your GPIB instrument. This is an interactive utility you can use to write commands to your instrument and read responses back from your instrument. It provides detailed information about the status of the NI-488.2 calls, and you can use it to print sample C source code that performs a simple query to a GPIB instrument.

Interactive Control

Interface Bus Interactive Control (IBIC) is available for more advanced, yet very quick, interactive communication with your GPIB instruments. You can use IBIC to interactively enter and execute GPIB functions or routines without using a development application or programming language. By successfully communicating with your GPIB instrument using the IBIC utility, you can quickly confirm that your hardware is fully capable of integration with your programming environment. 

NI I/O Trace

Using NI I/O Trace, you can “trace” driver calls. This feature is extremely useful for application debugging. The NI I/O Trace records all device- and board-level calls with a timestamp so you can easily and efficiently detect errors and timing issues in your application. This utility further differentiates National Instruments GPIB device functionality and usability from others.

GPIB Analyzer

With the GPIB Analyzer, you can analyze the physical bus activity by observing all of the GPIB handshake signals, interface management signals, and data signals. This capability is very useful for advanced debugging where NI I/O Trace alone cannot resolve a problem. In addition, you can analyze bus timing issues in much more detail. GPIB Analyzer software is accessible only with NI GPIB Analyzer boards, such as the PCIe-GPIB+ or PCI-GPIB+.


For additional information on using the utilities above, see How to Use NI-488.2 Utilities.

Architectural Stability

The NI-488.2 driver also provides unparalleled architectural stability, which contributes to increased productivity. Because the driver and the driver architecture are stable, you do not have to waste time rewriting and debugging applications to upgrade them to a new interface or OS. The following are some of the specific features that contribute to architectural stability:

  • API Compatibility – The NI-488.2 API is the de facto industry standard for GPIB communication. The API has improved in performance and efficiency but has remained unchanged from a user standpoint for more than 20 years. With this stability, applications originally written for an ISA board on DOS or a NuBus board on a Macintosh can run unchanged with a PCI Express board on Windows 7.
  • Broad Bus Coverage – NI provides GPIB controllers for the largest variety of buses. In addition to popular buses such as PCI, PCI Express, PXI/CompactPCI, PCMCIA, USB, and Ethernet, NI offers controllers for ISA, SBus (Sun Solaris), PMC, PC/104, and VME among others. Although some of these interfaces require a separate version of the NI-488.2 driver, because the API is the same, you can still port applications from a mainstream interface to a specialty interface with little or no effort.
  • OS Transparency – NI provides complete drivers for interfaces on the most common OSs, such as Windows 7/Vista/XP/Me/2000/9x/NT, Linux, Solaris, and Mac. NI also offers drivers for some interfaces on less common OSs such as HP-UX and Tru64 UNIX. Finally, for interfaces and OSs for which NI does not offer a complete driver, the company provides a driver development kit (NI-488DDK) so you can implement the driver on the OS of your choice. Again, because the driver API is always the same, the user can easily port applications between OSs and interfaces.
  • Availability of Products – NI provides GPIB controllers for the widest variety of buses and continues to offer those products for many years after the bus is no longer popular. NI still sells interfaces for ISA and SBus among others. This support guarantees that you do not have to spend time unnecessarily upgrading an application because an older interface is no longer available.

Finally, because the NI GPIB driver API is the de facto industry standard, lower-cost GPIB providers typically supply a driver that uses a wrapper that responds to calls to the NI driver. Because these driver developers do not know the internal architecture and intricacies of the NI driver, they cannot optimize the performance of their driver. The result is poor performance by these wrapped drivers. In addition, driver developers rarely provide a wrapper for every function in the NI driver, which leaves some applications without certain functions.

Having reliable software ensures minimal downtime as well as a wider variety of systems on which to develop and deploy GPIB applications. Full-featured NI-488.2 driver software has evolved over many man-years of development. For example, with NI-488.2, you can develop multithreaded applications as well as those written to run on multiprocessor or hyperthreaded systems. The driver has been thoroughly tested on those types of systems to ensure reliable, uninterrupted use.

The NI-488.2 driver is included with every GPIB controller/converter and can be purchased separately for additional licenses.

Back to Top

4. Additional Resources for Set up and Debug

Back to Top

5. Resources for Owners of Hybrid PXI/LabVIEW/NI TestStand and Instrument Control Systems


The mark LabWindows is used under a license from Microsoft Corporation. Windows is a registered trademark of Microsoft Corporation in the United States and other countries.


Back to Top

Bookmark & Share


Rate this document

Answered Your Question?
Yes No