User Manual

1
1. Introduction to the SCPI Language
1.1. Communication Interfaces
Computers communicate with the P4120 - 4165 series generator by sending and
receiving commands over USB or RS232 interface. Command is sent and identified in the
form of ASCII character strings for users to easily control the generator and do
user-defined development. Operations that you can do with a computer and a generator
include: Set the generator and output waveforms from the generator.
Connection: Please connect the USB Device port at the rear panel of the generator with
the corresponding USB interface on the computer using an USB cable, or connect the
RS232 port at the rear panel of the generator with the corresponding RS232 interface on
the computer using an RS232 cable.
1.2. Command Syntax
The command systems of this series present a hierarchy structure (tree system) and each
command consists of a “Root” keyword and one or multiple sub-keywords. The keywords
are separated by ":" and are followed by the parameter settings available, "?" is added at
the end of the command string to indicate query and the command and parameter are
separated by "space".
For example,
:FUNCtion:SQUare:DTYCycle {<percent> }
:FUNCtion:SQUare:DTYCycle?
FUNCtion is the root keyword of the command, SQUare and DTYCycle are the
second-level and third-level keywords respectively, all the keywords are separated by “:”.
<percent> denotes the parameter that users can set, the default unit of the numerical
parameters are listed in Appendix
; “?” denotes query; the command
FUNCtion:SQUare:DTYCycle and parameter are separated by “space”. All the command
strings begin with ":" or "*" and have no terminator ("\n" or "\r \n" can be recognized as
terminator also). The commands can be sent continuously (have command execution
queue), the program will be executed in sequence. If the command is correct, "->\n" will
be returned; if wrong, "=?\n" will be returned. If the parameter is invalid or the command