Command Arguments And Queries; Semicolon Command Separators; Command Terminators - Boonton SGX1000 Series Programming Reference Manual

Rf signal generator
Hide thumbs Also See for SGX1000 Series:
Table of Contents

Advertisement

1.3.4

Command Arguments and Queries

Many commands require arguments. In this case, the entire command string is sent, followed by the
argument. A space is used to separate the command from the argument. For example,
"SOURce:FREQuency 1e9" sets frequency to 1 GHz. Arguments may be numeric, or alphanumeric. If a
command requires more than one numeric argument, the arguments must be sent as a comma
delimited list.
To read the current value of a particular parameter, the Query Form of its command may be used. A
command query is formed by appending a question-mark ("?") suffix to the command instead of an
argument list. There should not be any whitespace between the command and the suffix. For example,
"SOURce:FREQuency?" queries the frequency parameter and causes the instrument to return its
current value.
1.3.5

Semicolon Command Separators

The semicolon (";") character is used to separate multiple commands on a single line. However, the
parsing path is affected when more than one command is combined on a line. As noted previously, the
first command of a line is always referenced to the root level whether, or not, the command is prefixed
by a colon. However, for the second and succeeding commands, the parsing level is NOT reset to the
root level, but rather referenced from the current node. This allows the parser to remain at the current
node and execute other commands from that node without resending the entire node string. For
example, the following multi-command strings are equivalent:
:SOURce:FREQuency 1e9; :SOURce:POWer 2.12;
:SOURce:FREQuency 1e9; :POWer 2.12;
SOURce:FREQuency 1e9; :POWer 2.12;
If a command does not belong to the same subsystem as the preceding command on the same line, then
its full path must be specified, including the colon prefix.
1.3.6

Command Terminators

All SCPI command strings transmitted to the instrument must be terminated. For commands sent via the
GPIB bus, any character with the IEEE488 EOI (End-Or-Identify) control line asserted may be used as a
terminator. This may be the last letter of the command, query, or argument. Optionally, a CR (ASCII 13)
and/or LF (ASCII 10) may be included. These are ignored by the parser, but if present, the EOI must be
asserted on the last message character transmitted.
On USB and LAN messages, the packetized protocols provide automatic termination of each message.
Again, CR and/or LF may be present, but must be the last message character(s) of the packet.
When the terminating condition is met (end of GPIB message or end of USB or LAN packet), the SCPI
path is first reset to the root level, and the received message is then passed to the SCPI parser for
evaluation.
(two full-path commands)
( second command referenced to SOURce node)
(leading colon omitted from first command)
3

Advertisement

Table of Contents
loading

Related Products for Boonton SGX1000 Series

Table of Contents