Scpi Commands And Queries; Creating Commands; Creating Queries; Figure 3-1: Example Of Scpi Subsystem Hierarchy - Tektronix TG 2000 User Manual

Signal generation platform
Table of Contents

Advertisement

Syntax

SCPI Commands and Queries

Creating Commands

Creating Queries

3–4
SCPI is a standard created by a consortium that provides guidelines for remote
programming of instruments. These guidelines provide a consistent program-
ming environment for instrument control and data transfer. This environment
uses defined programming messages, instrument responses, and data format
across all SCPI instruments, regardless of manufacturer. The TG 2000 Signal
Generation Platform uses a command language based on the SCPI standard.
The SCPI language is based on a hierarchical or tree structure (see Figure 3–1)
that represents a subsystem. The top level of the tree is the root node; it is
followed by one or more lower-level nodes.
Figure 3–1: Example of SCPI subsystem hierarchy
You can create commands and queries from these subsystem hierarchy trees.
Commands specify actions for the instrument to perform. Queries return
measurement data and information about parameter settings.
SCPI commands are created by stringing together the nodes of a subsystem
hierarchy and separating each node by a colon.
In Figure 3–1, OUTPut is the root node and CIRCle, STATe, DIAMeter, and
POSition are lower-level nodes. To create a SCPI command, start with the root
node OUTPut and move down the tree structure adding nodes until you reach the
end of a branch. Most commands and some queries have parameters; you must
include a value for these parameters. If you specify a parameter value that is out
of range, the parameter will be set to a default value. The command descriptions,
which start on page 3–35, list the valid values for all parameters.
For example, OUTPut:CIRCle:STATe ON is a valid SCPI command created
from the hierarchy tree in Figure 3–1.
To create a query, start at the root node of a tree structure, move down to the end
of a branch, and add a question mark. OUTPut:CIRCle:STATe? is an example of
a valid SCPI query using the hierarchy tree in Figure 3–1.
Root node
Lower-level
nodes
TG 2000 Signal Generation Platform User Manual

Advertisement

Table of Contents
loading

Table of Contents