Boonton CPS2000 User Programming Manual

0 (0)
CPS2000
True-Average Connected Power Sensors
PROGRAMMING REFERNCE
MANUAL
Rev. 20180720
Table of Contents
1 Introduction ............................................................................................................................................ 5
1.1 Scope ................................................................................................................................................ 5
1.2 Referenced Documents ................................................................................................................... 5
1.3 Definitions ........................................................................................................................................ 5
2 Command Syntax .................................................................................................................................... 6
2.1 Command Parameters & Response Types ....................................................................................... 6
2.1.1 Numeric Parameters & Response Types ............................................................................... 6
2.1.2 Boolean Parameters & Response Types ............................................................................... 6
2.1.3 Discrete (Enumeration) Parameters & Response Types ....................................................... 7
2.1.4 ASCII String Parameters & Response Types .......................................................................... 7
2.2 Message Termination & Maximum Length ..................................................................................... 7
2.3 Syntax Conventions .......................................................................................................................... 8
3 Status Reporting ................................................................................................................................... 10
3.1 Status Registers Model .................................................................................................................. 10
3.1.1 Condition Register ............................................................................................................... 10
3.1.2 Transition Filter Registers ................................................................................................... 11
3.1.3 Event Register ..................................................................................................................... 11
3.1.4 Enable Register ................................................................................................................... 11
3.2 Operation Status ............................................................................................................................ 11
3.3 Questionable Status ....................................................................................................................... 13
3.4 Standard Event Status .................................................................................................................... 14
3.4.1 Standard Event Status Register ........................................................................................... 14
3.4.2 Standard Event Status Enable Register ............................................................................... 15
3.5 Status Byte ..................................................................................................................................... 15
3.5.1 Service Request Enable Register ......................................................................................... 16
3.6 Error Codes .................................................................................................................................... 16
4 SCPI Conformance Information ............................................................................................................ 18
5 Measurement Sequence ...................................................................................................................... 19
5.1 Single Measurement Mode ........................................................................................................... 19
5.2 Continuous Measurement Mode ................................................................................................... 20
5.3 Power Measurements .................................................................................................................... 21
5.3.1 Power Measurement Filtering ............................................................................................ 21
5.3.2 Power Measurement Averaging ......................................................................................... 21
5.3.3 Interaction with FETCh[:SCALar][:POWer:AC]?................................................................... 21
6 Example Command Sequences ............................................................................................................ 23
6.1 Taking a Power Measurement with Software Triggering .............................................................. 23
6.2 Continuous Power Measurements ................................................................................................ 23
6.3 Setting Units, Offset, and Correction Frequency ........................................................................... 24
6.4 Retrieving Device Information ....................................................................................................... 24
6.5 Enabling Operation Status Information & Detecting Status Changes ........................................... 25
6.6 Retrieving and Setting Network Configuration .............................................................................. 25
7 Command Reference ............................................................................................................................ 27
7.1 Common Commands (IEE488.2 Commands) ................................................................................. 27
*CLS 27 *ESE 27 *ESE? 27 *ESR? 28 *IDN? 28 *OPC 28 *OPC? 29 *RST 29 *SRE 30 *SRE? 30 *STB? 30 *TST? 31
7.2 Measurement Subsystem (MEASurement Commands) ................................................................ 31
FETCh[:SCALar][:POWer:AC]? ........................................................................................................ 31
READ[:SCALar][:POWer:AC]? ......................................................................................................... 32
FETCh[:SCALar]:TEMPerature? ...................................................................................................... 33
READ[:SCALar]:TEMPerature? ....................................................................................................... 33
7.3 Sense Subsystem (SENSe Commands) ........................................................................................... 34
SENSe:AVERage:COUNt ................................................................................................................. 34
SENSe:AVERage:COUNt? ................................................................................................................ 34
SENSe:AVERage:COUNt:AUTO ....................................................................................................... 35
SENSe:AVERage:COUNt:AUTO? ..................................................................................................... 35
SENSe:CORRection:OFFset[:MAGNitude] ...................................................................................... 36
SENSe:CORRection:OFFset[:MAGNitude]? .................................................................................... 36
SENSe:FILTer:STATe ....................................................................................................................... 37
SENSe:FILTer:STATe? ..................................................................................................................... 37
SENSe:FILTer:TIMe ......................................................................................................................... 38
SENSe:FILTer:TIMe? ....................................................................................................................... 38
SENSe:FREQuency .......................................................................................................................... 39
SENSe:FREQuency? ........................................................................................................................ 39
7.4 Status Subsystem (STATus Commands) ......................................................................................... 40
STATus:OPERation[:EVENt]? .......................................................................................................... 40
STATus:OPERation:CONDition? ..................................................................................................... 40
STATus:OPERation:ENABle............................................................................................................. 41
STATus:OPERation:ENABle? ........................................................................................................... 41
STATus:QUEStionable[:EVENt]? ..................................................................................................... 42
STATus:QUEStionable:CONDition? ................................................................................................ 42
STATus:QUEStionable:ENABle ....................................................................................................... 43
STATus:QUEStionable:ENABle? ..................................................................................................... 43
STATus:PRESet ............................................................................................................................... 44
7.5 System Subsystem (SYSTem Commands) ...................................................................................... 45
SYSTem:ERRor[:NEXT]? .................................................................................................................. 45
SYSTem:COMMunicate[:NETwork]:MAC? ..................................................................................... 45
SYSTem:COMMunicate[:NETwork]:DHCP ...................................................................................... 46
SYSTem:COMMunicate[:NETwork]:DHCP? .................................................................................... 46
SYSTem:COMMunicate[:NETwork]:IP ............................................................................................ 47
SYSTem:COMMunicate[:NETwork]:IP? .......................................................................................... 47
SYSTem:COMMunicate[:NETwork]:SUBNet .................................................................................. 47
SYSTem:COMMunicate[:NETwork]:SUBNet?................................................................................. 48
SYSTem:COMMunicate[:NETwork]:GATeway................................................................................ 48
SYSTem:COMMunicate[:NETwork]:GATeway? .............................................................................. 49
SYSTem:VERSion? .......................................................................................................................... 49
SYSTem:INFO? ................................................................................................................................ 50
SYSTem:INFO:EXTended? .............................................................................................................. 50
7.6 Trigger Subsystem (TRIGger Commands) ...................................................................................... 51
TRIGger:SOURce ............................................................................................................................. 51
TRIGger:SOURce? ........................................................................................................................... 51
TRIGger[:IMMediate] ..................................................................................................................... 52
INITiate[:IMMediate] ..................................................................................................................... 52
INITiate:CONTinuous...................................................................................................................... 53
INITiate:CONTinuous? .................................................................................................................... 53
ABORt 53
7.7 Unit Subsystem (UNIT Commands) ................................................................................................ 54
UNIT:POWer ................................................................................................................................... 54
UNIT:POWer? ................................................................................................................................. 54
8 Revision Notes:
.................................................................................................................................... 55
TABLE OF CONTENTS Page 4
1 Introduction
1.1 Scope
This document is intended to serve as a specification and reference for the instrument commands supported by the CPS2000 Series True-Average Connected Power Sensors. It is not intended to fully describe the SCPI language, as that information can be retrieved from the SCPI Consortium and/or IEEE. However, where appropriate, some information specified in the SCPI specification may be repeated in this document for clarification purposes.
1.2 Referenced Documents
Ref
Title
Identification/Revision
Source
[1]
Standard Commands for Programmable Instruments (SCPI)
1999.0
1999 SCPI Consortium
[2]
ANSI/IEEE Standard 488.2-1987
488.2-1987
The Institute of Electrical and Electronics Engineers, Inc.
1.3 Definitions
Term/Abbreviation
Definition
SCPI
Standard Commands for Programmable Instruments
Command
A SCPI instruction consisting of keywords, parameters, and punctuation.
Query
A special type of command used to retrieve data and information from the device.
1-1 INTRODUCTION Page 5
2 Command Syntax
SCPI Commands and queries are sent as standard ASCII strings through various interfaces. Following standard SCPI ’99 syntax, the CPS2000 SCPI commands are made up of keywords, parameters, and various punctuation.
Commands consist of one or more keywords, separated by colon “: characters, with zero or more parameters starting with a <space> character. In general, commands are not acknowledged by any sort of response message.
Queries follow the same syntax as general commands, but end with a question mark “? character. Upon receiving a query command, the device will return data according to the specified query. Queries occasionally also have parameters, located after the ? character.
2.1 Command Parameters & Response Types
Several commands take one or more parameters as part of the command, while query commands return data in particular formats. SCPI defines different data formats for use in these parameters and responses including numerical values, Boolean values, enumerations, and strings.
Within this document, expected data types are specified along with each command’s specification.
For more information on the data types supported by SCPI, refer to the SCPI ’99 specification and IEEE
488.2.
2.1.1 Numeric Parameters & Response Types
Numeric parameters and response types are integer or floating point numerical values that can be positive or negative, depending on the command or query. Numerical values follow the formatting specifications of the NR1 format defined in IEEE 488.2. Following SCPI syntax, numerical values are transmitted as ASCII characters.
Denoted as:
<numeric_value>
For some commands, an additional unit suffix component is supported to denote units for a parameter. Suffix components are always optional, but when supported by a command, are documented with that command. When included, units suffix components are denoted with a numerical value as:
<numeric_value><suffix>
2.1.2 Boolean Parameters & Response Types
Boolean parameters and response types are binary variables having two possible values. Boolean parameters and response types can be denoted using:
2-1 COMMAND SYNTAX Page 6
ON or OFF
-or-
1 or 0
Where ON is equivalent to 1 and OFF is equivalent to 0.
Either format is accepted. Within this document, Boolean parameters and response types generally use the ON or OFF formatting to describe the meaning of each option.
Denoted as:
<Boolean>
2.1.3 Discrete (Enumeration) Parameters & Response Types
Discrete parameters and response types are values that have a specific set of supported options. The possible options for a command is documented with the command, and any options not specified in this document can be assumed as unsupported options.
Denoted as:
<Option1|Option2|Option3>
2.1.4 ASCII String Parameters & Response Types
The CPS2000 series of devices also supports ASCII string parameters and response types. Some commands return textual information and/or take text as a parameter. In general, ASCII string parameters and response types support the 8-bit ASCII character set. Any other character formatting is not supported.
Denoted as:
<string-label>
where “label” is a descriptive label for the expected contents of the string
2.2 Message Termination & Maximum Length
SCPI commands and responses are terminated upon receipt of a message terminator. The CPS2000 series of power sensors make use of a new-line (\n) character as its message terminator.
Additionally, for the CPS2000 series of devices, the maximum length allowed for a single command is 256 bytes.
2-2 COMMAND SYNTAX Page 7
2.3 Syntax Conventions
Specific syntax conventions are as follows:
CHARACTERS
DESCRIPTION
EXAMPLE
|
A vertical pipe character between keywords and/or parameters indicates alternate choices.
UNIT:POWer <DBM|W>
DBM and W are both accepted, but alternate choices.
[ ]
Indicates that the enclosed keywords are optional when composing a command. The enclosed keywords or parameters will be assumed even if omitted.
INITiate[:IMMediate]
:IMMediate is optional, and the
command is assumed even if instead sent as INITiate
:
Separates keywords within a complete command tree. Keywords further to the right within a command represents commands lower in the SCPI command tree, where keywords to the left represent more base, high-level subsystems of a command tree.
INITiate:CONTinuous
INITiate and CONTinuous are
separate keywords, but are combined to make up a single command using the : character.
,
Separates adjacent parameters or responses when more than one parameter or response is expected for a command.
SYSTem:ERRor[:NEXT]?
returns
<numeric_value>,<string-description>
Corresponding to 2 components of the response – a numerical value and a string value.
< >
Indicates that the enclosed content is not to be used literally in a command, but just represents and describes the necessary content.
SENSe:FREQuency <numerical_value>
Where <numerical_value> corresponds to a user-filled parameter for the SENSe:FREQuency command.
2-3 COMMAND SYNTAX Page 8
CHARACTERS
DESCRIPTION
EXAMPLE
Upper-case
keyword
characters
Indicates the minimum set of characters for a command.
SENSe:FREQuency?
In this command, only the SENS and
FREQ characters are required. As such,
an equivalent command would be:
SENS:FREQ?
Lower-case
keyword
characters
Additional, optional characters for a command. These characters can be included or omitted from a command string. If any are omitted, all lower-case keyword characters must be omitted.
INITiate:CONTinuous
In this command, only the INIT and
CONT characters are required. As such,
an equivalent command would be:
INIT:CONT
Whitespace
Generally ignored as long as they are not included within a commands keywords.
A single <space> character is required to separate parameters from a command’s keywords.
2-4 COMMAND SYNTAX Page 9
3 Status Reporting
In general, the status registers are always-positive (unsigned) 16-bit registers.
Although SCPI supports the use of transition filters, the CPS2000 series of devices does not make use of any transition filters. Additionally, the SCPI specification includes an optional feature for remapping bits within the Operation and Questionable Status Registers. The CPS2000 series of devices does not support that feature.
3.1 Status Registers Model
Each of the status registers supported by the CPS2000 series of devices follows a particular model according to the SCPI specification. Each Status described in the following sections has a set of 4 associated registers: a Condition register, Transition Filter registers, an Event register, and an Enable register. For the CPS2000 series of devices, the Transition Filter registers are not used.
For an example of using registers, see Section 6.5.
3.1.1 Condition Register
The Condition Register component of a status serves as the source of information for the rest of the Status Registers Model. This register is updated in real-time and is read-only. Bits set within the Condition Register describe conditions that occur in real-time.
3.1.2 Transition Filter Registers
Although the SCPI specification defines a set of Transition Filter Registers, the CPS2000 devices do not include support for any transition filters.
Instead, anytime a bit transitions from 0 to 1 in the Condition Register occcurs, the corresponding bit in the Event Register is set to 1.
3.1.3 Event Register
The Event Register component of a Status consists of bits assigned to events. Bits in the Event Register are latched and only cleared by a query or a *CLS command. The Event Register is read-only.
3.1.4 Enable Register
The Enable Register component of a Status contains bits that define what bits in the Event Register
generate a ‘1’ for the summary bit in the Status Byte. When a bit in the Enable Register is set to a ‘1’, a ‘1’ for the corresponding Event Register bit will result in a ‘1’ for the summary bit in the Status Byte.
3.2 Operation Status
The Operation Status provides general operational status information for the instrument. It follows the Status Registers Model described in section 3.1 and includes a Condition Register, Event Register, and Enable Register.
Configuration of each of these registers is performed with the STATus:OPERation SCPI commands as described in section 7.4 Status Subsystem (STATus Commands).
The Operation Status Condition Register is a 16-bit unsigned register and has the following definition:
BIT
DESCRIPTION
0
Calibrating bit Set when the instrument is performing a calibration.
1
Settling bit
Not Used
2
Ranging bit
Not Used
3
Sweeping bit
Not Used
4
Measuring bit
Set when the instrument is in the MEASURING state and is taking an actual power measurement.
See Section 5 Measurement Sequence for more details.
3-1 STATUS REPORTING Page 11
BIT
DESCRIPTION
5
Waiting for Trigger bit
Set when the instrument is in the
WAITING_FOR_TRIGGER state.
See Section 5 Measurement Sequence for more details.
6
Waiting for ARM bit Not Used
7
Correcting bit Not Used
8–12
Not Used
13
Instrument Summary bit
Not Used
14
Programming Running bit Not Used
15
Always Zero
3-3 STATUS REPORTING Page 12
3.3 Questionable Status
The Questionable Status provides information indicating the quality of various aspects of the device. A bit set within the Questionable Status Condition Register indicates that the associated data is of questionable quality due to some condition affecting that parameter. For example, if the Temperature bit is set, that means the accuracy of the Temperature reading is of questionable quality.
The Questionable Status follows the Status Registers Model described in section 3.1 and includes a Condition Register, Event Register, and Enable Register.
Configuration of each of these registers is performed with the STATus:QUEStionable SCPI commands as described in section 7.4 Status Subsystem (STATus Commands).
The Questionable Status Condition Register is a 16-bit unsigned register with the following definition:
BIT
DESCRIPTION
0
Questionable Voltage bit
Not Used
1
Questionable Current bit
Not Used
2
Questionable Time bit
Not Used
3
Questionable Power bit Set to a 1 when the latest power measurement is of questionable quality.
4
Questionable Temperature bit Set to a 1 when the latest temperature value is of questionable quality.
5
Questionable Frequency bit
Not Used
6
Questionable Phase bit
Not Used
7
Questionable Modulation bit Not Used
8
Questionable Calibration bit Set to a 1 when the device calibration is of questionable quality.
9
Not Used
10
Not Used
11
Not Used
12
Not Used
3-4 STATUS REPORTING Page 13
BIT
DESCRIPTION
13
Instrument Summary bit
Not Used
14
Command Warning bit Not Used
15
Always Zero
3.4 Standard Event Status
The Standard Event Status is a register described by IEEE 488.2. In general, it contains various error status information and basic operation information. From the full Status Registers Model, the Standard Event Status only consists of 2 registers: one containing the real-time status of standard events, and one to enable bits for generation of the Standard Event Status Summary Bit.
3.4.1 Standard Event Status Register
The Standard Event Status Register is read-only and contains the real-time status of various events.
The Standard Event Status Register’s value can be obtained using the *ESR? query.
The Standard Event Status Register’s value is cleared when:
a. Sending a *CLS command or b. Querying the value using the *ESR? query
The Standard Event Status Register is an 8-bit unsigned register with the following definition:
BIT
DESCRIPTION
0
Operation Complete bit When 1, indicates the last requested operation was completed.
1
Request Control bit Not Used
2
Query Error bit Not Used
3
Device Dependent Error bit When 1, indicates a device error occurred.
4
Execution Error bit When 1, indicates an execution error occurred.
5
Command Error bit When 1, indicates a command syntax error occurred.
6
User Request bit
Not Used
3-5 STATUS REPORTING Page 14
BIT
DESCRIPTION
7
Power On bit Not Used
3.4.2 Standard Event Status Enable Register
The Standard Event Status Enable Register is read/write and configures which bits of the Standard Event Status Register constitute a 1 in the Standard Event Status Summary Bit. If a bit of the Standard Event Status Enable Register is configured as 1 and the corresponding bit of the Standard Event Status Register is also 1, the Standard Event Status Summary Bit will be set to a 1.
The Standard Event Status Enable Register’s value can be configured using the *ESE command and can be retrieved using the *ESE? query.
The Standard Event Status Enable Register’s value is cleared when:
a. Power cycling the device or b. Sending a *ESE 0 command.
3.5 Status Byte
The Status Byte contains summary information about the state of the device. It contains bits corresponding to the Questionable Status Summary, Standard Event Status Summary and the Operation Status Summary, which are set as configured using the Status Registers Model (see section 3.1 for more details).
The value of the Status Byte is obtained using the *STB? query.
The Status Byte definition is as follows:
BIT
DESCRIPTION
0
Not Used
1
Not Used
1 if an error/event is present in the Error/Event queue, or 0 if no error/event is present.
2
Errors/events are retrievable using the *ESR? command.
3
Questionable Status Summary bit
4
Message Available bit (MAV) Set to a 1 when a message is available, such as when a power measurement is complete and ready for retrieval.
3-6 STATUS REPORTING Page 15
BIT
DESCRIPTION
5
Standard Event Status Summary bit
6
Service Request bit Summary status bit for the Status Byte itself. Configuring the behavior of this bit is performed using the *SRE command.
7
Operation Status Summary bit
3.5.1 Service Request Enable Register
The Status Byte also has an Enable Register for configuring the Service Request bit (bit 6 of the Status Byte). This register works similar to the other enable registers, configuring which bits of the Status Byte constitute a 1 in the Service Request bit.
The Service Request Enable Register can be configured using the *SRE command.
3.6 Error Codes
The list of SCPI error codes that are reported by the CPS2000 series of devices is as follows:
ERROR
CODE
DESCRIPTION
-100
General command error
-101
Invalid character
-102
Syntax error
-103
Invalid separator
-104
Data type error
-105
GET (query) not allowed
-108
Parameter not allowed
-109
Missing parameter
-110
Command header error
3-7 STATUS REPORTING Page 16
ERROR
CODE
DESCRIPTION
-115
Unexpected number of parameters
-120
Numeric data error
-130
Suffix error
-140
Character data error
-150
String data error
-160
Block data error
-170
Expression error
-200
General execution error
-220
General parameter error
-222
Data out of range error
-230
Data corrupt or stale error
-240
General hardware error
-241
Hardware missing
-242
Hardware malfunction
-300
Generic, device-specific error
-350
Queue overflow
3-8 STATUS REPORTING Page 17
3-8 STATUS REPORTING Page 17
Loading...
+ 38 hidden pages