No part of this manual may be reproduced
in any form or by any means (including
electronic storage and retrieval or translation into a foreign language) without prior
agreement and written consent from
Keysight Technologies as governed by
United States and international copyright
laws.
Trademarks
PCI Express® and PCIe® are registered
trademarks of PCI-SIG.
Manual Part Number
M8020-91040
Edition
Edition 9.1, August 2017
Keysight Technologies Deutschland GmbH
Herrenberger Strasse 130,
71034 Böblingen, Germany
Technology Licenses
The hard ware and/or software described in
this document are furnished under a
license and may be used or copied only in
accordance with the terms of such license.
U.S. Government Rights
The Software is “commercial computer
software,” as defined by Federal Acquisition
Regulation (“FAR”) 2.101. Pursuant to FAR
12.212 and 27.405-3 and Department of
Defense FAR Supplement
(“DFARS”) 227.7202, the U.S. government
acquires commercial computer software
under the same terms by which the software is customarily provided to the public.
Accordingly, Keysight provides the Software to U.S. government customers under
its standard commercial license, which is
embodied in its End User License Agree-
ment (EULA), a copy of which can be found
at http://www.keysight.com/find/sweula.
The license set forth in the EULA represents
the exclusive authority by which the U.S.
government may use, modify, distribute, or
disclose the Software. The EULA and the
license set forth therein, does not require
or permit, among other things, that Keysight: (1) Furnish technical information
related to commercial computer software
or commercial computer software documentation that is not customarily provided
to the public; or (2) Relinquish to, or otherwise provide, the government rights in
excess of these rights customarily provided
to the public to use, mod ify, reproduce,
release, perform, display, or d isclose commercial computer software or commercial
computer software documentation. No
additional government requirements
beyond those set forth in the EULA shall
apply, except to the extent that those
terms, rights, or licenses are explicitly
required from all providers of commercial
computer software pursuant to the FAR and
the DFARS and are set forth specifically in
writing elsewhere in the EULA. Keysight
shall be under no obligation to update,
revise or otherwise modify the Software.
With respect to any technical data as
defined by FAR 2.101, pursuant to FAR
12.211 and 27.404.2 and DFARS 227.7102,
the U.S. government acquires no greater
than Limited Rights as defined in FAR
27.401 or DFAR 227.7103-5 (c), as applicable in any technical data.
Warranty
THE MATERIAL CONTAINED IN THIS DOCUMENT IS PROVIDED "AS IS," AND IS SUBJECT TO BEING CHANGED, WITHOUT
NOTICE, IN FUTURE EDITIONS. FURTHER,
TO THE MAXIMUM EXTENT PERMITTED BY
APPLICABLE LAW, KEYSIGHT DISCLAIMS
ALL WARRANTIES, EITHER EXPRESS OR
IMPLIED WITH REGARD TO THIS MANUAL
AND ANY INFORMATION CONTAINED
HEREIN, INCLUDING BUT NOT LIMITED TO
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. KEYSIGHT SHALL NOT
BE LIABLE FOR ERRORS OR FOR INCIDENTAL OR CONSEQUENTIAL DAMAGES IN
CONNECTION WITH THE FURNISHING,
USE, OR PERFORMANCE OF THIS DOCUMENT OR ANY INFORMATION CONTAINED
HEREIN. SHOULD KEYSIGHT AND THE
USER HAVE A SEPARATE WRITTEN AGREEMENT WITH WARRANTY TERMS COVERING THE MATERIAL IN THIS DOCUMENT
THAT CONFLICT WITH THESE TERMS, THE
WARRANTY TERMS IN THE SEPARATE
AGREEMENT WILL CONTROL.
Safety Notices
A CAUTION notice denotes a hazard.
It calls attention to an operating procedure, practice, or the like that, if
not correctly performed or adhered
to, could result in damage to the
product or loss of important data. Do
not proceed beyond a CAUTION
notice until the indicated conditions
are fully understood and met.
A WARNING notice denotes a hazard.
It calls attention to an operating procedure, practice, or the like that, if
not correctly performed or adhered
to, could result in personal injury or
death. Do not proceed beyond a
WARNING notice until the indicated
conditions are fully understood and
met.
2Keysight M8070A Programming Guide
Safety Summary
GeneralThis product is a Safety Class 1 instrument (provided with a protective earth terminal).
The following general safety precautions must be observed during all phases of operation
of this instrument. Failure to comply with these precautions or with specific warnings or
operating instructions in the product manuals violates safety standards of design,
manufacture and intended use of the instrument. Keysight Technologies assumes no
liability for the customer's failure to comply with these requirements. Product manuals
are provided with your instrument on CD-ROM and/or in printed form. Printed manuals
are an option for many products. Manuals may also be available on the Web. Go to
www.keysight.com and type in your product number in the Search field at the top of the
page.
The protective features of this product may be impaired if it is used in a manner not
specified in the operation instructions.
All Light Emitting Diodes (LEDs) used in this product are Class 1 LEDs as per IEC
60825-1.
Environment Conditions
Before Applying Power
Ground the Instrument
Do Not Operate in an
Explosive Atmosphere
Do Not Remove the
Instrument Cover
This instrument is intended for indoor use in an installation category II, pollution degree 2
environment. It is designed to operate at a maximum relative humidity of 95% and at
altitudes of up to 2000 meters.
Refer to the specifications tables for the ac mains voltage requirements and ambient
operating temperature range.
Verify that all safety precautions are taken. The power cable inlet of the instrument serves
as a device to disconnect from the mains in case of hazard. The instrument must be
positioned so that the operator can easily access the power cable inlet. When the
instrument is rack mounted the rack must be provided with an easily accessible mains
switch.
To minimize shock hazard, the instrument chassis and cover must be connected to an
electrical protective earth ground. The instrument must be connected to the ac power
mains through a grounded power cable, with the ground wire firmly connected to an
electrical ground (safety ground) at the power outlet. Any interruption of the protective
(grounding) conductor or disconnection of the protective earth terminal will cause a
potential shock hazard that could result in personal injury.
Do not operate the instrument in the presence of flammable gases or fumes.
Operating personnel must not remove instrument covers. Component replacement and
internal adjustments must be made only by qualified personnel.
Instruments that appear damaged or defective should be made inoperative and secured
against unintended operation until they can be repaired by qualified service personnel.
Keysight M8070A Programming Guide3
Safety Symbols
Table 1 Safety Symbol
SymbolDescription
Indicates warning or caution. If you see this symbol on a
product, you must refer to the manuals for specific
Warning or Caution information to avoid personal injury
or damage to the product.
Frame or chassis ground terminal. Typically connects to
the equipment’s metal frame.
KC is the Korean certification mark to demonstrate that
the equipment is Class A suitable for professional use
and is for use in electromagnetic environments outside
of the home.
Indicates that antistatic precautions should be taken.
Indicates the time period d uring which no hazardous or
toxic substance elements are expected to leak or
deteriorate during normal use. Forty years is the
expected useful life of the product.
The RCM Mark is a compliance mark to the ACMA
(Australian Spectrum Management Agency). This
indicates compliance with all Australian EMC
regulatory information.
4Keysight M8070A Programming Guide
Compliance and Environmental Information
Table 2 Compliance and Environmental Information
Safety SymbolDescription
This product complies with WEEE Directive (2002/96/EC) marking requirements.
The affixed label ind icates that you must not discard this electrical/electronic
product in domestic household waste.
Product Category: With reference to the equipment types in WEEE Directive Annex I,
this product is classed as a “Monitoring and Control instrumentation” product.
Do not dispose in domestic household waste.
To return unwanted products, contact your local Keysight office, or see
In order to describe remote programming for the M8020A, M8030A and
M8040A, the modular configuration must be discussed.
The M8020A, M8030A and M8040A are modular instruments. They can
consist of several numbers of components. A component can be an AXIe
chassis, modules, channels, etc. All these components ‘form’ an
instrument. These instruments can be controlled by M8070A system
software.
The M8020A instrument supports the following modules.
• 1-channel, 32 Gb/s (Pattern Generator only or full BERT) -(1) M8041A
+ (1) M8062A
14Keysight M8070A Programming Guide
1 or 2-channel System Configuration
NOTE
The 1 or 2-channel configuration is a single channel system (a second
channel can be added with license) consisting of the 5-slot M9505A AXIe
Chassis and an M8041A module. The M8041A occupies three slots. A
maximum of two M8020A modules can be installed in a 5-slot chassis.
Programming Basics1
Figure 1M8020A configuration for 16 Gb/s BERT with 1 to 2 channel
3 or 4-channel System Configuration
The four channel configuration consists of the 5-slot M9505A AXIe
Chassis, an M8041A module, and an M8051A module. The M8041A
occupies three slots and the M8051A occupies two slots.
This configuration requires a cable (provided with the M8051A) that
connects the M8041A SYNC OUT to the M8051A SYNC IN to synchronize
the two modules to a common system clock.
Keysight M8070A Programming Guide15
1Programming Basics
Figure 2M8020A configuration for 16 Gb/s BERT for up to 4 channels
1-channel, 32 Gb/s (Pattern Generator Only)
A typical configuration using the M8061A 32 Gb/s multiplexer with
de-emphasis consists of the 5-slot M9505A AXIe Chassis, an M8041A
module, and an M8061A module. The M8041A occupies three slots and
the M8061A occupies two slots.
Figure 3M8020A configuration for 32 Gb/s BERT (external de-multiplexer is
16Keysight M8070A Programming Guide
recommended)
1-channel, 32 Gb/s (Pattern Generator only or full BERT)
A typical configuration for an M8020A 32 Gb/s full BERT consists of the
5-slot M9505A AXIe Chassis, an M8041A module, and an M8062A module.
The M8041A occupies three slots and the M8062A occupies two slots.
Figure 4M8020A configuration for 32 Gb/s BERT
Programming Basics1
M8030A Modular Configuration
The M8030A is a modular test solution which can be tailored to specific
needs from two channels with one M8041A to up to 10 channels.
The modules must be installed in the M9514A AXIe 14-slot chassis as
shown in
Table 3 M8030A modules’ arrangement in the M9514A AXIe chassis
Slot NumberModule
# 1For M8030A-BU1, M9537A AXIe embedded controller. For M8030A-BU2, this
# 2-4M8041A module
# 5-6M8051A module
# 7M9521A AXIe system module, always included in M8030A-BU1 or
Figure 5 on page -18 shows an example of modules arrangement in the
M9514A AXIe 14-slot chassis.
Figure 5Example of M8030A module arrangement
18Keysight M8070A Programming Guide
M8040A Modular Configuration
M8045A Module
(2 Channels)
NOTE
The M8040A is a modular test solution which simplifies accurate receiver
characterization of devices operating up to 32 and 64 GBaud with NRZ and
PAM-4. It supports the following modules.
• M8045A pattern generator
• M8046A analyzer
• M8057A remote head
The following section describes and illustrates various setup combinations
in which you can install the M8040A modules.
M8045A Pattern Generator Module
The M8045A module can be a one or two data channel system (a second
channel can be added with license). A one channel instrument has to be
returned to the factory for installing the second channel (hardware) and
license. It occupies three slots of the 5-slot M9505A AXIe chassis. The
following figure illustrates an M8045A module two data channel system)
installed in an M9595A AXIe chassis.
Programming Basics1
Keysight M8070A Programming Guide19
Figure 6M8045A configuration for 2 channels
The M8045A module must be installed in slots 1 through 3 of the
M9505A AXIe chassis for proper local bus communication unless the
M9537A AXIe Embedded Controller is installed (must be in slot 1).
1Programming Basics
M8046A
Module
M8057A Remote Head
M8046A Analyzer Module
The M8046A module occupies single slot of the 5-slot M9505A AXIe
chassis. The following figure illustrates an M8045A module with M8046A
module installed in an M9505A AXIe chassis.
Figure 7M8045A and M8046A configuration
M8057A Remote Head
The M8057A remote head is an external box which can be connected to
each channel of M8045A module, using the matched pair of cables. It
helps in minimizing signal degradations caused by lossy channels. The
following figure illustrates an M8057A remote head connected with one
channel of M8045A module.
Figure 8M8045A, M8046A and M8057A configuration
20Keysight M8070A Programming Guide
Using Identifiers
Location Identifiers
Programming Basics1
There are three different types of Identifiers:
• Location
• Group Name
• Measurement Name
When an instrument has several output channels with identical
capabilities or a subset of capabilities and has more than one module, the
selection of which module/channel to use is done using its location
identifier.
The location identifier is a predefined notation that can be used to address
certain properties, like high level, low level etc., of channels. The location
identifier is surrounded by single quotes (‘identifier’) or double quotes
(“identifier”). A location identifier will be appended to a SCPI command
followed by its argument(s). The location identifier addresses the
corresponding components. The location identifier consists of two parts:
the first part specifies the module, the second part addresses, in most
cases, a visible ‘component’ of a module, like an input or output connector.
For example, SCPI command :OUTP ‘M1.DataOut1’, OFF turns channel 1
(DataOut1) of module 1 (M1) output off.
If a SCPI command is to be sent to a specific module only and not a
specific channel, simply use “M1” or “M2” as the location identifier.
If you want to set a value that acts on all components of a modular
instrument (for example, set all jitter sources to off), omit the location
identifier.
Multiple Source Per Channel Identifier
Some features have multiple sources per channel. To identify these
sources, the “(*)” suffix is used.
For example, there are two periodic jitter sources per channel in a module.
The following SCPI command specifies periodic jitter source 2 as the
source for module 1/data out channel 1:
Group name identifiers are used to affect a group of inputs or outputs
using a single SCPI command. That is, all properties belonging to these
identifiers can be addressed simultaneously using the group name.
The following SCPI command shows the syntax for creating a group name
then adding the desired location identifiers.
The following is an example showing ‘Outputs’ as the group name followed
by ‘M1.DataOut1’ and ‘M1.DataOut2’ location identifiers assigned to the
‘Outputs’ group name identifier.
Measurement name identifiers are used to set up parameters associated
with a specific measurement name. For example, the following shows the
bit error ratio plugin SCPI command used to define a measurement name
called ‘MyMeasurement’:
:PLUGin:ERATio:NEW ‘MyMeasurement’
You can now set up parameters within the :PLUGin:ERATio subsystem to
be associated with the ‘MyMeasurement’ identifier.
The following shows the accumulation duration mode (set to fixed time)
and duration (set to 120 seconds) parameters associated with the
‘MyMeasurement’ identifier.
The M8020A/M8030A/M8040A platform supports a plugin interface. C#
assemblies which implement certain interfaces are recognized by the
software and integrated into the M8070A GUI and instrument software.
Error ratio, Output Timing and Jitter Tolerance measurements are
examples of the plugin concept. These C# assemblies are placed in a
predefined location and are integrated into the M8070A software at start
up time automatically.
These measurements can be controlled by the GUI and by SCPI
commands. This means that the SCPI tree has to be defined by the plugin
itself and is integrated into the existing SCPI tree of the
M8020A/M8030A/M8040A platform. SCPI commands for a plugin are
placed below a predefined node named “:PLUGin” followed by the type of
the plug in.
There is a set of “general” SCPI commands for creating, deleting and
controlling a plugin. Also, there is a flexible set of SCPI commands
provided by the plugin itself for setting and reading measurement
parameters.
Additionally, a user can create multiple measurements of the same type. A
measurement name identifier is used to address a created measurement.
Keysight M8070A Programming Guide23
Keysight M8070A System Software for M8000 Series of
BER Test Solutions
Programming Guide
2Recommended
Programming
Techniques
Output Protection / 26
Controlling the Output Levels / 27
Allowing the M8020A/M8030A/M8040A to Settle / 28
Reading the M8020A/M8030A/M8040A’s Status / 29
Working with Patterns / 36
Creating Pattern Sequences / 43
2Recommended Programming Techniques
NOTE
NOTE
Output Protection
Pattern Generator Output Termination
Output Protection Algorithm
The pattern generator's output ports must be terminated with 50 Ω if they
are not connected. Termination of output ports improves the test
performance.
Refer also to the M8020A/M8030A/M8040A Getting Started Guide for
information on terminating the M8061A outputs to ensure proper
performance.
The instrument has an internal protection algorithm that protects the
instrument from improper termination of the pattern generator's output
ports.
The algorithm checks whether the termination voltage and termination
resistance are correct before the output is enabled. This check happens
once only.
In non-balanced dc coupled mode, the termination voltage must be within
± 0.1 V of the specified value. The resistance must be between 40 and
60 Ω.
In balanced mode, the resistance must be between 80 and 120 Ω
(differential termination).
In ac coupled mode, which is intended for balanced only (for example,
8b/10b coded patterns), the output is enabled if no termination voltage
and no termination resistance are detected. This is the case if ac
capacitors are in front of the outputs. The check distinguishes between a
terminated or an open output.
Do not operate the output driver into an open.
26Keysight M8070A Programming Guide
Controlling the Output Levels
Controlling the Output Levels - Concepts
Controlling the Output Levels - Procedures
Changing the Voltages with SCPI
Recommended Programming Techniques2
When the output levels are changed at the M8020A/M8030A/M8040A
data and clock output ports, four parameters are changed:
•V
high
•V
low
•V
amptl
•V
offs
The M8020A/M8030A groups these parameters into "pairs" (V
V
high/Vlow
). If one of these values is modified, its "partner" remains
ampl/Voffs
constant and the values in the other pair are modified accordingly. For
example, if V
is changed, V
ampl
stays constant and V
offs
high
and V
low
are
modified accordingly.
,
The following commands show how you would set the data output so that
it has an amplitude of 1 V and an offset of 0.5 V:
Allowing the M8020A/M8030A/M8040A to Settle - Concepts
When patterns are sent to the pattern generator or error detector, the
M8020A/M8030A/M8040A requires some time to settle. The following
topics explain how the instruments react to pattern changes.
How Pattern Changes Affect the Pattern Generator
The M8020A/M8030A/M8040A requires some time to change the patterns
at the pattern generator and error detector. This is particularly true for
large text-based (ASCII) patterns that have to be loaded from the file
system.
In such a case, it is a recommended technique to always query the
M8020A/M8030A/M8040A's Operation Complete status after changing
the pattern.
How Pattern Changes Affect the Error Detector
When the pattern changes, the error detector has to resynchronize to the
new incoming signal. Depending on the signal, the alignment method used
and the desired BER threshold, this procedure can take up to half a minute
or more.
Checking Operation Status and Sync using SCPI Commands
The :STATus:OPERation:RUN? SCPI command returns the status of all
pattern generators, error detectors and clock generator. Query the desired
hardware component using the identifier (for example, ‘M1.DataOut1’).
The :STATus:INSTrument:SLOSs? SCPI command is a query that indicates
the status of the error detector synchronization. This query returns either
true (1) if all error detectors are synchronized, or false (0) if the error
detectors are not synchronized.
28Keysight M8070A Programming Guide
Reading the M8020A/M8030A/M8040A’s Status
Reading the M8020A/M8030A/M8040A’s Status - Concepts
The M8020A/M8030A/M8040A has a set of status registers that you can
use to monitor the status of the hardware, software and any running tests.
Overview of Registers
Specifically, it has the following registers:
• Status Byte
The Status Byte is a single register that stores the events occurring in
the other registers.
• Standard Event Status Register
The Standard Event Status Register monitors some non-critical errors
and basic operations.
• Questionable Data Status Register
The bits in the Questionable Data Status Register are set when certain
events occur in the M8020A/M8030A/M8040A that can lead to
questionable results.
• Operation Status Register
The Operation Status Register indicates when certain operations have
been completed.
Recommended Programming Techniques2
How the M8020A/M8030A/M8040A Uses Status Registers
You can determine the state of certain instrument hardware and firmware
events and conditions by programming the status register system.
The following subsections provide you with details about the
M8020A/M8030A/M8040A's status system.
Overview of the M8020A/M8030A/M8040A’s Status System
The M8020A/M8030A/M8040A has status reporting features that give
important information about events and conditions within the instrument.
For example, a flag may be set to indicate the end of a measurement or
perhaps a command error. To access this information, it is necessary to
query a set of registers using SCPI.
Keysight M8070A Programming Guide29
2Recommended Programming Techniques
M8020A/M8030A/M8040A Status System Structure
Status Register Group Model
The M8020A/M8030A/M8040A's status system is comprised of multiple
registers that are arranged in a hierarchical order. The lower-level status
registers propagate their data to the higher-level registers in the data
structures by means of summary bits. The Status Byte register is at the top
of the hierarchy and contains general status information for the
M8020A/M8030A/M8040A's events and conditions. All other individual
registers are used to determine the specific events or conditions.
Figure 9 on page -30 illustrates the typical structure of a status register.
The M8020A/M8030A/M8040A instrument status register model follows
the structure described in IEEE 488.2, section 11.4.2.
Figure 9Status register structure
A condition is a device state which is either TRUE or FALSE. A condition
register reflects these states in its condition bits.
A Condition Register is embedded in a register structure consisting of
Transition Filters, an Event Register and an Event Enable Register.
30Keysight M8070A Programming Guide
Recommended Programming Techniques2
This register is read by the CONDition? SCPI commands.
Transition Filters: A positive transition filter allows an event to be reported
when a condition changes from false to true. A negative transition filter
allows an event to be reported when a condition changes from true to
false. Setting both positive and negative filters true allows an event to be
reported anytime the condition changes. Clearing both filters disables
event reporting.
This register is set and read by the NTRansition[?] and PTRansition[?] SCPI
commands.
Event Register: An event register latches transition events from the
condition register as specified by the positive and negative transition
filters. Bits in the event register are latched and once set, they remain set
until cleared by either querying the register contents or sending the *CLS
command.
This register is read by the EVENt? SCPI commands.
Event Enable Register: An enable register specifies the bits in the event
register that can generate a summary bit. Summary bits are, in turn, used
by the next higher register.
This register is set and read by the ENABle[?] SCPI commands.
The registers work together as follows:
1The Condition Register corresponds to a condition on the hardware or
in the software. If the monitored condition is present, the
corresponding bit is high.
2The Transition Registers monitor changes in the Condition Register. If
the Positive Transition Register is configured to watch for a condition,
when this condition occurs and the bit in the Condition Register goes
high, the Positive Transition Register passes this event to the Event Register.
3 If this bit is enabled in the Event Enable Register, a summary bit is
generated in the next higher register. For the higher register, this is the
Condition Register and the event is handled the same way as
described here.
Keysight M8070A Programming Guide31
2Recommended Programming Techniques
M8020A/M8030A/M8040A Status Reporting Structure
Figure 10 on page -32 shows the M8020A/M8030A/M8040A’s status
reporting structure.
Figure 10Status reporting structure
32Keysight M8070A Programming Guide
Status Byte
Recommended Programming Techniques2
The Status Byte is the summary register to which the other registers
report. Each reporting register is assigned a bit in the Status Byte Register.
The bits in the Status Byte byte have the following meaning:
Table 4 Status byte descriptions
BitMnemonicDescription
0Not used
1Not used
2EAVError available: the error queue contains at
least one message.
3QUESA bit has been set in the Questionable Data
Status register (indicates that a signal is of
questionable quality).
4MAVMessage available: There is at least one
message in the message queue.
5ESBA bit in the Standard Event Register has
been set.
6RQSReQuest Service.
7OPERA bit in the Operation Status Register has
been set.
Keysight M8070A Programming Guide33
2Recommended Programming Techniques
Standard Event Status Register
The Standard Event Status register provides general-purpose information
about the instrument. It sets bit 5 in the Status Byte.
Table 5 Standard event status register descriptions
BitMnemonicDescription
0Operation CompleteOperation Complete bit. It is set in response
1Request ControlRequest Control bit.
2Query ErrorQuery error bit. It indicates that there is a
3Device Dependent ErrorDevice-dependent error bit. It is set when an
4Execution ErrorExecution error bit. It is set when a
5Command ErrorCommand error bit. It is set whenever the
6User RequestUser Request bit.
7Power OnPower-on bit. It is set each time the
to the *OPC command, but only if the
instrument has completed all its pend ing
operations.
problem with the output data queue. There
has been an attempt to read the queue when
it is empty, the output data has been lost, or
the query command has been interrupted.
instrument-specific error has occurred.
command (GPIB instrument specific) cannot
be executed due to an out of range
parameter or some instrument condition
that prevents execution.
instrument detects an error in the format or
content of the program message (usually a
bad header, missing argument, or wrong
data type etc.).
instrument is powered from off to on.
34Keysight M8070A Programming Guide
Questionable Status Register
The Questionable Status Register indicates that a currently running
process is of questionable quality. The output of this register sets bit 3 of
the Status Byte.
Table 6 Questionable status register descriptions
BitMnemonicDescription
0 - 8Not used
Recommended Programming Techniques2
9INSTrumentThis bit indicates the status of certain
10Not used
11PROTectionThis bit indica tes whether one or more of the
12SYMBolThis bit indicates whether the error
13 - 15Not used
Operation Status Register
The output of this register gives information about the current operation
the instrument is performing. It sets bit 7 of the Status Byte.
Table 7 Operation status register descriptions
BitMnemonicDescription
0 - 7Not used
8RUN
9 - 15Not used
hardware components.
instrument outputs detect an overload
condition.
detector(s) has experienced a symbol
alignment loss.
Keysight M8070A Programming Guide35
2Recommended Programming Techniques
Working with Patterns
Patterns can be accessed with a program and are stored in three different
areas:
1 Local to current setting (“current:”)
2 Shared between settings (“shared:”)
3 Factory supplied standard patterns (“factory:”). These patterns are read
only and cannot be modified.
Below these root nodes is a folder structure using ‘/’ as a separation
character. So a complete pattern name might be something like
“factory:SATA/LTDP-short”.
Patterns consist of a sequence of symbols. A symbol has a coding:
1 Binary (“Bit”)
2 8b10b (“B8B10”)
3 128/130 (“B128B130”)
4 128/132 (“B128B132”)
A symbol can have additional attributes to modify behavior. All symbols
support:
1 Mask: this attribute affects DataIn locations only. It specifies if the
symbol is actually compared or masked (excluded from compare).
2 Squelch: this attribute affects DataOut locations only. If this attribute is
1, a squelch (out of band) level is used.
In addition, there are coding specific attributes, to control aspects of the
coding such as bypassing or using a scrambler. Refer to
:DATA:PATTern:I DATa[?] on page 474 for more information.
The :DATA:PATTern:USE SCPI command is used to specify the patterns
and attributes. Refer to :DATA:PATTern:USE[?] on page 473 for details on
how to specify a pattern and set up its parameters. The parameters include
the pattern name, number of symbols, symbol coding (optional), mask
(optional) and squelch (optional).
36Keysight M8070A Programming Guide
Symbol Coding Descriptions
Bit Coding
To encode a bit coded (binary) symbol 1, 2, or 3 bits are needed. This
depends on the use of mask and squelch.
Table 8 Plain bit coding without using mask or squelch
Bit Offset/RangeBit (range) NameDescription
0DataData bit
Table 9 Mask is used
Bit Offset/RangeBit (range) NameDescription
0DataData bit
1MaskMask (ignored on DataOut)
Recommended Programming Techniques2
Table 10 Squelch is used
Bit Offset/RangeBit (range) NameDescription
0DataData bit
1SquelchSquelch (ignored on DataIn)
Table 11 Mask and squelch are used
Bit Offset/RangeBit (range) NameDescription
0DataData bit
1MaskMask (ignored on DataOut)
2SquelchSquelch (ignored on DataIn)
Keysight M8070A Programming Guide37
2Recommended Programming Techniques
Table 12 Error is used
Bit Offset/RangeBit (range) NameDescription
0DataData bit
1ErrorError (ignored on DataOut, ignored on
DataIn)
38Keysight M8070A Programming Guide
8b10b Coding
To encode an 8b10b symbol 16 bits (2 bytes) are used.
Table 13 8b10b coding
Recommended Programming Techniques2
Bit Offset/RangeBit (range) NameDescription
7:0DataSymbol data
8K/D0 = D-character, 1 = K-character
9Reserved for future use. Must be set
to 0
10MaskMask (if present, ignored on DataOut)
11SquelchSquelch (if present, ignored on
DataIn)
12Enable scramblerEnable scrambler (ignored on DataIn)
13Pause scramblerPause scrambler (ignored on DataIn)
14Reset scramblerReset scrambler (ignored on DataIn)
15Start of FrameStart of Frame (ignored on DataOut)
Table 14 Variant for captured pattern
Bit Offset/RangeBit (range) NameDescription
7:0DataSymbol data
8K/D0 = D-character, 1 = K-character
9Reserved for future use. Must be set
to 0
10ErrorError (ignored on DataOut, ignored on
DataIn)
15:11SquelchReserved for future use. Must be set
to 0
Keysight M8070A Programming Guide39
2Recommended Programming Techniques
128/130 Coding
To encode 128/130 symbol 144 bits (18 bytes) are used.
Table 15 128/130 coding
Bit Offset/RangeBit (range) NameDescription
1:0FramingFraming bits
129:2DataData
130MaskMask (if present, ignored on DataOut)
131SquelchSquelch (if present, ignored on
132Reset ScramblerReset scrambler (ignored on DataIn)
133Pause scramblerPause scrambler (ignored on DataIn)
134Bypass scramblerScrambler bypass
135Bypass byte 0 scramblerScrambler bypass byte 0
136Do DC balancingDo DC balancing (ignored on DataIn)
137Reset DC balancingReset DC balancing (ignored on
138Send scrambler stateSend scrambler state
139 Reset Parity Reset Parity (ignored on DataIn)
140 Pause Parity Pause Parity (ignored on DataIn)
141Start of FrameStart of Frame (ignored on DataOut)
143:142 Reserved for future use. Must be set
DataIn)
DataIn)
to 0
40Keysight M8070A Programming Guide
128/132 Coding
To encode a 128/132 symbol 144 bits (18 bytes) are used.
Table 16 128/132 coding
Bit Offset/RangeBit (range) NameCod ing-128/132 content
3:0FramingFraming bits
131:4DataData
132MaskMask (if present, ignored on DataOut)
Recommended Programming Techniques2
133SquelchSquelch (if present, ignored on
DataIn)
134Reset ScramblerScrambler reset (ignored on DataIn)
135Pause ScramblerScrambler pause (ignored on DataIn)
136Bypass ScramblerScrambler bypass
137Bypass Byte 0 ScramblerScrambler bypass byte 0
138Do DC BalancingDo DC balancing (ignored on DataIn)
139Reset DC BalancingRest DC balancing (ignored on DataIn)
140Send Scrambler StateSend scrambler state (ignored on
DataIn)
141Reset ParityReset parity (ignored on DataIn)
142Pause ParityPause parity (ignored on DataIn)
143Start of FrameStart of frame (ignored on DataOut)
Keysight M8070A Programming Guide41
2Recommended Programming Techniques
Symbol Sequences
When combining symbols to a sequence of symbols they are filled in one
after the other without any gaps. For the non-bit codings that use multiple
bytes, the symbols naturally start again on a byte boundary. For the bit
codings (binary) they start at the next available bit. Bits are used in a
fashion that allows reading from “left to right”. This means the symbol bit 0
is encoded as bit 7 in a byte.
Figure 11Example 1: plain bit coding
Figure 12Example 2: mask and squelch bit coding
42Keysight M8070A Programming Guide
Creating Pattern Sequences
Sequence Editor
Recommended Programming Techniques2
Figure 13Example 3: 8b10b coding
A pattern sequence is configured using a language. The pattern sequence
language is based on XML.
Pattern sequences are created and edited using the Sequence Editor in
the M8070A software interface as shown in Figure 14 on page -43.
Figure 14Sequence Editor in M8070A software interface
Keysight M8070A Programming Guide43
2Recommended Programming Techniques
A default “Generator” and “Analyzer” sequence are configured in the
Sequence Editor as shown in Figure 14 on page -43. You can edit these
sequences or create new ones.
As a pattern sequence is being configured, the corresponding XML
elements are generated and can be viewed in the XML editor by clicking
on the <Xml> button shown in Figure 15 on page -44.
Figure 15<Xml> button
Figure 16 on page -44 shows the XML elements for the default Generator
and Analyzer. Clicking the UI button will return to the graphical interface.
Figure 16XML view
In UI view, click in a pattern sequence block to display its sequence
settings as shown in Figure 17 on page -45.
To specify a version number for the sequence syntax, insert the following:
<version>1.0.0</version>
Keysight M8070A Programming Guide45
2Recommended Programming Techniques
Symbol Width
Pattern Generation Granularity
To specify the symbol encoding this sequence works with, insert the
following:
<symbolWidth>1</symbolWidth>
Available symbol widths are:
1: this is for bit coded symbols
10: this is for 8b/10b coded and bit coded symbols
130: for 128/130 coded and bit coded symbols
132: for 128/132 coded and bit coded symbols
Pattern generation has granularity. A single bit cannot be generated.
Instead, multiple bits are generated at once. Compared to other BERTs like
the J-BERT N4903B, different granularities are supported to allow for less
restrictions in the pattern generation. Also, granularity is hidden as much
as possible by unrolling patterns internally.
Table 17 Pattern generation granularity
Symbol WidthGranularity
164
1080
130130
132132
The actual pattern sequence attributes are specified within:
<sequence replicate=”Serialize”></sequence>
Replicate allows global selection of how to distribute PRBS or memory
patterns to multiple locations.
• Serialize: first bit/symbol is assigned to first location, next bit/symbol to
next location and so on. This means a pattern needs to have a minimum
block length * locations bits. In the case of a PRBS, a PRWS is issued,
setting the phases of the PRBS generators in a way that they will form a
PRBS after a MUX.
• Copy: each location gets a copy of the PRBS /pattern.
46Keysight M8070A Programming Guide
Blocks and Loops
The basic building blocks of a sequence are blocks and loops.
A block is the basic unit of a sequence. Here patterns are assigned to
locations or branches and are specified to other blocks. A block transitions
to the next as a default action. But it also might be enclosed in a loop.
Nested loops are also possible. There are three counted loop levels plus an
infinite loop level:
• Loop level 1 can be used to repeat a block.
• Loop level 2 and 3 can span multiple blocks, but it must be ensured
that either the start or end of a loop is on a fresh block.
• Loop level 4 is for infinite loops.
The following illustrates valid loop nesting with the full 4 loop levels:
Recommended Programming Techniques2
Figure 18Loop nesting
Count attribute specifies the number of loop iterations. The valid value
range is 1 to 232. If omitted, infinite is assumed. The enabled attribute
allows the complete loop, including all loop content, to be temporarily
disabled. If omitted, the default is enabled.
<loop count="1"enabled="1"></loop>
Keysight M8070A Programming Guide47
2Recommended Programming Techniques
Length Attribute
Synchronization and Loop Block
Pattern Selection
The length attribute specifies the “length” of the block in number of bits.
The enabled attribute allows the block to be temporarily disabled
(ignored). If omitted, the default is enabled.
<block length="1"enabled="1"></block>
A special combination of sync and loop is available for achieving
synchronization:
Other attributes for block or syncAndLoopBlock:
1 name: for naming a block.
2 cdr: for freezing CDR when CDR control is “sequence”.
3 errorInsertion: for suppressing error insertion.
4 disparity: for setting the disparity in 8b10b coding.
5 startWordAlign: for initiating a word alignment in 8b10b and 128/130
coding. In the syncAndLoopBlock this flag is used for the initial block
only, not for the looped block.
Within a block or syncAndLoopBlock, select the type of patterns to use.
The choices are clock, pulse, Prbs, static and memory pattern. The XML
elements for pattern selection are as follows:
Trigger output pulses can be generated and controlled from sequence
blocks. These pulses are sent to the front panel TRIG OUT connectors.
This requires that the trigger mode be set to sequencer controlled. The
following describes how to change the trigger mode.
1 In the M8070A software interface, select System > Module View.
2Click on Trig Out.
3 Under Configuration parameters, change Operating Mode to
Sequencer Controlled.
Refer to :OUTPut:TRIGger:MODE[?] on page 226 for information about
setting the trigger mode using this SCPI command.
Two variants are available:
1 A trigger pulse can be generated relative to a sequence block.
2 A trigger pulse can be generated whenever a specific bit sequence is
generated by a PRBS generator.
This is controlled via nodes within a block node.
If multiple sequences are used, only one sequence can actually have
control of the trigger.
Triggering Relative to a Sequence Block
The following is an example of a trigger pulse relative to a sequencer
block:
<trigger>
<pulse offset="0"width="32"/>
</trigger>
The offset can be omitted and defaults to 0. The width can also be omitted
and defaults to 32.
Keysight M8070A Programming Guide49
2Recommended Programming Techniques
Triggering Based on Specific Bit Sequence
Block Branching
The following is an example of a trigger pulse generated based on a
specific PRBS bit sequence:
All attributes can be omitted. The width defaults to 32. The match pattern
defaults to all 0’s or all 1’s depending on the invert attribute. The
polynomial defaults to the polynomial used by the generators or analyzers.
Invert also defaults to the PRBS invert setting of the generators or
analyzers.
Within a block a conditional branch to another block can be done. The
most simple form is as follows:
<if source="Break"</if>
This example simply jumps to the next block when a break command is
done. The following describes how to set up a break command.
1 In the M8070A software interface, select Patterns > Sequence Editor.
2Under the Block Branches settings, change Condition to Break.
Refer to :DATA:SEQuence:BREak on page 484 for information on setting
the break command using this SCPI command.
When a branch to a different block is desired, use the “goto” attribute:
1 In the M8070A software interface, select Patterns > Sequence Editor.
2Under the Block Branches settings, click in the Go To Block field and
enter the block name.
Other potential conditions are SysInA, SysInB, CtrlInA, or CtrlInB. Break,
SysInA and SysInB are global events and affect all locations of a sequence.
CtrlInA and CtrlInB are local to a module and are most suitable when all
locations of a sequence are using a single module.
50Keysight M8070A Programming Guide
Link Training Events
NOTE
Block Controls
Recommended Programming Techniques2
It is also possible to specify a reaction based on a static level or a
transition. Using the “event” attribute, you can select “low”, “high”,
“positiveEdge” and “negativeEdge”.
1 In the M8070A software interface, select Patterns > Sequence Editor.
2Under the Block Branches settings, change Transition to Positive,
Negative, Static High, or Static Low.
• Link Training Target State: indicates that the Link Training is in the
target state (that is loopback)
<if source="LinkTrainingTargetState"</if>
• Link Training Detect State: indicates that the Link Training is in the
detect state (that is the reset state)
<if source="LinkTrainingDetectState"</if>
• Link Training Error: indicates that an error occurred when trying to
bring up the link (that is Link Training reached the target state but not
the target speed)
<if source="LinkTrainingError"</if>
Within a block it can be specified to generate a signal on CTRL OUT A, SYS
OUT A, or SYS OUT B front panel connector. This can be useful for
triggering an external device such as an oscilloscope or to generate
auxiliary signals such as a laser enable signal. However, be aware that
there is no specified timing relationship to the DataOut.
In a two module configuration, the sinkLocation attribute is used to specify
on what module the CTRL OUT A signal is generated.
The shape of the signal is specified with the value attribute. It can be a
static 0, static 1, or a pulse.
SysOutA and SysOutB are internally controlled from the Trigger
Sequencer.
Therefore, these signals can only be used in the same sequence where
the trigger out is controlled.
Keysight M8070A Programming Guide51
2Recommended Programming Techniques
NOTE
Global Block Controls
CtrlOutA can only be used if it is not currently being used by the global
block controls.
Global block controls are used to set up global routing of signals. Signals
can be routed to the CTRL OUT A front panel connector only.
One common use could be for generating a pulse on CTRL OUT A
whenever an error on the M1.DataIn1 or M1.DataIn2 of the corresponding
module occurs:
<controls>
<control sink="CtrlOutA"source="Error"
sourceLocation="M1.DataIn1"/>
</controls>
With the additional “signalShape” attribute, it can be selected if a 0/1
pulse is generated whenever an error occurs.
52Keysight M8070A Programming Guide
Coding Configuration
Various aspects of coding can be configured. This is done with the
<codingConfigurations> node. It is inserted just before the <symbolWidth>
node. Within this node the 8b10b specific attributes are configured in a
<b8b10> node. The align symbol is configured with an optional attribute. If
not specified the default align symbol is K28.5. Also, you can specify a
substitution symbol in an attribute that is inserted into the received data
stream when an invalid code word is recognized. The default for this is
K28.0. So the complete node would look like the following:
<b8b10 align="K28.5"substitution="K28.0">
And can be shortened to the following:
<b8b10>
Up to four filler primitives can be specified. Each filler primitive can consist
of up to 4 symbols, where a symbol can be any valid 8b10b symbol or a ‘*’
that is used as a wildcard matching any symbol.
A filler symbol specification looks like the following:
<fillerPrimitive symbol1="K28.1"symbol2="K28.1"/>
USB 3.0
Recommended Programming Techniques2
After specifying a filler primative, various aspects of the (de)scrambler can
be configured with the <scrambler> node. With the polynomial attribute
the USB/PCIe or SATA polynomial can be selected. The reset value for the
scrambler and the reset value for the scrambler after a hold sequence can
be configured with the resetValue and resetValueAfterHold attribute. In
addition, it can be specified if the scrambler is reset after a filler primitive
was removed with the resetAfterFillerRemove attribute. All these nodes
are optional, with defaults suitable for USB testing. If just <scrambler>
node is given without attributes, it is equivalent to the following:
Within the scrambler node, sequences of up to 4 symbols can be
configured that control the scrambler when they are seen in the incoming
data stream. With resetPrimitive the scrambler is reset, with holdPrimitive
it is paused and with pauseStartPrimitive it is paused until a
pauseEndPrimitive is seen.
The following are examples for the different standards.
Link Training Configuration describes the parameters controlling the
LTSSM (Link Training and Status State Machine). In the first release it is
only defined and implemented for PCI Express 3.0. This is done with the
<linkTrainingConfigurations> node. It is inserted just before the
<codingConfigurations> node. The following parameters can be
configured as attributes.
Table 18 Link Training Configuration
NamePossible ValuesDefault ValueDescriptionUsed for DUT
DUT TypeAddInCard
Link
Equalization
SystemBoard
Bypass
PresetsOnly
Full
Lane Number0 - 150This is the lane number
Link Number0 - 2550This is the link number
Start PresetP0 - P9P4This is the preset used by
AddInCardSpecifies which role the DUT
should play during link
training. It can either be an
upstream device for testing
a downstream port or vice
versa.
BypassDetermines whether link
equalization should be
performed. It can either be
aborted after phase 1
(Bypass) or fully executed. In
the second case it can be
determined whether only
preset or all (that is,
individual cursor) requests
should be accepted.
being used.
being used.
the BERT’s TX port after
switching to Gen 3
operation and when
operating as an upstream
device.
Type
Both
Both
Both
Add-in Card
Add-in Card
56Keysight M8070A Programming Guide
Recommended Programming Techniques2
NamePossible ValuesDefault ValueDescriptionUsed for DUT
DUT Preset
Hint
DUT Initial
Preset
DUT Target
Preset
User
Calibrated
Presets
-6 dB
-7 dB
-8 dB
-9 dB
-10 dB
-11 dB
-12 dB
Reserved
P0 - P9P0This is the preset the BERT
P0 - P9P0This is the preset the BERT
True
False
ReservedThis is the preset hint being
sent by the BERT to the DUT
during phase 0 of the link
equalization procedure. This
is only used when the BERT
operates as an upstream
device.
transfers to the DUT in
phase 0 of the link
equalization procedure. This
is only used when the BERT
operates as an upstream
device.
requests the DUT to switch
to during link equalization.
Dependent on the role the
BERT is playing, this is done
in either phase 2 or 3 of the
link equal ization training.
FalseBERT's TX port should use
user-calibrated presets or
standard presets during link
training.
If not specified standard
presets are used.
Type
Add-in Card
Add-in Card
Both
Both
The following is an example of a Link Training Configuration for PCIe 3.0:
Once a sequence has been configured, it is downloaded to the hardware
using the download button in the Sequence Editor shown in Figure 19 on
page -58. When the sequence has been downloaded, this button turns
green.
Figure 19Download button
You can also download the pattern sequence configuration by copying and
pasting the XML elements as a sequence string using the
:DATA:SEQuence:VALue SCPI command. For an example, refer to
:DATA:SEQuence:VALue[?] on page 483.
58Keysight M8070A Programming Guide
Keysight M8070A System Software for M8000 Series of
BER Test Solutions
Programming Guide
3Programming
Examples
Introduction / 60
Initializing the Connection / 60
SJ Example / 62
PJ E xa mp l e / 68
Sampling Point Alignment Example / 74
BER Example / 78
M8070A Jitter Tolerance Measurement CSV Output / 83
3Programming Examples
Introduction
Initializing the Connection
N4903B Initialization
This chapter provides programming examples for setting up some of the
most common functions including:
• Initialization
•SJ
•PJ
• Sampling point alignment
•BER
If you have programmed the N4903B, examples are provided for
comparison to the M8020A. This will facilitate code conversion from the
N4903B to the M8020A.
The ResourceName ("TCPIP1::10.0.0.207::inst0::INSTR") must be replaced
by the instrument's address string from the VISA Assistant.
' First our declarations...
Private myN490X As AgilentN490x
Private myBERT As AgilentBert
Private myPG As AgilentBertLib.IAgilentBertPG
Private myPGClock As AgilentBertLib.IAgilentBertPGClock
Private myPGOut As AgilentBertLib.IAgilentBertPGOutput
Private myEDDataIn As AgilentBertLib.IAgilentBertEDDataIn
Private Sub Form_Load()
Set myN490X = New AgilentN490x
Set myBERT = myN490x.IAgilentBert
myBERT.Initialize ("TCPIP1::10.0.0.207::inst0::INSTR",
True, True,"QueryInstrStatus=true")
End Sub
Private Sub Form_Unload(Cancel As Integer)
myBERT.Close
End Sub
60Keysight M8070A Programming Guide
M8020A Initialization
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
public override List<string> startBERAcc()
// M8020A
{
List<string> errorStr = new List<string>();
errorStr = this.ErrorQ();
return errorStr;
}
public override List<string> stopBERAcc()
// M8020A - error counters can't be stopped yet
{
List<string> errorStr = new List<string>();
errorStr = this.ErrorQ();
return errorStr;
}
public override List<string> resetBERCounter()
{
List<string> errorStr = new List<string>();
List<double> bitResults = new List<double>();
List<double> bitCounter = new List<double>();
# size of results
print " " + str(len(results)) + " data items, " + str(int(len(results)/6)) + " rows;",
# if there are any rows (and not just a blank measurement), then
# use the name of the jtol measurement as the filename
# this will overwrite the file if it already exists!
# the file will be located in \Program Files (x86)\Agilent\M8070A\bin\, maybe
if (int(len(results)/6) == 0):
# nothing to write to file
print "no file created"
else:
with open(id.Trim('"').Replace(' ','_') + ".csv", 'w') as f:
# output header to file
f.write("Modulation Frequency (GHz),Sinusoidal Jitter (UI),Number of B
Ratio,Measurement results\n")
The following python script generates the results from all open jitter
tolerance measurements to different CSV files. This script can be easily
modified to generate the output of the highest-passing point at each jitter
modulation frequency value measured. This script can be run from the
M8070A Script Editor or can also be run externally.
Programming Examples3
Keysight M8070A Programming Guide83
3Programming Examples
# iterate over the data
# first element ([0]) is a module identifier, discard
# items are then grouped in bundles of six, per header above
# we need to insert a comma or LF after each item, depending on pos
for idx,data in enumerate(results):
if (idx==0):
# do nothing, this is the module identifier
pass
elif (idx%6==0):
# output ending in a newline
#print data
f.write(data + "\n")
else:
# output ending in a comma
#print data + ",",
f.write(data + ",")
# close file and move on!
f.close()
print "written to file"
84Keysight M8070A Programming Guide
Keysight M8070A System Software for M8000 Series of
BER Test Solutions
Programming Guide
4SCPI Command
Language
SCPI Command Language - Introduction / 86
Important Points about SCPI / 89
Sending Commands to the M8020A/M8030A/M8040A / 93
Command Line Arguments / 94
Communication / 95
4SCPI Command Language
SCPI Command Language - Introduction
The Serial BERT is compatible with the standard language for remote
control of instruments. Standard Commands for Programmable
Instruments (SCPI) is the universal programming language for instrument
control.
SCPI can be subdivided into the following command sets:
• SCPI Common Commands
• SCPI Instrument Control Commands
• IEEE 488.2 Mandatory Commands
SCPI Common Commands
This is a common command set. It is compatible with IEEE 488.2 and
contains general housekeeping commands. The common commands are
always preceded by an asterisk. A typical example is the reset command:
*RST
The IEEE 488.2 command set also contains query commands. Query
commands always end with a question mark.
SCPI Instrument Control Commands
The programming commands are compatible with the Standard
Commands for Programmable Instruments (SCPI) standard. For more
detailed information regarding the GPIB, the IEEE 488.2 standard, or the
SCPI standard, refer to the following books:
• SCPI Consortium. SCPI- Standard Commands for Programmable
Instruments, 1997 (http://www.scpiconsortium.org).
• International Institute of Electrical and Electronics Engineers. IEEE
Standard 488.1- 1987, IEEE Standard Digital Interface for
Programmable Instrumentation. New York, NY, 1987.
• International Institute of Electrical and Electronics Engineers. IEEE
Standard 488.2- 1987, IEEE Standard Codes, Formats, Protocols and
Common commands For Use with ANSI/IEEE Std 488.1- 1987. New
York, NY, 1987.
86Keysight M8070A Programming Guide
IEEE 488.2 Mandatory Commands
NOTE
In order to comply with the SCPI model as described in IEEE 488.2, the
Serial BERT implements certain mandatory commands. Other commands
are implemented optionally. For more detail on the IEEE 488.2 mandatory
and optional commands, see IEEE Commands - Reference on page 100.
Overlapped and Sequential Commands
IEEE 488.2 defines the distinction between overlapped and sequential
commands. A sequential command is one which finishes executing before
the next command starts executing. An overlapped command is one which
does not finish executing before the next command starts executing.
It is not reliable to use wait statements in the control program to
facilitate the use of overlapped commands.
Because these commands may allow the execution of more than one
command at a time, special programming techniques must be used to
ensure valid results. The common commands *OPC, *WAI and *OPC? can
be used for this purpose. They help synchronize a device controller with
the execution of overlapped commands.
The behaviors of these commands, in brief, are as follows:
•*OPC
The *OPC command sets the Operation Complete (OPC) bit of the Event
Register when the No Operation Pending flag is TRUE (No Operation
Pending flag is attached to each overlapped command). Until that time,
the controller may continue to parse and execute previous commands.
It is good technique, then, to periodically poll the OPC bit to determine
if the overlapped command has completed.
•*WAI
The *WAI command allows no further execution of commands or
queries until the No Operation Pending flag is true, or receipt of a
Device Clear (dcas) message, or a power on.
The *WAI command can be used for overlapped commands. It stops the
program execution until any pending overlapped commands have
finished. Specifically, it waits until the No Operation Pending flag is
TRUE, or receipt of a dcas message, or a power on.
SCPI Command Language4
Keysight M8070A Programming Guide87
4SCPI Command Language
NOTE
Data Types
•*OPC?
The *OPC? query returns the ASCII character "1" in the Output Queue
when the No Operation Pending flag is TRUE. At the same time, it also
sets the Message Available (MAV) bit in the Status Byte Register. The
*OPC? will not allow further execution of commands or queries until the
No Operation Pending flag is true, or receipt of a Device Clear (dcas)
message, or a power on.
The command behaviors described above are for overlapped commands.
When the same commands are used with sequential commands, the
behaviors may be different.
The M8020A/M8030A/M8040A has the capability of receiving and
returning data in the following formats:
STRING
A string of human-readable ASCII characters, either quoted or nonquoted.
88Keysight M8070A Programming Guide
NUMERIC
The M8020A/M8030A/M8040A handles the following numeric formats:
• <NR1>: Integer (0, 1, 2, - 1, etc.)
• <NR2>: Number with an embedded decimal point (0.1, 0.001. 3.3, etc.)
• <NR3>: Number with an embedded decimal point and exponent (1e33,
1.3e- 12, etc.)
• <NRf>: Represents <NR1>, <NR2> and <NR3>
• Binary preceded by #b (#B010101, #b011111, etc.)
• Octal preceded by #q (#Q777111, #q7331777, etc.)
• Hex preceded by #h (#haff, #h8989fffff, etc.)
BOOLEAN
Boolean values can be sent to the M8020A/M8030A/M8040A as either
ON | OFF or 0 | 1. The M8020A/M8030A/M8040A answers queries with 0 |
1.
Definite Length Arbitrary Block Data
Important Points about SCPI
Important Points about SCPI - Concepts
SCPI Command Language4
Block data is used when a large quantity of related data is being returned.
A definite length block is suitable for sending blocks of 8-bit binary
information when the length is known beforehand. An indefinite length
block is suitable for sending blocks of 8-bit binary information when the
length is not known beforehand or when computing the length beforehand
is undesirable.
It has the following format:
#<Length of length><Length of data><data>
<Length of length> is a single integer that contains the number of digits in
<Length of data>, which in turn contains the length of the data. For
example, a 512-byte pattern would be defined as:
#3512<data>
There are a number of key areas to consider when using SCPI for the first
time. These are as follows:
• Instrument Model
• Command Syntax
• Optional Parts of Commands
• Sending Commands
• Command Separators
• SCPI Command Structure
Instrument Model
SCPI guidelines require that the M8020A/M8030A/M8040A is compatible
with an instrument model. This ensures that when using SCPI, functional
compatibility is achieved between instruments that perform the same
tasks. For example, if two different instruments have a programmable
clock frequency setting, then both instruments would use the same SCPI
commands to set their frequency. The instrument model is made up of a
number of subsystems.
The sub-system defines a group of functions within a module and has a
unique identifier under SCPI, which is called the Root Keyword.
Keysight M8070A Programming Guide89
4SCPI Command Language
For more details on the instrument model, see STATus Subsystem on
page 110.
Command Syntax
Commands may be up to twelve characters long. A short-form version is
also available which has a preferred length of four characters or less. In
this document the long-form and short-form versions are shown as a
single word with the short-form being shown in upper-case letters.
For example, the long-form node command SOURce has the short-form
SOUR. Using the short form saves time when entering a program;
however, using the long form makes a program more descriptive and
easier to understand.
SCPI commands may be commands only, commands and queries, or
queries only. A question mark at the end of a command indicates that it is
a query. If the question mark appears in brackets ([?]), the command has a
command and query form.
Optional Command Keywords
Some layers in the SCPI command structure are optional. These optional
keywords are indicated by square brackets ([]). A typical use for these
types of keywords is with a command that is unique to one module. In this
case, the top layer (Root Keyword) of the command structure may be
omitted.
For example, the following command code segments are functionally
identical:
[:SOURce]:JITTer[:GLOBal][:STATe] <ON|OFF|1|0>
:JITTer <ON|OFF|1|0>
:JITT <ON|OFF|1|0>
:jitt <ON|OFF|1|0>
Note that it is not necessary to include the syntax inside the square
brackets ([]).
90Keysight M8070A Programming Guide
Query Responses
NOTE
It is possible to interrogate the individual settings and status of a device
using query commands. Retrieving data is a two-stage operation.
The query command is sent from the controller using the OUTPUT
statement and the data is read from the device using the ENTER
statement. A typical example is the SCPI IEEE 488.2 Common Command
*IDN? which queries the identity of a device.
When sending strings to the instrument, either the double quote (") or
the single quote may be used ('), the latter being more suited to PASCAL
programs, which make use of a single quote; the former being more
suited to use in BASIC programs, which use a double quote as a
delimiter.
Command Separators
The SCPI command structure is hierarchical and is governed by commas,
semicolons and colons:
• Commas are used to separate parameters in one command.
• Colons are used to separate levels.
• Semicolons are used to send more than one command to the
instrument at a time.
It is possible to send several commands in one pass, as long as the
commands all belong to the same node in the SCPI tree. The commands
have to be separated by semicolons.
The following SCPI commands provide examples of this.
Any optional commands are enclosed in square brackets [ ] and any
structure and identifies the source
subsystem.
subnode for setting a voltage level.
output amplitude level.
channel 1 and specifies an amplitude of
1.11.
optional characters are shown in lower case.
A colon indicates a change of level in the command hierarchy.
Commands at the same level in the hierarchy may be included in the
same command line, if separated by a semi-colon.
The bar symbol (|) indicates mutually exclusive commands.
To translate this syntax into a command line, follow the convention
described above. Remember, however, that the command line can be
created in several different ways. It can be created with or without optional
keywords and in a long or short form. The following example gives three
possible forms of the command line; all are acceptable.
In long form:
:SOURce:VOLTage:AMPLitude ‘M1.DataOut1’,1.11
In short form:
:SOUR:VOLT:AMPL ‘M1.DataOut1’,1.11
92Keysight M8070A Programming Guide
With the optional commands removed:
NOTE
:VOLT ‘M1.DataOut1’,1.11
The long form is the most descriptive form of programming commands in
SCPI.
Sending Commands to the M8020A/M8030A/M8040A
Sending Commands to the M8020A/M8030A/M8040A - Overview
A command is invalid and will be rejected if:
• It contains a syntax error.
• It cannot be identified.
• It has too few or too many parameters.
• A parameter is out of range.
• It is out of context.
Sending Commands using VISA
The following is a list of the available hardware interfaces for sending
commands to the M8020A/M8030A/M8040A firmware:
SCPI Access (HiSLIP): TCPIP0::localhost::hislip0::INSTR (High-Speed LAN
Instrument Protocol)
SCPI Command Language4
SCPI Access (VXI-11): TCPIP0::localhost::inst0::INSTR (VXI-11 is a TCP/IP
instrument protocol defined by the VXIbus Consortium)
If you use the VXI-11 (TCP/IP instrument protocol) in your test programs,
you must change the resource string to the HiSLIP protocol if the
software is running on Windows 8 or Windows 8.1. VXI-11 is not
supported at this time on Windows 8 or Windows 8.1.
SCPI Access (Telnet): telnet localhost 5024 (Communication with LAN
instrument through SCPI Telnet port)
Keysight M8070A Programming Guide93
4SCPI Command Language
Command Line Arguments
(See Communication on page 95 for details about /Socket, /Telnet, /Inst,
/AutoID, /NoAutoID, /FallBack).
Table 19 Command line arguments
ArgumentDescription
/AutoIdStart in auto ID mode (this is the default)
/NoAutoId Do not start in auto ID mode - use
/FallBackUse auto ID mode if the communication
/Socket <socket port> Set the socket port for the SCPI
/Telnet <telnet port> Set the telnet port for the SCPI
/Inst <instrument
number>
/rcl Recall last used setting [optional]
/rstReset to factory default [optional]
/IgnoreAwg M8070A software don't grab M8195A
[optional]
communication parameters from command
line [optional]
parameters from the command line don't
work [optional]
communication (only used with /NoAutoId)
[optional]
communication (only used with /NoAutoId)
[optional]
Set the instrument number for VXI-11.3 and
HiSLIP SCPI communication [optional]
modules [optional]
94Keysight M8070A Programming Guide
Communication
SCPI Command Language4
Depending on the command line arguments /Socket, /Telnet, /Inst,
/AutoID, /NoAutoID, /FallBack, the M8070A software starts several servers
to handle SCPI commands. (Refer to the table above.)
/Socket, /Telnet, /Inst: If -1, don't start the respective servers
/FallBack: If starting a server fails because of a conflict, try using another
port or number
"HiSLIP, VXI-11.3: increase the index until a server can be started
successfully
"Socket, Telnet: start with port 60000, then increase it until the servers can
be started successfully. If neither socket nor telnet is disabled the M8070A
software tries to start the servers on two consecutive ports
(socket port = telnet port + 1)
/AutoID: Automatically select ports and number for the connections,
which are unique per instrument.
"This is the default behavior; it is not necessary to specify this argument on
the command line.
"/Socket, /Telnet, /Inst are ignored (unless they are -1 and a server is
disabled)
"If the M8070A software detects more than one AXIe module, use a special
mechanism to obtain a number for the HiSLIP and VXI-11.3 servers, which
makes sure that the M8070A software always uses the same VISA resource
string per module
"The socket and telnet port are then calculated from the HiSLIP index:
telnet port = 60000 + 2 * <HiSLIP index>
socket port = 60000 + 2 * <HiSLIP index> + 1
Keysight M8070A Programming Guide95
4SCPI Command Language
NOTE
Note: Ports may already be in use by Windows or other applications, so
they are not available for M8195A.
/NoAutoID: Do not automatically select ports and number for the
connections, use the values specified with /Socket, /Telnet, /Inst or their
respective default values instead.
If both /NoAutoID and /AutoID are specified, /AutoID overrides /NoAutoID.
The first port not assigned by IANA is 49152 (IANA, Internet Assigned Numbers
Authority, http://www.iana.org).
96Keysight M8070A Programming Guide
Keysight M8070A System Software for M8000 Series of
BER Test Solutions
The SCPI commands are divided into subsystems, which reflect the various
functionality of the instrument. The following figure shows where the
port-related subsystems are located.
Table 20 Subsystems
SubsystemDescription
STATusThe STATus subsystem reports the current system condition,
TRIGgerThe TRIGger subsystem selects the following trigger modes: