Instrument Control Toolbox

Communicating with Instruments

Instrument Control Toolbox can communicate with instruments by a variety of methods, including:

  • Instrument drivers
  • Communication protocols
  • Instrument Control app
  • Quick-Control Oscilloscope
  • Quick-Control Function Generator
  • Simulink blocks

The toolbox provides functions for creating objects that contain properties related to the instrument and to the instrument control session.

Instrument Drivers

Instrument drivers let you communicate with instruments independently of device protocols. As a result, you can use common MATLAB terminology for communication without learning instrument-specific commands, such as Standard Commands for Programmable Instruments (SCPI).

The toolbox lets you work with VXIplug&play, IVI, and MATLAB instrument drivers. VXIplug&play and IVI instrument drivers often ship with your instrument; they are also available from instrument manufacturer Web sites. If needed, you can create MATLAB instrument drivers with driver development tools included in the toolbox.

Communication Protocols

Instrument Control Toolbox supports communication protocols, including GPIB, serial, TCP/IP, and UDP, for direct communication with instruments. You can also communicate with instruments using VISA over GPIB, VXI, USB, TCP/IP, and serial buses. The toolbox provides a set of functions for creating and working with instruments. These functions let you write commands to an instrument or read data from it for use in MATLAB. The toolbox supports common text commands, such as SCPI. The transferred data can be binary or ASCII.

The toolbox also supports client and server socket communication over TCP/IP and UDP; in addition, it supports the Bluetooth serial protocol for communication with Bluetooth devices.

Test & Measurement Tool

The Test & Measurement Tool enables you to communicate with and configure instruments without writing code. It lets programmers and nonprogrammers:

  • Search for available hardware
  • Connect to an instrument
  • Configure instrument settings
  • Write data to an instrument
  • Read data from an instrument

The Test & Measurement Tool automatically generates MATLAB code from an instrument control session. By saving this code to a MATLAB file, you can execute the same commands programmatically.

Test and Measurement Tool searching for available hardware and drivers.

The Test & Measurement Tool (bottom) searching for available hardware and drivers(top). It communicates with and controls instruments without the need to write code and can automatically generate MATLAB code from your session.

Quick-Control Oscilloscope

Instrument Control Toolbox provides Quick-Control Oscilloscope to automatically determine the best driver and interface technology, enabling quick analysis of captured data. By creating a Quick-Control Oscilloscope object, you can easily control and acquire data into MATLAB.

The Quick-Control Oscilloscope object provides the most common functions for controlling and acquiring data from oscilloscopes so that you do not need to know any details about the underlying instrument driver. In addition to connecting to and collecting data from an instrument, other toolbox functions let you configure enabled channels, acquisition time, vertical range and offset, coupling, trigger level, and trigger slope.

Quick-control oscilloscope object that collects data and changes it settings without requiring knowledge of the instrument drivers.

Quick-Control Oscilloscope object that collects data and changes settings without requiring knowledge of instrument drivers.

Quick-Control Function Generator

Instrument Control Toolbox provides Quick-Control Function Generator to enable quick configuration and download of data to be sent out by the generator. The Quick-Control Function Generator object provides the most common functions for controlling function generators so that you do not need to know any details about the underlying instrument driver. In addition to connecting to the instrument and enabling the output, other toolbox functions let you download arbitrary waveforms into the instrument’s memory and configure the frequency, amplitude, and modulation characteristics of standard waveforms.

Simulink Blocks

Instrument Control Toolbox includes instrument control blocks for use with Simulink. Blocks can send live data from a Simulink model to an instrument or query an instrument for live data to be inserted into a model. The toolbox facilitates hardware selection and configuration for use in Simulink models.

Next: Managing a Session

Try Instrument Control Toolbox

Get trial software

Developing Modular, PXI, and AXIe Test Systems using MATLAB

View webinar