S331E, S332E, S361E, S362E Site Master™MS2711E, MS2712E, MS2713E Spectrum Master™MT8212E, MT8213E Cell Master™ Programming Manual : Programming with SCPI : Subsystem Commands
Subsystem Commands
Subsystem commands control all instrument functions and some general purpose functions. All subsystem commands are identified by the colon used between keywords, as in :INITiate:CONTinuous.
The following information is provided for each subsystem command described in the following chapters.
The command name, See Command Names.
The path from the subsystem root command, See Hierarchical Command Structure.
The query form of the command (if applicable), See Query Commands.
The command title
A description of the purpose of the command.
The data parameters used as arguments for the command, See Data Parameters. This may include the parameter type and the available parameter choices.
Command Names
Typical SCPI commands consist of one or more keywords, parameters, and punctuation. SCPI command keywords can be a mixture of upper and lower case characters. Except for common commands, each keyword has a long and a short form. In this manual, the long form is presented with the short form in upper case and the remainder in lower case. For example, the long form of the command keyword to control the instrument display is :DISPlay.
The short form keyword is usually the first four characters of the long form (example: DISP for DISPlay). The exception to this is when the long form is longer than four characters and the fourth character is a vowel. In such cases, the vowel is dropped and the short form becomes the first three characters of the long form. Example: the short form of the keyword :POWer is :POW.
Some command keywords may have a numeric suffix to differentiate between multiple instrument features such as multiple trace options. For example; keywords :TRACe[:DATA]{1|2|3}, :TRACe1, or :TRACe3.
In the previous paragraph, :TRACe is identical to :TRACe1. If a numeric suffix it not included in a command, the first option is implied. Curly brackets { } designate optional keyword parameters. Square brackets [ ] designate optional command keywords.
As with any programming language, the exact command keywords and command syntax must be used. The syntax of the individual commands is described in detail in the programming command chapters. Unrecognized versions of long form or short form commands, or improper syntax, will generate an error.
Long Format vs. Short Format
Each keyword has a long format and a short format. The start frequency can be specified by :SENSe:FREQuency:STARt or :SENS:FREQ:STAR. The capital letters in the command specification indicate the short form of the command. A mixture of the entire short form elements with entire long form elements of each command is acceptable. For example, :SENS:FREQuency:STAR is an acceptable form of the command. However, :SENS:FREQuen:STA is not an acceptable form of the command because :FREQuen is not the entire short or long form of the command element.
Hierarchical Command Structure
All SCPI commands, except the common commands, are organized in a hierarchical structure similar to the inverted tree file structure used in most computers. The SCPI standard refers to this structure as “the Command Tree.” The command keywords that correspond to the major instrument control functions are located at the top of the command tree. The root command keywords for the SCPI command set are shown in Figure: SCPI Command Tree.
SCPI Command Tree
All instrument SCPI commands, except the :ABORt command, have one or more subcommands (keywords) associated with them to further define the instrument function to be controlled. The subcommand keywords may also have one or more associated subcommands (keywords). Each subcommand level adds another layer to the command tree. The command keyword and its associated subcommand keywords form a portion of the command tree called a command subsystem. The :CONFigure command subsystem is shown in Figure: SCPI :CONFigure Subsystem.
SCPI :CONFigure Subsystem
A colon (:) separates each subsystem. For example, the command :SENSe:FREQuency:STARt <freq> sets the start frequency. The start frequency is part of the :FREQuency subsystem which is part of the :SENSe subsystem. Stop frequency is also part of the :SENSe:FREQuency subsystem. It is specified by :SENSe:FREQuency:STOP.
Query Commands
All commands, unless specifically noted in the commands syntax descriptions, have a query form. As defined in IEEE-488.2, a query is a command with a question mark symbol appended (examples: *IDN? and :OPTions?). When a query form of a command is received, the current setting associated with the command is placed in the output buffer. Query commands always return the short form of the parameter unless otherwise specified. Boolean values are returned as 1 or 0, even when they can be set as on or off.
When sending query commands immediately following an instrument setup command, a delay of up to two seconds may be required to allow the instrument sufficient time to complete the setup and receive the query.
The following identifiers have been used throughout the optional command definitions. Descriptions are provided here. In most cases, units are specified with the individual command.
Description of Command Indentifiers
Amplitude value. Units specified with the command.
Frequency. Units specified with the command.
Integer value, no units. Range specified with the command.
Numeric value, integer, or real.
Percentage value from 0 to 00. Units are always %.
<rel ampl>
Relative amplitude. Units are always dB.
Parameter value in the units of the x‑axis. Units are specified with the command.
The string should be enclosed in either single quotes (‘ ’) or double quotes (“ ”).
The name should be enclosed in either single quotes (‘ ’) or double quotes (“ ”). The need for an extension is documented with applicable commands.
Voltage. Units specified with the command.
Current. Units specified with the command.
Data Parameters
Data parameters, referred to simply as “parameters,” are the quantitative values used as arguments for the command keywords. The parameter type associated with a particular SCPI command is determined by the type of information required to control the particular instrument function. For example, Boolean (ON | OFF) type parameters are used with commands that control switch functions.
Some command descriptions specify the type of data parameter to be used with each command. The most commonly used parameter types are numeric, extended numeric, discrete, and Boolean.
Numeric parameters comprise integer numbers or any number in decimal or scientific notation, and may include polarity signs. This includes <NR1>, <NR2>, and <NR3> numeric data as defined in Data Parameter Notations below. Parameters that accept all three <NR> formats are designated <NRf> throughout this document.
Extended Numeric
Extended numeric parameters include values such as MAXimum and MINimum.
Discrete parameters, such as INTernal and EXTernal, are used to control program settings to a predetermined finite value or condition.
Boolean parameters represent binary conditions and may be expressed as ON, OFF or 1, 0.
Data Parameter Notations
The following syntax conventions are used for data parameter descriptions in this manual:
Parameter Notations
::=a generic command argument consisting of one or more of the other data types
::=boolean values in <NR1> format; numeric 1 or 0
::=ON | OFF. Can also be represented as 1 or 0, where 1 means ON and 0 means OFF
Boolean parameters are always returned as 1 or 0 in <NR1> format by query commands
::=an unsigned integer without a decimal point (implied radix point)
::=a signed integer without a decimal point (implied radix point)
::=a signed number with an explicit radix point
::=a scaled explicit decimal point numeric value with and exponent (e.g., floating point number)
::=SCPI numeric value: <NRf>|MINimum|MAXimum|UP|DOWN|DEFault|NAN (Not A Number)|INFinity|NINFinity (Negative Infinity) or other types
::=<STRING PROGRAM DATA> ASCII characters enclosed by double quotes For example: “OFF”
::=IEEE-488.2 block data format
::=Not Applicable
Unit Suffixes
Unit suffixes are not required for data parameters, provided the values are scaled for the global default units. The instrument SCPI default units are: Hz (Hertz) for frequency related parameters s (seconds) for time related parameters, and m (meters) for distance related parameters.