& Agilent 8166A Lightwave Multichannel System, Third Edition
In this Manual
This manual contains information about SCPI commands which can be
used to program the following instruments:
• Agilent 8163A Lightwave Multimeter
• Agilent 8164A Lightwave Measurement System
• Agilent 8166A Lightwave Multichannel System
The Structure of this Manual
This manual is divided into 5 parts:
• “Introduction to Programming” on page 15 gives a general
introduction to SCPI programming with the Agilent 8163A Lightwave
Multimeter, the Agilent 8164A Lightwave Measurement System, and
the Agilent 8166A Lightwave Multichannel System.
• “Specific Commands” on page 35 lists all instrument specific
commands.
• “Instrument Setup and Status” on page 45, “Measurement
Operations & Settings” on page 67, and “Mass Storage, Display, and
Print Functions” on page 129 give fuller explanations of all
instrument specific commands.
• “VISA Programming Examples” on page 133 gives some example
programs showing how the SCPI commands can be used with the
Agilent 8163A Lightwave Multimeter, the Agilent 8164A Lightwave
Measurement System, and the Agilent 8166A Lightwave Multichannel
System.
• “The Agilent 816x VXIplug&play Instrument Driver” on page 155,
“GPIB Command Compatibility List” on page 183, and “Error
Codes” on page 191 give information about the Agilent 816x
VXIplug&play Instrument Driver, compatibility issues, and error
codes.
Conventions used in this Manual
• All commands and typed text is written in Courier font, for example
• SCPI commands are written in mixed case: text that you MUST print is
written in capitals; text which is helpful but nor necessary is written in
lower case.
So, the command INITiate[:IMMediate] can be entered either as
init[:imm], or as initiate[:immediate]. It does not matter
whether you enter text using capitals or lower-case letters.
• SCPI commands often contain extra arguments in square brackets.
These arguments may be helpful, but they need not be entered.
So, the command INITiate[:IMMediate] can be entered as init
or initiate:imm.
• A SCPI command which can be either a command or a query is
appended with the text /?.
So, DISPlay:ENABle/? refers to both the command
DISPlay:ENABle and the query DISPlay:ENABle?.
Related Manuals
You can find more information about the instruments covered by this
manual in the following manuals:
NOTEPlease note that User Guides no longer contain programming
information, and must now be used in conjunction with this manual.
If you are not familiar with the General Purpose Interface Bus, GPIB,
then refer to the following books:
• ANSI/IEEE-488.1-1978, IEEE Standard Digital Interface for
Programmable Instrumentation, and ANSI/IEEE-488.2-1987, IEEE
Standard Codes, Formats, and Common Commands, published by
the Institute of Electrical and Electronic Engineers.
In addition, the commands not from the IEEE 488.2 standard are defined
according to the Standard Commands for Programmable Instruments
(SCPI). For an introduction to SCPI and SCPI programming techniques,
refer to the following documents:
• Hewlett-Packard Press (Addison-Wesley Publishing Company, Inc.): A
Beginners Guide to SCPI by Barry Eppler.
Status Byte Register32
Standard Event Status Register32
Operation/Questionable Status Summary32
Operation/Questionable Status Summary Register32
Operation/Questionable Slot Status33
Operation Slot Status Register33
Questionable Slot Status Register33
Status Command Summary34
Other Commands34
Specific Commands35
Specific Command Summary37
Instrument Setup and Status45
IEEE-Common Commands47
Status Reporting – The STATus Subsystem54
Interface/Instrument Behaviour Settings – The SYSTem
Subsystem
64
Measurement Operations & Settings67
Root Layer Command69
Measurement Functions – The SENSe Subsystem72
Agilent 81635A and Agilent 81619A- Master and Slave
Channels
72
Signal Generation – The SOURce Subsystem92
Triggering - The TRIGger Subsystem117
Extended Trigger Configuration123
Extended Trigger Configuration Example127
Mass Storage, Display, and Print Functions129
Display Operations – The DISPlay Subsystem131
VISA Programming Examples133
How to Use VISA Calls135
How to Set up a Fixed Laser Source137
How to Measure Power using FETCh and READ139
& Agilent 8166A Lightwave Multichannel System, Third Edition
Contents
How to Co-ordinate Two Modules
143
How Power Varies with Wavelength147
How to Log Results150
The Agilent 816x VXIplug&play Instrument Driver155
Installing the Agilent 816x Instrument Driver157
Using Visual Programming Environments160
Getting Started with HP VEE160
GPIB Interfacing in HP VEE161
Getting Started with LabView162
Getting Started with LabWindows165
Features of the Agilent 816x Instrument Driver165
Directory Structure167
Opening an Instrument Session167
Closing an Instrument Session168
VISA Data Types and Selected Constant Definitions168
Error Handling169
Introduction to Programming170
Example Programs170
VISA-Specific Information171
Instrument Addresses171
Callbacks171
Development Environments171
Microsoft Visual C++ 4.0 (or higher) and Borland C++ 4.5 (or higher)
171
Microsoft Visual Basic 4.0 (or higher)171
HP VEE 5.01 (or higher)172
LabWindows CVI/ (R) 4.0 (or higher)172
Online Information172
Lambda Scan Applications173
Equally Spaced Datapoints174
How to Perform a Lambda Scan Application176
The Prepare Lambda Scan Function176
The Get Lambda Scan Parameters Function177
The Execute Lambda Scan Function177
How to Perform a Multi-Frame Lambda Scan Application178
The Equally Spaced Datapoints Function179
The Register Mainframe Function179
The Unregister Mainframe Function179
The Prepare Multi Frame Lambda Scan Function180
The Get MF Lambda Scan Parameters Function181
The Execute Multi Frame Lambda Scan Function181
The Get Lambda Scan Result Function181
The Get Number of PWM Channels Function182
The Get Channel Location Function182
GPIB Command Compatibility List183
Compatibility Issues185
GPIB Bus Compatibility185
Status Model185
Preset Defaults185
Removed Command186
Obsolete Commands187
Changed Parameter Syntax and Semantics187
Changed Query Result Values188
Timing Behavior189
Error Handling189
Command Order190
Instrument Status Settings190
Table 5Commands that can only be configured using the master channel . . . 73
Table 6Commands that are independent for both master and slave channels . . 73
Table 7Triggering and Power Measurements . . . . . . . . . 117
Table 8Generating Output Triggers from Power Measurements . . . . . 118
This chapter gives general information on how to control your
instrument remotely.
Descriptions for the actual commands for the instruments are given in
the following chapters. The information in these chapters is specific to
the Agilent 8163A Lightwave Multimeter, Agilent 8164A Lightwave
Measurement System, and Agilent 8166A Lightwave Multichannel System
and assumes that you are already familiar with programming the GPIB.
& Agilent 8166A Lightwave Multichannel System, Third Edition
GPIB InterfaceIntroduction to Programming
GPIB Interface
The interface used by your instrument is the GPIB (General Purpose
Interface Bus).
GPIB is the interface used for communication between a controller and
an external device, such as the tunable laser source. The GPIB conforms
to IEEE standard 488-1978, ANSI standard MC 1.1 and IEC
recommendation 625-1.
If you are not familiar with the GPIB, then refer to the following books:
• The International Institute of Electrical and Electronics Engineers.
IEEE Standard 488.1-1987, IEEE Standard Digital Interface for
Programmable Instrumentation. New York, NY, 1987
• The 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
To obtain a copy of either of these last two documents, write to:
The Institute of Electrical and Electronics Engineers, Inc.
345 East 47th Street
New York, NY 10017
USA.
In addition, the commands not from the IEEE-488.2 standard, are defined
according to the Standard Commands for Programmable Instruments
(SCPI).
For an introduction to SCPI, and SCPI programming techniques, please
refer to the following documents:
• Hewlett-Packard Press (Addison-Wesley Publishing Company, Inc.). A
Beginners Guide to SCPI. Barry Eppler. 1991.
• The SCPI Consortium: Standard Commands for Programmable
Instruments. To obtain a copy of this manual, contact the following
address:
SCPI Consortium Office
Bode Enterprise
2515 Camino del Rio South, Suite 340
San Diego, CA, 92108
USA
The interface of the Agilent 8163A Lightwave Multimeter and of the
Agilent 8164A Lightwave Measurement System to the GPIB is defined by
the IEEE Standards 488.1 and 488.2.
Table 1 shows the interface functional subset that the instruments
implement.
Table 1GPIB Capabilities
MnemonicFunction
SH1Complete source handshake capability
AH1Complete acceptor handshake capability
T6Basic talker; serial poll; unaddressed to talk if addressed to
listen
L4Basic listener; unaddressed to listen if addressed to talk; no
listen only
SR1Complete service request capability
RL1Complete remote/local capability
PP0No parallel poll capability
DC1Device clear capability
DT0No device trigger capability
C0No controller capability (Controller capability to be imple-
mented)
Setting the GPIB Address
There are two ways to set the GPIB address:
• You can set the GPIB address by using the command
“:SYSTem:COMMunicate:GPIB[:SELF]:ADDRess” on page 66.
• You can set the GPIB address from the front panel. See your
instrument’s User’s Guide for more information.
2 No modification is made inside strings or binary blocks. Outside
strings and binary blocks, the following modifications are made:
– Lower-case characters are converted to upper-case.
– The characters 00
).
(20
16
– Two or more blanks are truncated to one.
3 An EOI (End Or Identify) sent with any character is put into the input
queue as the character followed by a line feed (LF, 0A
with a LF, only one LF is put into the input queue.
4 The parser starts if the LF character is received or if the input queue is
full.
to 0916 and 0B16 to 1F16 are converted to spaces
16
). If EOI is sent
16
Clearing the Input Queue
Switching the power off, or sending a Device Interface Clear signal,
causes commands that are in the input queue, but have not been
executed to be lost.
The Output Queue
The output queue contains responses to query messages. The instrument
transmits any data from the output queue when a controller addresses
the instrument as a talker.
Each response message ends with a carriage return (CR, 0D
), with EOI=TRUE. If no query is received, or if the query has an
(0A
16
error, the output queue remains empty.
The Message Available bit (MAV, bit 4) is set in the Status Byte register
whenever there is data in the output queue.
) and a LF
16
The Error Queue
The error queue is 30 errors long. It is a FIFO queue (first-in first-out).
That is, the first error read is the oldest error to have occurred. A new
error is only put into the queue if it is not already in it.
If more than 29 errors are put into the queue, the message:
& Agilent 8166A Lightwave Multichannel System, Third Edition
Programming and Syntax Diagram ConventionsIntroduction to Programming
Programming and Syntax Diagram
Conventions
A program message is a message containing commands or queries that
you send to the instruments. The following are a few points about
program messages:
• You can use either upper-case or lower-case characters.
• You can send several commands in a single message. Each command
must be separated from the next one by a semicolon (;).
• A command message is ended by a line feed character (LF) or
<CR><LF>.
• You can use any valid number/unit combination.
In other words, 1500NM,1.5UM and 1.5E-6M are all equivalent.
If you do not specify a unit, then the default unit is assumed. The
default unit for the commands are given with command description in
the next chapter.
Short Form and Long Form
The instrument accepts messages in short or long forms.
For example, the message
:STATUS:OPERATION:ENABLE 768
is in long form.
The short form of this message is
:STAT:OPER:ENAB 768
In this manual, the messages are written in a combination of upper and
lower case. Upper case characters are used for the short form of the
message.
For example, the above command would be written
:STATus:OPERation:ENABle
The first colon can be left out for the first command or query in your
message. That is, the example given above could also be sent as
Introduction to ProgrammingProgramming and Syntax Diagram Conventions
Command and Query Syntax
All characters not between angled brackets must be sent exactly as
shown.
The characters between angled brackets (<...>) indicate the kind of
data that you should send, or that you get in a response. You do not type
the angled brackets in the actual message.
Descriptions of these items follow the syntax description. The following
types of data are most commonly used:
stringis ascii data. A string is contained between double
quotes ("...") or single quotes (‘...’).
value is numeric data in integer (12), decimal (34.5) or ex-
ponential format (67.8E-9).
wspis a white space.
Other kinds of data are described as required.
The characters between square brackets ([...]) show optional
information that you can include with the message.
The bar (|) shows an either-or choice of data, for example, a|b means
either a or b, but not both simultaneously.
Extra spaces are ignored, so spaces can be inserted to improve
readability.
Units
Where units are given with a command, usually only the base units are
specified. The full sets of units are given in the table below.
Table 2Units and allowed Mnemonics
UnitDefaultAllowed Mnemonics
metersMPM, NM, UM, MM, M
decibelDBMDB, DB
secondSNS, US, MS, S
decibel/1mWDBMMDBM, DBM
HertzHZHZ, KHZ, MHZ, GHZ, THZ
WattWattPW, NW, UW, MW, Watt
meters per second M/SNM/S, UM/S, MM/S, M/S
& Agilent 8166A Lightwave Multichannel System, Third Edition
Programming and Syntax Diagram ConventionsIntroduction to Programming
Data Types
With the commands you give parameters to the instrument and receive
response values from the instrument. Unless explicitly specified these
data are given in ASCII format. The following types of data are used:
• Boolean data may only have the values 0 or 1.
• Integer range is given for each individual command.
• Float variables may be given in decimal or exponential writing (0.123
or 123E-3).
All Float values conform to the 32 bit IEEE Standard, that is, all
Float values are returned as 32-bit real values.
• A string is contained between double quotes ("...") or single quotes
(‘...’). When the instrument returns a string, it is always included in "
" and terminated by <END>.
• When a register value is given or returned (for example *ESE), the
decimal values for the single bits are added. For example, a value of
nine means that bit 0 and bit 3 are set.
• Larger blocks of data are given as Binary Blocks, preceded by
“#<H><Len><Block>”, terminated by <END>; <H> represents the
number of digits, <Len> represents the number of bytes, and <Block>
is the data block. For example, for a Binary Block with 1 digit and 6
bytes this is: #16TRACES<END>.
Slot and Channel Numbers
Each module is identified by a slot number and a channel number. For
commands that require you to specify a channel, the slot number is
represented by [n] in a command and the channel number is represented
by [m].
The slot number represents the module’s position in the mainframe.
These are:
• from one to two for the Agilent 8163A,
• from zero to four for the Agilent 8164A, and
• from one to seventeen for the Agilent 8166A.
These numbers are displayed on the front panel beside each module slot.
NOTEThe Agilent 8164A slot for back-loadable tunable laser modules is
Introduction to ProgrammingProgramming and Syntax Diagram Conventions
Channel numbers apply to modules that have two inputs/outputs, for
example, the Agilent 81635A Dual Power Sensor.
Modules with two channels, for example, the Agilent 81635A Dual Power
Sensor, use the channel number to distinguish between these channels.
NOTEThe channel number of single channel modules is always one.
For example, if you want to query slot 1, channel 2 with the command,
“:SENSe[n]:[CHANnel[m]]:POWer:WAVelength?” on page 89, you
should send the command:
• :sens1:chan2:pow:wav?
NOTEIf you do not specify a slot or channel number, the lowest possible
number is used as the default value. This means:
•Slot 1 for the Agilent 8163A and Agilent 8166A mainframes.
•Slot 0 for the Agilent 8164A mainframe.
•Channel 1 for all channels.
Laser Selection Numbers
The laser selection number, [l], identifies the upper or lower wavelength
laser source for dual wavelength Laser Source modules and Return Loss
modules with two internal laser sources. The lower wavelength source is
denoted by 1. The upper wavelength source is denoted by 2.
NOTEFor Return Loss modules, 0 denotes the use of an external laser source
as the input to your Return Loss module for the following commands:
• “:SENSe[n]:[CHANnel[m]]:RETurnloss:CORRection:FPDelta[l]” on
page 90,
• “:SENSe[n]:[CHANnel[m]]:RETurnloss:CORRection:FPDelta[l]?”
on page 90,
• “:SENSe[n]:[CHANnel[m]]:RETurnloss:CORRection:REFLectance[l]”
on page 91, and
• “:SENSe[n]:[CHANnel[m]]:RETurnloss:CORRection:REFLectance[l]
?” on page 91.
& Agilent 8166A Lightwave Multichannel System, Third Edition
Common CommandsIntroduction to Programming
Common Commands
The IEEE 488.2 standard has a list of reserved commands, called
common commands. Some of these commands must be implemented by
any instrument using the standard, others are optional.
Your instrument implements all the necessary commands, and some
optional ones. This section describes the implemented commands.
Common Command Summary
Table 3 gives a summary of the common commands.
Table 3Common Command Summary
Command Parameter FunctionPage
*CLS Clear Status Commandpage 47
*ESE Standard Event Status Enable Commandpage 48
*ESE? Standard Event Status Enable Querypage 48
*ESR? Standard Event Status Register Querypage 49
*IDN? Identification Querypage 49
*OPCOperation Complete Commandpage 50
*OPC? Operation Complete Querypage 50
*OPT? Options Querypage 51
*RST Reset Commandpage 51
*STB? Read Status Byte Querypage 52
*TST? Self Test Querypage 53
*WAI Wait Commandpage 53
NO T EThese commands are described in more detail in “IEEE-Common Commands” on page 47.
Common Status Information
There are three registers for the status information. Two of these are
status-registers and one is an enable-registers. These registers conform
to the IEEE Standard 488.2-1987. You can find further descriptions of
these registers under *ESE, *ESR?, and *STB?.
Figure 2 shows how the Standard Event Status Enable Mask (SESEM)
and the Standard Event Status Register (SESR) determine the Event
Status Bit (ESB) of the Status Byte.
*ESE
sets the Standard Event Status Enable Mask
*STB?
returns the Status Byte Register
OSBESBQSB
Status
Byte
001
All bits shown as are unused
Figure 2The Event Status Bit
The SESR contains the information about events that are not slot
specific. For details of the function of each bit of the SESR, see
“Standard Event Status Register” on page 32.
01234567
*ESR?
Event
Status
Enable
Mask
&
&
&
&
OR
Event
Status
Register
returns the Standard Event Status Register
&
&
01234567
111111
&
&
01234567
100000
The SESEM allows you to choose the event that may affect the ESB of
the Status Byte. If you set a bit of the SESEM to zero, the corresponding
event cannot affect the ESB. The default is for all the bits of the SESEM
to be set to 0.
The questionable and operation status systems set the Operational Status
Bit (OSB) and the Questionable Status Bit (QSB). These status systems
are described in “The Status Model” on page 27 and “Status Reporting – The STATus Subsystem” on page 54.
NOTEUnused bits in any of the registers change to 0 when you read them.
& Agilent 8166A Lightwave Multichannel System, Third Edition
The Status ModelIntroduction to Programming
The Status Model
Status Registers
Each node of the status circuitry has three registers:
• A condition register (CONDition), which contains the current status.
This register is updated continuously. It is not changed by having its
contents read.
• The event register (EVENt), which contains details of any positive
transitions in the corresponding condition register, that is, when a bit
changes from 0 → 1. The contents of this register are cleared when it
is read. The contents of any higher-level registers are affected with
regard to the appropriate bit.
• The enable register (ENABle), which enables changes in the event
register to affect the next stage of registers.
NOTEThe event register is the only kind of register that can affect the next
The structures of the Operational and Questionable Status Systems are
similar. Figure 4 describe how the Questionable Status Bit (QSB) and
the Operational Status Bit (OSB) of the Status Byte Register are
determined.
Enable Registers
To th e
OR
Event Registers
Condition Register
of the Next Node
A positive transition in the condition
11111
Figure 3The Registers and Filters for a Node
The Operational/Questionable Slot Status Event Register
(OSSER/QSSER) contains the status of a particular module slot. A bit
changes from 0 → 1 when an event occurs, for example, when a laser is
switched on. For details of the function of each bit of these registers, see
“Operation/Questionable Status Summary Register” on page 32 and
“Operation/Questionable Status Summary Register” on page 32.
The Operational/Questionable Slot Enable Status Mask
(OSESM/QSESM) allows you to choose the events for each module slot
that may affect the Operational/Questionable Status Event Register (see
below). If you set a bit of the OSESM/QSESM to zero, the occurence of
the corresponding event for this particular module slot cannot affect the
Operational/Questionable Status Event Register. The default is for all the
bits of the OSESM/QSESM to be set to 0.
register, when a bit changes from 0 → 1,
causes the corresponding bit of the
corresponding event register
to change from 0 → 1.
& Agilent 8166A Lightwave Multichannel System, Third Edition
The Status ModelIntroduction to Programming
The Operational/Questionable Status Event Summary Register
(OSESR/QSESR) summarizes the status of every module slot of your
instrument. If, for any slot, any bit of the QSSER goes from 0 → 1 AND
the corresponding bit of the QSSEM is 1at the same time, the QSESR bit
representing that slot is set to 1.
The Operational/Questionable Status Enable Summary Mask
(OSESM/QSESM) allows you to choose the module slots that may affect
the OSB/QSB of the Status Byte. If any bit of the QSESR goes from 0 → 1
AND the corresponding bit of the QSESM is 1at the same time, the QSB
of the Status Byte is set to 1. If you set a bit of the OSESM/QSESM to
zero, the corresponding module slot cannot affect the OSB/QSB. The
default is for all the bits of the OSESM/QSESM to be set to 0.
The Operational/Questionable Status Enable Summary Mask for the
Agilent 8163A Lightwave Multimeter and the Agilent 8164A Lightwave
Measurement System consists of one level. These are described in
“Status System for 8163A & 8164A” on page 30.
As the Agilent 8166A Lightwave Multichannel System has 17 module
slots, the Operational/Questionable Status Enable Summary Mask
consists of two levels. This is described in “Status System for 8166A” on page 30.
The status system for the Agilent 8163A Lightwave Multimeter and the
Agilent 8164A Lightwave Measurement System returns the status of 2
and 5 module slots respectively. The Operational/Questionable Status
Summary Registers consist of one level and are described by Figure 4.
Any commands that require LEVel1 do not apply to these mainframes.
Status Byte Register
Status Summary
Slot 1
Operational/Questionable Status
Enable Summary Mask
Register
Operational/Questionable Status
Event Summary Register
Operational/Questionable Status
Condition Summary Register
Operational/Questionable
Slot Status Enable Mask
Register
Operational/Questionable
Slot Status Event
Register
Operational/Questionable
Slot Status Condition
Register
Status Byte
to next
&
&
&
&
&
&
OR
for a positive
transition
&
&
to next
level
OR
for a positive
transition
level
Figure 4The Operational/Questionable Status System for 8163A & 8164A
Status System for 8166A
The status system for the Agilent 8166A Lightwave Multichannel System
returns the status of 17 module slots. The Operational/Questionable
Status Summary Registers consists of two levels, as described by Figure
& Agilent 8166A Lightwave Multichannel System, Third Edition
The Status ModelIntroduction to Programming
Module slots 1 to 14 affect the Level 0 summary register as described in
Figure 4. Bit 0 of the Level 0 summary registers represents the summary
of the status of module slots 15, 16, and 17. The Level 1 summary
registers contain an individual summary for each of these module slots.
Status Byte Register
Status
Summary
for Level 0
Status
Summary
for Level 1
Slot 15
Operational/Questionable Status
Enable Summary Mask
Register (Level 1)
Operational/Questionable Status
Event Summary Register (Level 1)
Operational/Questionable Status
Condition Summary Register (Level 1)
Operational/Questionable
Slot Status Enable Mask
Register
Operational/Questionable
Slot Status Event
Register
Operational/Questionable
Slot Status Condition
Register
Status Byte
Operational/Questionable Status
Enable Summary Mask
Register (Level 0)
Operational/Questionable Status
Event Summary Register (Level 0)
Operational/Questionable Status
Condition Summary Register (Level 0)
&
&
&
&
to next
&
&
&
&
OR
for a positive
transition
&
&
&
OR
for a positive
transition
level
to next
level
OR
&
for a positive
transition
to next
level
Figure 5The Operational/Questionable Status System for 8166A
*STB?returns status byte, value 0 .. +255
*ESEsets the standard event status enable mask, parameter 0 .. +255
*ESE?returns SESE, value 0 .. +255
*ESR?returns the standard event status register, value 0 .. +255
*OPCparses all program message units in the message queue.
*OPC?returns 1 if all operations (scan trace printout, measurement) are com-
pleted. Otherwise it returns 0.
*CLSclears the status byte and SESR, and removes any entries from the er-
ror queue.
*RSTclears the error queue, loads the default setting, and restarts communi-
cation.
NOTE: *RST does NOT touch the STB or SESR. A running measurement
is stopped.
*TST?initiates an instrument selftest and returns the results as a 32 bit LONG.
Other Commands
*OPT?returns the installed modules and the slots these modules are installed
in:
For example, *OPT? → 81682A, 81533B, 81532A, ,
Modules 81682A, 81533B, and 81532A are installed in slots 0 to 2 respectively. Slots 3 and 4 are empty.
*WAIprevents the instrument from executing any further commands until the
current command has finished executing. All pending operations are
completed during the wait period.
*IDN?identifies the instrument; returns the manufacturer, instrument model
number, serial number, and firmware revision level.
This chapter lists all the instrument specific commands relating to the
Agilent 8163A Lightwave Multimeter and the Agilent 8164A Lightwave
Measurement System, with a single-line description.
Each of these summaries contains a page reference for more detailed
information about the particular command later in this manual.
& Agilent 8166A Lightwave Multichannel System, Third Edition
Specific Command SummarySpecific Commands
Specific Command Summary
The commands are ordered in a command tree. Every command belongs
to a node in this tree.
The root nodes are also called the subsystems. A subsystem contains all
commands belonging to a specific topic. In a subsystem there may be
further subnodes.
All the nodes have to be given with a command. For example in the
command disp:brig
• DISPlay is the subsystem containing all commands for controlling
the display,
• BRIGhtness is the command selecting brightness.
NOTEIf a command and a query are both available, the command ends /?.
So, disp:brig/? means that disp:brig and disp:brig? are both
available.
Table 4 gives an overview of the command tree. You see the nodes, the
subnodes, and the included commands.
Table 4Specific Command Summary
CommandDescriptionPage
:DISPlay
:BRIGhtness/?Changes or queries the current display brightness.page 131
:CONTrast/?Changes or queries the current display contrast.page 131
:ENABle/?Switches the display on or off or queries whether the display is on or
off.
:FETCh[n][:CHANnel[m]][:SCALar]
:POWer[:DC]?Returns a power value from a sensor.page 74
:RETurnloss?Returns the current return loss value.page 74
:RETurnloss?Returns a return loss value.page 74
:INITiate[n]:[CHANnel[m]]
[:IMMediate]Starts a measurement.page 74
:CONTinuous/?Starts or Queries a single/continuous measurement.page 75
This chapter gives descriptions of commands that you can use when
setting up your instrument. The commands are split into the following
separate subsytems:
• IEEE specific commands that were introduced in “Common
Commands” on page 25.
• STATus subsystem commands that relate to the status model.
• SYSTem subsystem commands that control the serial interface and
& Agilent 8166A Lightwave Multichannel System, Third Edition
IEEE-Common CommandsInstrument Setup and Status
IEEE-Common Commands
“Common Commands” on page 25 gave a brief introduction to the IEEE-
common commands which can be used with the instruments. This
section gives fuller descriptions of each of these commands.
command:
syntax:*CLS
description:The CLear Status command *CLS clears the following:
parameters:none
response:none
example:*CLS
*CLS
• Error queue
• Standard event status register (SESR)
• Status byte register (STB)
After the *CLS command the instrument is left waiting for the next command. The instrument setting is unaltered by the command, although *OPC/*OPC? actions are cancelled.
& Agilent 8166A Lightwave Multichannel System, Third Edition
IEEE-Common CommandsInstrument Setup and Status
command:
syntax:*ESR?
description:The standard Event Status Register query *ESR? returns the contents of the Standard
parametersnone
responseThe bit value for the register (a 16-bit signed integer value):
example:*ESR? → 21<END>
command:
syntax:*IDN?
description:The IDeNtification query *IDN? gets the instrument identification over the interface.
parameters:none
response:The identification terminated by <END>:
*ESR?
Event Status Register. The register is cleared after being read.
BitMnemonicDecimal Value
7 (MSB)Power On 128
6Not used0
5Command Error 32
4 Execution Error 16
3Device Dependent Error 8
2Query Error 4
1Not used0
0 (LSB)Operation Complete 1
*IDN?
For example.
HEWLETT-PACKARD
mmmm
ssssssss
rrrrrrrrrr
NOTEThe Agilent 8163A, Agilent 8164A, and Agilent8166A will always return HEWLETT-
PACKARD as the manufacturer. This will not be affected by the transition of these
instruments to Agilent Technologies. This will allow programs that use this string to
continue functioning.
See “:SLOT[n]:HEAD[n]:IDN?” on page 71 for information on module identity strings.
description:The instrument parses and executes all program message units in the input queue and
parameters:none
response:none
example:*OPC
command:
syntax:*OPC?
description:The OPeration Complete query *OPC? parses all program message units in the input
*OPC
sets the operation complete bit in the standard event status register (SESR). This command can be used to avoid filling the input queue before the previous commands have finished executing.
The following actions cancel the *OPC command (and put the instrument into Operation
Complete, Command Idle State):
• Power-on
• the Device Clear Active State is asserted on the interface.
• *CLS
• *RST
*OPC?
queue, sets the operation complete bit in the Standard Event Status register, and places
an ASCII ’1’ in the output queue, when the contents of the input queue have been processed.
The following actions cancel the *OPC? query (and put the instrument into Operation
Complete, Command Idle State):
• Power-on
• the Device Clear Active State is asserted on the interface.
• *CLS
• *RST
parameters:none
response:1<END> is always returned.
example:*OPC? → 1<END>
& Agilent 8166A Lightwave Multichannel System, Third Edition
IEEE-Common CommandsInstrument Setup and Status
command:
syntax:*OPT?
description:The OPTions query *OPT? returns the modules installed in your instrument.
parameters:none
response:Returns the part number of all installed modules, separated by commas.
example:*OPT? → 81682A ,, 81533B, 81532A, <END>
command:
syntax:*RST
description:The ReSeT command *RST sets the mainframe and all modules to the reset setting (stan-
*OPT?
Slots are listed starting with the lowest slot number, that is, slot 0 for the Agilent 8164A and
Slot 1 for the Agilent 8163A and Agilent 8166A.
If any slot is empty or not recognised, two spaces are inserted instead of the module’s part
number. See the example below, where slots 1 and 4 are empty.
*RST
dard setting) stored internally.
Pending *OPC? actions are cancelled.
The instrument is placed in the idle state awaiting a command. The *RST command clears
the error queue.
The *RST command is equivalent to the *CLS command AND the syst:preset com-
description:The STatus Byte query *STB? returns the contents of the Status Byte register.
parameters:none
response:The bit value for the register (a 16-bit signed integer value):
example:*STB? → 128<END>
*STB?
BitMnemonicDecimal Value
7 (MSB)Operation Status 128
6 Not used 0
5 Event Status Bit 32
4 Not used 0
3 Questionable Status8
2 Not used 0
1 Not used 0
0 Not used 0
& Agilent 8166A Lightwave Multichannel System, Third Edition
IEEE-Common CommandsInstrument Setup and Status
command:
syntax:*TST?
description:The self-TeST query *TST? makes the instrument perform a self-test and place the results
parameters:none
response:The sum of the results for the individual tests (a 32-bit signed integer value, where 0 ≤ val-
example:*TST? → 0<END>
*TST?
of the test in the output queue. If the self-test fails, the results are also put in the error
queue. We recommend that you read self-test results from the error queue. No further
commands are allowed while the test is running. After the self-test the instrument is returned to the setting that was active at the time the self-test query was processed. The
self-test does not require operator interaction beyond sending the *TST? query.
ue≤ 4294967296):
Bits MnemonicDecimal Value
31Selftest failed on MainframeA negative value
18 - 30Not used0
17Selftest failed on Slot 17131072
16Selftest failed on Slot 1665536
15Selftest failed on Slot 1532768
14Selftest failed on Slot 1416384
13Selftest failed on Slot 138192
12Selftest failed on Slot 124096
11Selftest failed on Slot 112048
10Selftest failed on Slot 101024
9Selftest failed on Slot 9512
8Selftest failed on Slot 8256
7Selftest failed on Slot 7128
6Selftest failed on Slot 664
5Selftest failed on Slot 532
4Selftest failed on Slot 416
3Selftest failed on Slot 38
2Selftest failed on Slot 24
1Selftest failed on Slot 12
0Selftest failed on Slot 01
If 16 is returned, the module in slot 4 has failed.
If 18 is returned, the modules in slots 1 and 4 have failed.
A value of zero indicates no errors.
command:
syntax:*WAI
description:The WAIt command prevents the instrument from executing any further commands until
description:Returns the Operational Status Event Summary Register (OSESR).
parameters:none
response:The sum of the results for the slots (a 16-bit signed integer value, where 0 ≤ value ≤ 32767):
description:Reads the Operational Status Condition Summary Register.
parameters:none
response:The sum of the results for the individual slots (a 16-bit signed integer value, where 0 ≤ value
description:Returns the OSESM for the OSESR
parameters:none
response:The bit value for the operation enable mask as a 16-bit signed integer value (0 .. +32767)
example:stat:oper:enab? → +128<END>
command:
syntax::STATus:OPERation[:EVENt]:LEVel1?
description:Returns the Operational Status Event Summary Register (OSESR) for slots 15 to 17 of the
parameters:none
response:The sum of the results for the slots (a 16-bit signed integer value, where 0 ≤ value ≤ 32767):
description:Sets the bits in the Operational Status Enable Summary Mask (OSESM) that enable the con-
parameters:The bit value for the OSESM as a 16-bit signed integer value (0 .. +32767)
response:none
example:stat:oper:enab:level1 128
command:
syntax::STATus:OPERation:ENABle:LEVel1?
description:Returns the OSESM for the OSESR for slots 15 - 17 of the Agilent 8166A Lightwave Measure-
parameters:none
response:The bit value for the operation enable mask as a 16-bit signed integer value (0 .. +32767)
example:stat:oper:enab:level1? → +128<END>
:STATus:OPERation:ENABle:LEVel1
tents of the OSESR for slots 15 - 17 of the Agilent 8166A Lightwave Measurement System to
affect the Status Byte (STB).
Setting a bit in this register to 1 enables the corresponding bit in the OSESR for slots 15 - 17
of the Agilent 8166A Lightwave Measurement System to affect bit 7 of the Status Byte.
The default value is 0.
:STATus:OPERation:ENABle:LEVel1?
ment System
command:
syntax::STATusn:OPERation[:EVENt]?
description:Returns the Operational Slot Status Event Register (OSSER) of slot n.
parameters:none
response:The results for the individual slot events (a 16-bit signed integer value, where 0 ≤ value ≤
example:stat1:oper? → +0<END>
:STATusn:OPERation[:EVENt]?
32767):
Bit
4-15
3
2
1
0
Mnemonic
Not used
Slot n: Zeroing started
Not used
Slot n: Coherence Control has been switched on
Slot n: Laser has been switched on
Instrument Setup and StatusStatus Reporting – The STATus Subsystem
command:
syntax::STATusn:OPERation:CONDition?
description:Returns the Operational Slot Status Condition Register of slot n.
parameters:none
response:The results for the individual slot events (a 16-bit signed integer value, where 0 ≤ value ≤
description:Sets the bits in the Operation Slot Status Enable Mask (OSSEM) for slot n that enable the
parameters:The bit value for the OSSEM as a 16-bit signed integer value (0 .. +32767)
response:none
example:stat:oper:enab 128
:STATusn:OPERation:CONDition?
32767):
Bit
4-15
3
2
1
0
:STATusn:OPERation:ENABle
contents of the Operation Slot Status Event Register (OSSER) for slot n to affect the OSESR.
Setting a bit in this register to 1 enables the corresponding bit in the OSSER for slot n to affect bit n of the OSESR.
Mnemonic
Not used
Slot n: Zeroing ongoing
Not used
Slot n: Coherence Control is switched on
Slot n: Laser is switched on
Decimal Value
0
8
0
2
1
command:
syntax::STATusn:OPERation:ENABle?
description:Returns the OSSEM of slot n
parameters:none
response:The bit value for the OSSEM as a 16-bit signed integer value (0 .. +32767)
example:stat:oper:enab? → +128<END>
command:
syntax::STATus:PRESet
description:Presets all bits in all the enable masks for both the OPERation and QUEStionable status
parameters:none
response:none
example:stat:pres
:STATusn:OPERation:ENABle?
:STATus:PRESet
systems to 0, that is, OSSEM, QSSEM, OSESM, and QSESM.
description:Returns the Questionable Status Event Summary Register (QSESR).
parameters:none
response:The sum of the results for the QSESR as a 16-bit signed integer value (0 .. +32767)
description:Returns the Questionable Status Condition Summary Register.
parameters:none
response:The sum of the results for the Questionable Status Condition Summary Register as a 16-bit
description:Returns the QSESM for the event register
parameters:none
response:The bit value for the QSEM as a 16-bit signed integer value (0 .. +32767)
example:stat:ques:enab? → +128<END>
description:Returns the QSESM for the QSESR for slots 15 - 17 of the Agilent 8166A Lightwave Mea-
parameters:none
response:The bit value for the QSESM as a 16-bit signed integer value (0 .. +32767)
example:stat:oper:enab:level1? → +128<END>
:STATus:QUEStionable:ENABle:LEVel1
contents of the QSESR for slots 15 - 17 of the Agilent 8166A Lightwave Measurement System to affect the Status Byte (STB).
Setting a bit in this register to 1 enables the corresponding bit in the OSESR for slots 15 - 17
of the Agilent 8166A Lightwave Measurement System to affect bit 7 of the Status Byte.
The default value is 0.
:STATus:QUEStionable:ENABle:LEVel1?
surement System
command:
syntax::STATusn:QUEStionable[:EVENt]?
description:Returns the questionable status of slot n - the Questionable Slot Status Event Register
parameters:none
response:The results for the individual slot events (a 16-bit signed integer value, where 0 ≤ value ≤
example:stat1:oper? → +0<END>
:S TATus n:QUEStionable[:EVENt]?
(QSSER).
32767):
Bit
8-15
7
6
5
4
3
2
1
0
Every nth bit is the summary of slot n.
Mnemonic
Not used
Slot n: Duty cycle has been out of range
Slot n: ARA has been recommended
Slot n: Module has been out of specification
Slot n: Module has settled unsuccessfully
Slot n: Laser protection has been on
Slot n: Temperature has been out of range
Slot n: A Zeroing operation has failed
Slot n: Excessive Value has occurred
& Agilent 8166A Lightwave Multichannel System, Third Edition
Status Reporting – The STATus SubsystemInstrument Setup and Status
command:
syntax::STATusn:QUEStionable:CONDition?
description:Returns the Questionable Slot Status Condition Register for slot n.
parameters:none
response:The results for the individual slot events (a 16-bit signed integer value, where 0 ≤ value ≤
description:Sets the bits in the Questionable Slot Status Enable Mask (QSSEM) for slot n that enable
:S TATus n:QUEStionable:CONDition?
32767):
Bit
8-15
7
6
5
4
3
2
1
0
Every nth bit is the summary of slot n.
:S TATus n:QUEStionable:ENABle
the contents of the Questionable Slot Status Register (QSSR) for slot n to affect the QSESR.
Mnemonic
Not used
Slot n: Duty cycle is out of range
Slot n: ARA recommended
Slot n: Module is out of specification
Slot n: Module has not settled
Slot n: Laser protection on
Slot n: Temperature out of range
Slot n: Zeroing failed
Slot n: Excessive Value
Decimal Value
0
128
64
32
16
8
4
2
1
Setting a bit in this register to 1 enables the corresponding bit in the QSSER for slot n to af-
fect bit n of the QSESR.
parameters:The bit value for the QSSEM as a 16-bit signed integer value (0 .. +32767)
response:none
example:stat:ques:enab 128
command:
syntax::STATusn:QUEStionable:ENABle?
description:Returns the QSSEM for slot n
parameters:none
response:The bit value for the QSSEM as a 16-bit signed integer value (0 .. +32767)
example:stat:ques:enab? → +128<END>
description:Sets the instrument’s internal date.
parameters:• the first value is the year (four digits),
response:none
example:syst:date 1999, 1, 12
command:
syntax::SYSTem:DATE?
description:Returns the instrument’s internal date.
parameters:none
response:The date in the format year, month, day (16-bit signed integer values)
example:syst:date? → +1999,+1,+12<END>
command:
syntax::SYSTem:ERRor?
description:Returns the next error from the error queue (see “The Error Queue” on page 20).
:SYSTem:DATE
• the second value is the month, and
• the third value is the day.
:SYSTem:DATE?
:SYSTem:ERRor?
Each error has the error code and a short description of the error, separated by a comma,
for example 0, "No error".
Error codes are numbers in the range -32768 and +32767.
Negative error numbers are defined by the SCPI standard. Positive error numbers are de-
vice dependent.
parameters:none
response:The number of the latest error, and its meaning.
example:syst:err? → -113,"Undefined header"<END>
Instrument Setup and StatusInterface/Instrument Behaviour Settings – The SYSTem Subsystem
command:
syntax::SYSTem:TIME?
description:Returns the instrument’s internal time.
parameters:none
response:The time in the format hour, minute, second. Hours are counted 0...23 (16-bit signed inte-
example:syst:time? → +20,+15,+30<END>
command:
syntax::SYSTem:VERSion?
description:Returns the SCPI revision to which the instrument complies.
parameters:none
response:The revision year and number.
example:syst:vers? → 1995.0<END>
This chapter gives descriptions of commands that you can use when you
are setting up or performing measurements. The commands are split up
into the following subsystems:
• Root layer commands that take power measurements, configures
triggering, and return information about the mainframe and it’s slots
• SENSe subsystem commands that control Power Sensors, Optical
Head Interface Modules, and Return Loss Modules.
• SOURce subsystem commands that control Laser Source modules,
DFB source modules, Tunable Laser modules, and Return Loss
Modules with internal laser sources.
• TRIGger subsystem commands that control triggering.
Measurement Operations & SettingsMeasurement Functions – The SENSe Subsystem
command:
syntax::SLOT[n]:HEAD[m]:TST?
description:Returns the latest selftest results for an optical head.
NOTEThis command does not perform a selftest. Use selfTeST command, “*TST?” on
parameters:none
response:Returns an error code and a short description of the error.
example:slot:head:tst?
affects:Optical heads
command:
syntax::SPECial:REBoot
description:Reboots the mainframe and all modules.
parameters:none
response:none
example:spec:reb
:SLOT[n]:HEAD[m]:TST?
page 53, to perform a selftest.
→ +0,"self test OK"<END>
:SPECial:REBoot
Measurement Functions – The
SENSe Subsystem
The SENSe subsystem lets you control measurement parameters for a
Power Sensor, an Optical Head Interface module, or a return loss
module.
Agilent 81635A and Agilent 81619A- Master
and Slave Channels
For the Agilent 81635A Dual Power Sensor and Agilent 81619A Dual
Optical Head Interface module, channel 1 is the master channel and
channel 2 is the slave channel. The master and slave channels share the
same software and hardware triggering system. For some commands,
setting parameters for the master channel sets the parameters for the
slave channel. In these cases, you may only set parameters for the slave
channel by setting master channel parameters.
description:Reads the current return loss value. It does not provide its own triggering and so must be
:FETCh[n][:CHANnel[m]][:SCAlar]:POWer[:DC]?
be used with either continuous software triggering (see “:INITiate[n]:[CHANnel[m]]:CON-
Tinuous?” on page 75) or a directly preceding immediate software trigger (see “:INI-
Tiate[n]:[CHANnel[m]][:IMMediate]” on page 74).
It returns the power meter value the previous software trigger measured. Any subsequent
FETCh command will return the same value, if there is no subsequent software trigger.
If the reference state is relative, units are dB.
:FETCh[n][:CHANnel[m]][:SCAlar]:RETurnloss?
used with either continuous software triggering (see “:INITiate[n]:[CHANnel[m]]:CONTinu-
ous?” on page 75) or a directly preceding immediate software trigger (see “:INI-
Tiate[n]:[CHANnel[m]][:IMMediate]” on page 74).
It returns the return loss value the previous software trigger measured. Any subsequent
FETCh command will return the same value, if there is no subsequent software trigger.
parameters:none
response:The current power meter value as a float value in dB.
example:fetc1:ret? → +6.73370400E-00<END>
affects:All return loss modules
description:Initiates the software trigger system and completes one full trigger cycle, that is, one mea-
parameters:none
response:none
example:init
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel is also affected.
description:Sets the software trigger system to continuous measurement mode.
parameters:A boolean value:0 or OFF: do not measure continuously
response:none
example:init2:cont 1
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel is also affected.
description:Queries whether the software trigger system operates continuously or not
parameters:none
response:A boolean value:0 or OFF: measurement is not continuous
example:init2:cont? → 1<END>
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel parameters are identical.
description:Reads the current power meter value. It provides its own software triggering and does not
NOTEThe power meter must be running for this command to be effective.
parameters:none
response:The current power meter reading as a float value in dBm, W or dB.
NOTEIf the reference state is absolute, units are dBm or W.
example:read1:pow? → +1.33555600E-006<END>
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel is also triggered.
:READ[n][:CHANnel[m]][:SCALar]:POWer[:DC]?
need a triggering command.
If the software trigger system operates continuously (see “:INITiate[n]:[CHAN-
nel[m]]:CONTinuous?” on page 75), this command is identical to “:FETCh[n][:CHAN-
nel[m]][:SCAlar]:POWer[:DC]?” on page 74.
If the software trigger system does not operate continuously, this command is identical to
generating a software trigger (“:INITiate[n]:[CHANnel[m]][:IMMediate]” on page 74) and
then reading the power meter value.
If the reference state is relative, units are dB.
To read a simultaneous result from the slave channel, send “:FETCh[n][:CHAN-
nel[m]][:SCAlar]:POWer[:DC]?” on page 74 directly after this command.
description:Reads the current return loss value. It provides its own software triggering and does not
NOTEThe return loss module must be running for this command to be effective.
parameters:none
response:The current power meter reading as a float value in dB.
example:read1:ret? → +1.33555600E-000<END>
affects:All return loss modules
If no unit type is specified, decibels (dB) is implied.
response:none
example:sens1:corr 10DB
affects:All power meters
dual sensors:Master and slave channels are independent.
description:Returns the calibration factor for a module.
parameters:none
response:The calibration factor as a float value. Units are in dB, although no units are returned in
example:sens1:corr?
affects:All power meters
dual sensors:Master and slave channels are independent.
description:Zeros the electrical offsets for a power meter or return loss module.
parameters:none
response:none
example:sens1:corr:coll:zero
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel is also zeroed.
description:Zeros the electrical offsets for all installed power meter and return loss modules.
parameters:none
response:none
example:sens:chan:corr:coll:zero:all
affects:All power meters and return loss modules
dual sensors:Command is independent of channel.
Measurement Operations & SettingsMeasurement Functions – The SENSe Subsystem
NOTESetting parameters for the logging function sets some parameters,
including hidden parameters, for the stability and MinMax functions and
vice versa. You must use the
:SENSe[n][:CHANnel[m]]:FUNCtion:PARameter:LOGGing command to
set parameters before you start a logging function using the
:SENSe[n][:CHANnel[m]]:FUNCtion:STATe command.
<averaging time>[NS|US|MS|S]
description:Sets the number of data points and the averaging time for the logging data acquisition
function.
parameters:Data Points:
Data Points is the number of samples that are recorded before the
logging mode is completed. Data Points is an integer value.
Averaging time:
Averaging time is a time value in seconds.
There is no time delay between averaging time periods. Use
“:SENSe[n][:CHANnel[m]]:FUNCtion:PARameter:STABility?” on
page 81 if you want to use delayed measurement.
Averaging Time
Measurement Running
Measurement Stopped
135246879
t
If you specify no units for the averaging time value in your command, seconds are used as
the default.
NOTESee “:SENSe[n][:CHANnel[m]]:FUNCtion:STATe” on page 82 for information on start-
ing/stopping a data acquisition function.
NOTESee “:SENSe[n][:CHANnel[m]]:FUNCtion:RESult?” on page 81 for information on accessing
the results of a data acquisition function.
NOTESee “Triggering and Power Measurements” on page 117 for information on how triggering
affects data acquisition functions.
response:none
example:sens1:func:par:logg 64,1ms
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel is also affected.
syntax::SENSe[n][:CHANnel[m]]:FUNCtion:PARameter:LOGGing?
description:Returns the number of data points and the averaging time for the logging data acquisition
function.
parameters:none
response:Returns the number of data points as an integer value and the averaging time, t
avg
, as a
float value in seconds.
example:sens1:func:par:logg?
→ +64,+1.00000000E-001<END>
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel parameters are identical.
& Agilent 8166A Lightwave Multichannel System, Third Edition
Measurement Functions – The SENSe SubsystemMeasurement Operations & Settings
NOTESetting parameters for the MinMax function sets some parameters,
including hidden parameters, for the stability and logging functions and
vice versa. You must use the
:SENSe[n][:CHANnel[m]]:FUNCtion:PARameter:MINMax command to
set parameters before you start a MinMax function using the
:SENSe[n][:CHANnel[m]]:FUNCtion:STATe command.
description:Sets the MinMax mode and the number of data points for the
parameters:CONTinous:
NOTESee “:SENSe[n][:CHANnel[m]]:FUNCtion:STATe” on page 82 for information on start-
NOTESee “:SENSe[n][:CHANnel[m]]:FUNCtion:RESult?” on page 81 for information on accessing
NOTESee “Triggering and Power Measurements” on page 117 for information on how triggering
response:none
example:sens1:func:par:minm WIND,10
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel is also affected.
:SENSe[n][:CHANnel[m]]:FUNCtion:PARameter:MINMax
CONTinous|WINDow|REFResh,<data points>
MinMax data acquisition function.
continuous MinMax mode
WINDow:
REFResh:
Data Points is the number of samples that are recorded in the memory buffer used by the
WINDow and REFResh modes. Data Points is an integer value.
See Chapter 3 of the Agilent 8163A Lightwave Multimeter, Agilent 8164A Lightwave Measurement System, & Agilent 8166A Lightwave Multichannel System User’s Guide, for more
information on MinMax mode.
description:Returns the MinMax mode and the number of data points for the MinMax data acquisition
parameters:none
response:CONT:
example:sens1:func:par:minm?
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel parameters are identical.
The number of data points is returned as an integer value.
window MinMax mode
refresh MinMax mode
→ WIND,+10<END>
79
Measurement Operations & SettingsMeasurement Functions – The SENSe Subsystem
NOTESetting parameters for the stability function sets some parameters,
including hidden parameters, for the logging and MinMax functions and
vice versa. You must use the
:SENSe[n][:CHANnel[m]]:FUNCtion:PARameter:STABility command to
set parameters before you start a stability function using the
:SENSe[n][:CHANnel[m]]:FUNCtion:STATe command.
<total time>[NS|US|MS|S],<period time>[NS|US|MS|S],<averaging time>[NS|US|MS|S]
description:Sets the total time, period time, and averaging time for the stability data acquisition function.
parameters:Total time:
Period time:
Averaging time:
The total time from the start of stability mode until it is completed.
A new measurement is started after the completion of every period time.
A measurement is averaged over the averaging time.
Averaging Time
Period Time
Measurement Running
Measurement Stopped
12345
t
NOTEThe total time should be longer than the period time.
The period time should be longer than the averaging time.
The number of data points is equal to the total time divided by the period time.
Total time, period time, and averaging time are time values in seconds.
If you specify no units in your command, seconds are used as the default.
NOTESee “:SENSe[n][:CHANnel[m]]:FUNCtion:STATe” on page 82 for information on starting/stop-
ping a data acquisition function.
NOTESee “:SENSe[n][:CHANnel[m]]:FUNCtion:RESult?” on page 81 for information on accessing
the results of a data acquisition function.
NOTESee “Triggering and Power Measurements” on page 117 for information on how triggering
affects data acquisition functions.
response:none
example:sens1:func:par:stab 1s,0.1s,0.1s
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel is also affected.
description:Returns the data array of the last data acquisition function.
parameters:none
response:The last data acquisition function’s data array as a binary block.
description:Enables/Disables the logging, MinMax, or stability data acquisition function mode.
parameters:LOGGing:
NOTEWhen you enable a logging data acquisition function for a Agilent 8163A Series Power
NOTEStop any function before you try to set up a new function. Some parameters cannot be set
response:none
example:sens1:func:stat logg,star
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel is also affected.
:SENSe[n][:CHANnel[m]]:FUNCtion:STATe
LOGGing|STABility|MINMax,STOP|STARt
Logging data acquisition function
STABility:
MINMax:
STOP:
STARt:
Meter with averaging time of less than 100 ms with input hardware triggering disabled, all
GPIB commands will be ignored for the duration of the function.
See “:SENSe[n][:CHANnel[m]]:FUNCtion:PARameter:LOGGing” on page 78 for more infor-
mation on the logging data acquisition function.
description:Returns the function mode and the status of the data acquisition function.
parameters:none
response:NONE
example:sens1:func:stat?
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel parameters are identical.
:SENSe[n][:CHANnel[m]]:FUNCtion:STATe?
No function mode selected
LOGGING_STABILITY
MINMAX
description:Returns the start mode and the threshold value.
parameters:none
response:ABOV:
example:sens1:func:thr?
affects:All HP 8153A Lightwave Multimeter series power meters and the HP 81534A Return Loss
:SENSe[n][:CHANnel[m]]:FUNCtion:THReshold
<threshold value>[PW|NW|UW|MW|Watt|DBM]
Function starts when power is above the threshold value.
BELow:
IMMediately:
Threshold Value:
module
:SENSe[n][:CHANnel[m]]:FUNCtion:THReshold?
BEL:
IMM:
Threshold Value:
Function starts when power is below the threshold value.
Function starts immediately.
A float value in Watts or dBm.
Function starts when power is above the threshold value.
Function starts when power is below the threshold value.
Function starts immediately.
A float value in Watts or dBm.
description:Sets the averaging time for the module.
parameters:The averaging time as a float value in seconds.
response:none
example:sens1:pow:atim 1s
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel is also affected.
description:Returns the averaging time for the module.
parameters:none
response:The averaging time as a float value in seconds.
example:sens1:pow:atim?
affects:All power meters and return loss modules
dual sensors:Can only be sent to master channel, slave channel parameters are identical.
description:Returns whether automatic power ranging is being used by the module.
parameters:none
response:A boolean value:0: automatic ranging is not being used.
example:sens1:pow:rang:auto?
affects:All power meters
dual sensors:Can only be sent to master channel, slave channel parameters are identical.
:SENSe[n]:[CHANnel[m]]:POWer:RANGe:AUTO
If automatic power ranging is enabled, ranging is automatically determined by the instrument. Otherwise, it must be set by the sensn:pow:rang command.
Sets the reference value in dB used if you choose measurement relative to another channel
TOREF:
The reference as a float value.
• dB if you use TOMODule or
• Watts or dBm if you use TOREF.
reference mode using the command
“:SENSe[n]:[CHANnel[m]]:POWer:REFerence:STATe:RATio?” on page 87, the
instrument uses the last reference value entered for the selected reference mode.
Sets the reference value in Watts or dBm if you choose measurement
relative to a constant reference value
85
Measurement Operations & SettingsMeasurement Functions – The SENSe Subsystem
description:Takes the input power level value as the reference value.
parameters:none
response:none
example:sens1:pow:ref:disp
affects:All power meters
dual sensors:Master and slave channels are independent.
:SENSe[n]:[CHANnel[m]]:POWer:REFerence?
Returns the reference value in dB used if you choose measurement
relative to another channel
TOREF:
Returns the reference value in Watts or dBm if you choose measurement relative to a constant reference value
an integer value representing the slot number you want to refer255 or TOREF:
channel number:
corresponding to the slot for the first parameter and an integer value
corresponding to the channel for the second value.
If you want to use an absolute reference, use TOREF as the first parameter and
any integer value as the second parameter.
sens1:pow:ref:stat:rat TOREF,1
ence
results are displayed relative to an absolute reference
an integer value representing the channel number you want to ref-
erence
References channel 2.1
References an absolute reference
description:Returns the reference setting for the module.
parameters:none
response:results are displayed relative to an absolute reference or to the current power reading
examples:sens1:pow:ref:stat:rat?
affects:All power meters
dual sensors:Master and slave channels are independent.
description:Inquires the current sensor wavelength.
parameters:none
response:The wavelength as a float value in meters.
examplesens1:pow:wav? → +1.55000000E-006<END>
affects:All power meters and return loss modules
dual sensors:Master and slave channels are independent.
“:SENSe[n]:[CHANnel[m]]:RETurnloss:CALibration:COLLect:REFLectance” on page 89 and
“:SENSe[n]:[CHANnel[m]]:RETurnloss:CALibration:COLLect:TERMination” on page 90 for
information on calibrating your return loss module.
measurement. See “:SENSe[n]:[CHANnel[m]]:RETurnloss:CORRection:REFLectance[l]” on
page 91 for information on setting the return loss value of your reference reflector.
89
Measurement Operations & SettingsMeasurement Functions – The SENSe Subsystem
measurement. See “:SENSe[n]:[CHANnel[m]]:RETurnloss:CORRection:REFLectance[l]” on
page 91 for information on setting the return loss value of your reference reflector.
panel connector. Twice this value is added to the measured Return Loss.
laser source of a dual return loss module.
An external laser source is denoted by 0. 0 is the default value of [l].
A lower wavelength source is denoted by 1.
An upper wavelength source is denoted by 2.
front panel connector. Twice this value is added to the measured Return Loss.
length laser source of a dual return loss module.
An external laser source is denoted by 0. 0 is the default value.
A lower wavelength source is denoted by 1.
An upper wavelength source is denoted by 2.
For example, the Agilent 81000BR reference reflector provides an accurate and stable 0.18
dB reference.
upper or lower wavelength laser source of a dual return loss module.
An external laser source is denoted by 0. 0 is the default value of [l].
A lower wavelength source is denoted by 1.
An upper wavelength source is denoted by 2.
For example, the Agilent 81000BR reference reflector provides an accurate and stable 0.18
dB reference.
the upper or lower wavelength laser source of a dual return loss module.
An external laser source is denoted by 0. 0 is the default value of [l].
A lower wavelength source is denoted by 1.
An upper wavelength source is denoted by 2.
Measurement Operations & SettingsSignal Generation – The SOURce Subsystem
Signal Generation – The SOURce
Subsystem
The SOURce subsystem allows you to control a laser source module,
DFB source module, tunable laser module, or a return loss module that
has an internal source.
description:Switches the laser current off and on.
parameters:0 or OFF:
response:none
example:outp 1
affects:All laser source, DFB source, tunable laser modules and return loss modules with an inter-
:OUTPut[n][:CHANnel[m]]:PATH?
The High Power output is regulated.
LOWS:
BHR:
BLR:
The Low SSE output is regulated.
oth outputs are active but only the High Power output is Regulated.
B
oth outputs are active but only the Low SSE output is Regulated.
B
→ HIGH<END>
:OUTPut[n][:CHANnel[m]][:STATe]
The laser emits light only when the current is on. Set the state to OFF or 0 to switch the laser current off. Set the state to ON or 1 to switch the laser current on. The default is for the
laser current to be off.
switch laser current off
1 or ON:
nal source
switch laser current on
command:
syntax::OUTPut[n][:CHANnel[m]][:STATe]?
description:Returns the current state of the laser current.
parameters:none
response:A boolean value:0 – laser current off
example:outp?
affects:All laser source, DFB source, tunable laser modules and return loss modules with an inter-
MAX: maximum programmable value
DEF: This is not the preset (*RST) default value but is half the sum of,
the minimum programmable value and the maximum programmable
value
The default units are HZ, although KHZ, MHZ, GHZ, and THZ can also be specified.
The resolution of the frequency is always 1 Hz.
dual-wavelength laser source or a return loss module with an internal dual-wavelength laser source. The default value of [l] is 1, the lower wavelength source. The upper wavelength source is denoted by 2.
MAX: maximum modulation frequency
DEF: This is not the preset (*RST) default value but is half the sum of, the minimum modu-
lation frequency and the maximum modulation frequency
NOTEUse [l] to query the modulation frequency of the upper or lower wavelength laser source
of a dual-wavelength laser source or a return loss module with an internal dual-wavelength laser source. The default value of [l] is 1, the lower wavelength source. The upper
wavelength source is denoted by 2.
response:modulation frequency relevant to the current value or specified parameter (if MIN, MAX,
or DEF are chosen as a parameter).
example:sour2:am:freq? min → +2.00000000E+002<END>
All laser source, DFB source, and tunable laser modules
description:Returns the type or source of the modulation of the laser output.
parameters:0:
NOTEUse [l] to query the modulation source of the upper or lower wavelength laser source of a
response:none
example:sour2:am:sour?
affects:All laser source, DFB source, and tunable laser modules can use internal digital modula-
[:SOURce[n]][:CHANnel[m]]:AM:SOURce[l]
internal digital modulation
1, COHCtrl, or INT2:
2, AEXTernal, or EXT:
3 or DEXTernal:
4 or LFCohctrl:
5 or WVLLocking:
6 or BACKplane:
dual-wavelength laser source or a return loss module with an internal dual-wavelength laser source. The default value of [l] is 1, the lower wavelength source. The upper wavelength source is denoted by 2.
tion
All other modulation modes are only available with tunable laser modules.
[:SOURce[n]][:CHANnel[m]]:AM:SOURce[l]?
internal digital modulation
1:
2:
3:
4:
5:
6:
dual-wavelength laser source or a return loss module with an internal dual-wavelength laser source. The default value of [l] is 1, the lower wavelength source. The upper wavelength source is denoted by 2.
coherence control
external analog modulation
external digital modulation
low frequency coherence control
wavelength locking
external digital modulation using Input Trigger Connector
coherence control
external analog modulation
external digital modulation
low frequency coherence control
wavelength locking
external digital modulation using Input Trigger Connector
→ +0<END>
tion
All other modulation modes are only available with tunable laser modules.
source of a dual-wavelength laser source or a return loss module with an internal dualwavelength laser source. The default value of [l] is 1, the lower wavelength source. The
upper wavelength source is denoted by 2.
panel outputs a version of the modulating signal that has the same frequency and
phase as the modulating signal, but has a fixed, TTL-level amplitude. You can use
this to synchronize your external measuring equipment to your instrument.
To allow for your possible synchronization requirements, there are two ways in
which the signal can be output. Either the signal is combined with the laser-ready
signal, so that the output is kept low when there is no optical signal being output
(for example, while the laser is settling after a change of wavelength). Or the
modulation signal is output all the time. This is set by the :SOURCE:MODOUT
command (see “[:SOURce[n]][:CHANnel[m]]:MODout” on page 97).
“[:SOURce[n]][:CHANnel[m]]:WAVelength:SWEep:LLOGging” on page 111, and
modulation simultaneously, a sweep can not be started, see
“[:SOURce[n]][:CHANnel[m]]:WAVelength:SWEep:[STATe]” on page 115.
description:Returns the current state of modulation.
NOTEUse [l] to query the current state of modulation of the upper or lower wavelength laser
parameters:none
response:A boolean value:0: modulation is disabled
example:sour2:am:stat?
affects:All laser source, DFB source, and tunable laser modules
[:SOURce[n]][:CHANnel[m]]:AM:STATe[l]?
source of a dual-wavelength laser source or a return loss module with an internal dualwavelength laser source. The default value of [l] is 1, the lower wavelength source. The
upper wavelength source is denoted by 2.
of your Agilent 81640A/80A/82A Tunable Laser module.
modulation signal is output all the time
1:
modulation is combined with the laser-ready signal.
In this case, the output is kept low when no optical signal is output (for example, while
the laser is settling after a change of wavelength).
modulation is combined with the laser-ready signal.
In this case, the output is kept low when no optical signal is output
(for example, while the laser is settling after a change of wavelength).
description:Sets the level of attenuation.
parameters:Any value in the specified range (see the specifications in the appropriate User’s Guide).
NOTEUse [l] to set the attenuation level of the upper or lower wavelength laser source of a dual-
NOTETunable laser modules with in-built optical attenuators need to be in Manual
NOTEIn this respect, this command does not conform to the SCPI standard. The SCPI
response:none
example:sour2:pow:att 22.32db
affects:All tunable laser modules with an in-built optical attenuator, all laser source modules, and
[:SOURce[n]][:CHANnel[m]]:POWer:ATTenuation[l]
Also allowed (for
tunable laser
modules only)
are:
wavelength laser source or of a return loss module with an internal dual-wavelength laser
source. The default value of [l] is 1, the lower wavelength source. The upper wavelength
source is denoted by 2.
Attenuation Mode (see
“[:SOURce[n]][:CHANnel[m]]:POWer:ATTenuation:AUTO” on page 99) for this
value to have an affect. The output power is a combination of this value and the
laser output power (see
“[:SOURce[n]][:CHANnel[m]]:POWer[:LEVel][:IMMediate][:AMPLitude]” on
page 101).
standard requires that entering an explicit value for the attenuation switches the
attenuation mode OFF.
The default units are dB.
return loss modules with an internal source
MIN: minimum programmable value
MAX: maximum programmable value
DEF: This is not the preset (*RST) default value but is half the sum of,
the minimum programmable value and the maximum programmable value
NOTEUse [l] to query the attenuation level of the upper or lower wavelength laser source of a
parameters:Also allowed (for
response:attenuation level relevant to the current value or specified parameter (if MIN, MAX, or DEF
example:sour2:pow:att? def → +3.10000000+E001<END>
affects:All tunable laser modules with an in-built optical attenuator, all laser source modules, and
description:Selects Automatic or Manual Attenuation Mode.
[:SOURce[n]][:CHANnel[m]]:POWer:ATTenuation[l]?
When using a tunable laser module with an in-built optical attenuator, the value returned
applies only to the attenuation mode (see “[:SOURce[n]][:CHANnel[m]]:POWer:ATTenua-tion:AUTO” on page 99).
dual-wavelength laser source or of a return loss module with an internal dual-wavelength
laser source. The default value of [l] is 1, the lower wavelength source. The upper wavelength source is denoted by 2.
DEF: This is not the preset (*RST) default value but is half the sum of,
the minimum amplitude level and the maximum amplitude level
In Automatic Attenuation Mode, you specify the output power.
In Manual Attenuation Mode, you must specify both the laser output power, and the attenuation level.
parameters:OFF or 0:
ON or 1:
response:none
example:sour2:pow:att:auto 1
affects:All tunable laser modules with an in-built optical attenuator
description:Queries whether the attenuator is set to ‘dark’ position (where all light is blocked by the la-
parameters:none
response:0:1:dark position not set
example:sour2:pow:att:dark?
affects:All tunable laser modules with an in-built optical attenuator
[:SOURce[n]][:CHANnel[m]]:POWer:ATTenuation:DARK
Dark position blocks all light from the laser. You can use this as an alternative to disabling
the laser, the advantage of doing this is that you avoid the laser rise time.
This command is available in Attenuation Mode Only.