Agilent Technologies
Warn in G
WA R N I N G
Agilent Technologies Sales and Service Offices
Japan 0120 421 0120 421 678 FAX Mexico 5081
Conventions used in this Manual
Structure of this Manual
This manual is divided into 5 parts
Related Manuals
T E
Table of Contents
Signal Generation The SOURce Subsystem
Specific Command Summary
Root Layer Command
Signal Conditioning
Features of the Agilent 816x Instrument Driver
Installing the Agilent 816x Instrument Driver
Using Visual Programming Environments
Error Handling
Removed Command
Compatibility Issues
Preset Defaults
Obsolete Commands
Operational/Questionable Status System for
Agilent 8163A/B, 8164A/B & 8166A/B Mainframes, Sixth Edition
Agilent 8163A/B, 8164A/B & 8166A/B Mainframes, Sixth Edition
List of Tables
Agilent 8163A/B, 8164A/B & 8166A/B Mainframes, Sixth Edition
Introduction to Programming
Introduction to Programming
Gpib Interface
Camino del Rio South, Suite 340 San Diego, CA
Scpi Consortium Office Bode Enterprise
Mnemonic Function
Returning the Instrument to Local Control
If the instrument is in remote control, a screen resembling
Gpib Interface
Message Queues
Message Queues
How the Input Queue Works
Clearing the Input Queue
Output Queue
If more than 29 errors are put into the queue, the message
Error Queue
If no error has occurred, the error queue contains
Is placed as the last message in the queue
Programming and Syntax Diagram Conventions
Command message is ended by a line feed character LF or
Crlf
Is in long form Short form of this message is
Statusoperationenable
Short Form and Long Form
Statoperenab
Units
Command and Query Syntax
Unit Default Allowed Mnemonics
String Value Wsp
Data Types
Slot and Channel Numbers
Laser Selection Numbers
Input to your Return Loss module for the following commands
112,
Common Commands
Common Commands
Gives a summary of the common commands
Common Command Summary
Parameter Function
All bits shown as are unused Event Status Enable Mask
ESE sets the Standard Event Status Enable Mask
Common Status Information
T E
Status Model
Status Registers
Status Model
Slot Status Event
Status System for 8163A/B & 8164A/B
Slot Status Condition
Status System for 8166A/B
Standard Event Status Register
Annotations
Status Byte Register
Operation/Questionable Status Summary
Operation Slot Status Register
Operation/Questionable Status Summary Register
Operation/Questionable Slot Status
Questionable Slot Status Register
Status Model
Status Command Summary
Long
Other Commands
OPT? WAI IDN?
Introduction to Programming
Specific Commands
Command Description
Specific Command Summary
Specific Commands
WAVelengthREFerence/?
INITiatenCHANnelm
Command Description DISPlay
FETChnCHANnelmSCALar
INPUTnCHANnelm
READnCHANnelm
PATH/?
Terminals
ROUTen
SENSenCHANnelmPOWer
SENSenCHANnelmFUNCtion
SENSenCHANnelmRETurnlossCORRection
Command Description SENSenCHANnelmPOWerReference
SENSenCHANnelmRETurnlossCALibration
SLOTn
SOURcenCHANnelm
SOURcenCHANnelmPOWer
SOURcenCHANnelmPOWerATTenuationl
SOURcenCHANnelmAM
SOURcenCHANnelmWAVelengthCORRection
SOURcenCHANnelmWAVelengthREFerence
Command Description SOURcenCHANnelmWAVelengthSWEep
SOURcenCHANnelmWAVelengthSWEepSTEP
STATusOPERation
Command Description SPECial
STATusn
STATusnOPERation
SYSTem
Command Description STATusnQUEStionable
Slot n
SYSTemCOMMunicateGPIB
Specific Commands
Instrument Setup and Status
IEEE-Common Commands
Instrument Setup and Status
Standard event status register Sesr
Error queue
At power-on By sending a value of zero
Status byte register STB
ESE?
Bit Mnemonic Decimal Value
Parameters None Response Identification terminated by END
Complete, Command Idle State
Power-on
Agilent Technologies Manufacturer
Slot 1 for the Agilent 8163A/B and Agilent 8166A/B
Plete, Command Idle State
Lead to useful gains in program execution efficiency
Example OPT? → 81682A , , 81533B, 81532A, END
Error queue
Following are not changed
Bits Mnemonic
Selftest failed on Mainframe
WAI
Pending operations, are completed during the wait period
Bits Mnemonics
Status Reporting The STATus Subsystem
STATusOPERationEVENtLEVel0?
Agilent 8163A/B Agilent 8164A/B Agilent 8166A/B
Status Reporting The STATus Subsystem
STATusOPERationCONDitionLEVel0?
STATusOPERationEVENtLEVel1?
STATusOPERationENABleLEVel
STATusOPERationENABleLEVel0?
Bits Mnemonics Decimal Value Agilent 8166A/B
STATusOPERationENABleLEVel1?
STATusOPERationENABleLEVel1
Syntax STATusOPERationENABleLEVel1wspvalue Description
STATusOPERationCONDitionLEVel1?
STATus nOPERationEVENt?
Offset
Extrapolated values
STATus nOPERationCONDition?
STATusnOPERationENABle?
STATusnOPERationENABle
STATusnOPERationENABlewspvalue
STATusPRESet
Agilent 8163A/B Agilent 8164A/B
STATusQUEStionableEVENtLEVel0?
Statques? → +0END
STATusQUEStionableCONDitionLEVel0?
STATusQUEStionableENABleLEVel0?
STATusQUEStionableENABleLEVel
STATusQUEStionableEVENtLEVel1?
STATusQUEStionableCONDitionLEVel 1?
Syntax STATusQUEStionableENABleLEVel 1wspvalue Description
STATusQUEStionableENABleLEVel1?
Syntax STATusQUEStionableCONDitionLEVel 1? Description
11-15 Not Used
STATusnQUEStionableEVENt?
Syntax STATusnQUEStionableEVENt? Description
STATusnQUEStionableCONDition?
STATusnQUEStionableENABlewspvalue
STATusnQUEStionableENABle
STATusnQUEStionableENABle?
SYSTemDATE
SYSTemERRor?
SYSTemDATE?
Gpib interface state
Output and error queues
Standard Event Status Enable Mask SESEM,
Backlight and contrast of the display
SYSTemCOMMunicateGPIBSELFADDRess
SYSTemTIME?
SYSTemVERSion?
Systcommgpibaddr
Measurement Operations & Settings
Measurement Operations & Settings
Root Layer Command
LOCK?
Slot nEMPTy?
Agilent Technologies as the manufacturer
Manufacturer
Slot nIDN?
SLOTnHEADnEMPTy?
SLOTnTST?
SLOTnHEADnIDN?
SLOTnHEADmWAVelengthRESPonse?
SLOTnHEADmOPTions?
SLOTnHEADmTST?
Syntax SLOTnHEADmWAVelengthRESPonse? Description
SLOTnHEADmWAVelengthRESPonseCSV?
SPECialREBoot
SLOTnHEADmWAVelengthRESPonseSIZE?
Agilent 81635A and Agilent 81619A Master Slave Channels
Command
Measurement Functions SENSe Subsystem
Measurement Functions The SENSe Subsystem
SENSenCHANnelmPOWerUNIT/? SENSenCHANnelmPOWerWAVelength/?
FETChnCHANnelmSCAlarPOWerDC?
FETChnCHANnelmSCAlarRETurnloss?
INITiatenCHANnelmIMMediate
FETChnCHANnelmSCAlarMONitor?
INITiatenCHANnelmCONTinuous
Read nCHANnel mSCALarPOWerALL?
INITiate nCHANnel mCONTinuous?
Ber
Read nCHANnel mPOWerALLCONFig?
READnCHANnelmSCALarPOWerDC?
Member of the pair represents the channel number
READnCHANnelmSCALarMONitor?
READnCHANnelmSCALarRETurnloss?
SENSenCHANnelmCORRectionLOSSINPutMAGNitude?
SENSe nCHANnel mCORRectionLOSSINPutMAGNitude
SENSenCHANnelmCORRectionCOLLectZERO
Operation
SENSe nCHANnel mCORRectionCOLLectZERO?
SENSenCHANnelmCORRectionCOLLectZEROALL
Averaging Time
SENSenCHANnelmFUNCtionPARameterLOGGing
SENSenCHANnelmFUNCtionPARameterLOGGing?
Cont
SENSenCHANnelmFUNCtionPARameterMINMax
SENSenCHANnelmFUNCtionPARameterMINMax?
Wind
Averaging Time Period Time
SENSenCHANnelmFUNCtionPARameterSTABility
Period time
Response Example Affects Dual sensors
Sens1funcres? →
SENSenCHANnelmFUNCtionPARameterSTABility?
SENSenCHANnelmFUNCtionRESult?
Return Loss modules
SENSe nCHANnel mFUNCtionRESultBLOCk?
SENSe nCHANnel mFUNCtionRESultMAXBlocksize?
SENSenCHANnelmFUNCtionRESultMONitor?
SENSenCHANnelmFUNCtionSTATe
100
SENSenCHANnelmFUNCtionSTATe?
SENSenCHANnelmFUNCtionTHReshold
SENSenCHANnelmPOWerATIMe
101
SENSenCHANnelmFUNCtionTHReshold?
Range Upper Linear Power Limit
SENSenCHANnelmPOWerATIMe?
SENSenCHANnelmPOWerRANGeUPPer
102
103
SENSenCHANnelmPOWerRANGeUPPer?
SENSenCHANnelmPOWerRANGeMONitorUPPer
Range Upper Linear
Ment. Otherwise, it must be set by the sensnpowrang command
SENSenCHANnelmPOWerRANGeMONitorUPPer?
SENSenCHANnelmPOWerRANGeAUTO
SENSenCHANnelmPOWerRANGeAUTO?
You must append a unit type
Reference mode using the command
105
DB if you use TOMODule or
SENSenCHANnelmPOWerREFerenceSTATe?
SENSenCHANnelmPOWerREFerenceDISPlay
SENSenCHANnelmPOWerREFerenceSTATe
106
107
SENSe nCHANnel mPOWerREFerenceSTATeRATio
SENSenCHANnelmPOWerREFerenceSTATeRATio?
To the channel for the second value
SENSenCHANnelmPOWerWAVelength
SENSe nCHANnel mPOWerUNIT
SENSenCHANnelmPOWerUNIT?
108
SENSenCHANnelmRETurnlossCALibrationFACTory
SENSenCHANnelmPOWerWAVelength?
109
SENSenCHANnelmRETurnlossCALibrationFACTory
Defined termination reference measurement. See
110
SENSe nCHANnel mRETurnlossCALibrationCOLLectTERMination
SENSe nCHANnel mRETurnlossCALibrationTERMination?
SENSenCHANnelmRETurnlossCORRectionFPDeltal
111
SENSenCHANnelmRETurnlossCORRectionFPDeltal?
DB reference
112
SENSe nCHANnel mRETurnlossCORRectionREFLectance l
Lower wavelength source is denoted by
OUTPutnCHANnelmCONNection
Signal Generation The SOURce Subsystem
113
OUTPutnCHANnelmCONNection?
OUTPutnCHANnelmPATH?
114
OUTPutnCHANnelmSTATe
SOURcenCHANnelmAMINTernalFREQuencyl
115
SOURcenCHANnelmAMINTernalFREQuencyl?
Syntax SOURcenCHANnelmAMSOURcelwsp
116
SOURcenCHANnelmAMSOURcel
INTINT1INT2COHCAEXTEXTDEXTWVLLBACK012356
SOURcenCHANnelmAMSTATel?
117
SOURcenCHANnelmAMSTATel
Wavelength source is denoted by
SOURcenCHANnelmAMCOHCtrlCOHLevell?
118
SOURce nCHANnel mAMCOHCtrlCOHLevel l
SOURcenCHANnelmFMSOURcel
SOURcenCHANnelmFMSTATel
119
SOURce nCHANnel mFMSOURce l?
SOURcenCHANnelmFMSTATel?
Mhzkhzhzminmaxdef
120
SOURcenCHANnelmFMSBSCtrlFREQuencyl
SOURcenCHANnelmFMSBSCtrlFREQuencyl?
SOURcenCHANnelmMODout
121
SOURcenCHANnelmFMSBSCtrlLevell?
SOURcenCHANnelmMODout?
SOURcenCHANnelmPOWerATTenuationl?
122
SOURcenCHANnelmPOWerATTenuationlDARK
SOURcenCHANnelmPOWerATTenuationlAUTO
SOURcenCHANnelmPOWerATTenuationlAUTO?
This command is available in Attenuation Mode Only
SOURcenCHANnelmPOWerLEVelIMMediateAMPLitudel
SOURcenCHANnelmPOWerATTenuationlDARK?
124
125
SOURcenCHANnelmPOWerLEVelIMMediateAMPLitudel?
Also allowed MIN minimum amplitude level
SOURcenCHANnelmPOWerLEVelRISetimel?
SOURcenCHANnelmPOWerLEVelRISetimel
126
SOURcenCHANnelmPOWerUNIT
SOURce nCHANnel mPOWerSTATe
SOURcenCHANnelmPOWerSTATe?
SOURcenCHANnelmPOWerUNIT?
SOURcenCHANnelmPOWerWAVelength?
SOURcenCHANnelmPOWerWAVelength
128
Pmax
129
SOURce nCHANnel mREADoutDATA?
SOURce nCHANnel mREADoutDATABLOCk?
SOURcenCHANnelmREADoutPOINts?
130
SOURcenCHANnelmWAVelengthCWlFIXEDlwspvalue
SOURcenCHANnelmWAVelengthCWlFIXEDl
SOURcenCHANnelmWAVelengthCWlFIXEDl?
131
SOURcenCHANnelmWAVelengthCORRectionARA
SOURce nCHANnel mWAVelengthCORRectionAUTocalib
132
SOURce nCHANnel mWAVelengthCORRectionARAALL
81989A, 81949A
SOURce nCHANnel mWAVelengthCORRectionZERO
133
SOURcenCHANnelmWAVelengthCORRectionZEROALL
SOURcenCHANnelmWAVelengthFREQuencyl
134
SOURcenCHANnelmWAVelengthCORRectionZEROAUTO
Thzghzmhzkhzhz
SOURcenCHANnelmWAVelengthREFerencel?
135
SOURcenCHANnelmWAVelengthFREQuencyl?
SOURcenCHANnelmWAVelengthREFerenceDISPlay
SOURcenCHANnelmWAVelengthSWEepCHECkparams?
136
Message
SOURce nCHANnel mWAVelengthSWEepCYCLes
137
ValueMINMAXDEF0
SOURce nCHANnel mWAVelengthSWEepCYCLes?
SOURce nCHANnel mWAVelengthSWEepDWELl?
138
SOURce nCHANnel mWAVelengthSWEepDWELl
SOURcenCHANnelmWAVelengthSWEepEXPectedtriggers?
Sweep state
139
SOURcenCHANnelmWAVelengthSWEepFLAG?
Start Sweep waiting for trigger Trigger →
SOURcenCHANnelmWAVelengthSWEepLLOGging
Following settings are the prerequisites for Lambda Logging
140
SOURcenCHANnelmWAVelengthSWEepLLOGgingwspOFFON01
SOURcenCHANnelmWAVelengthSWEepMODE?
141
SOURcenCHANnelmWAVelengthSWEepMODE
SOURcenCHANnelmWAVelengthSWEepPMAX?
SOURcenCHANnelmWAVelengthSWEepREPeat
142
SOURcenCHANnelmWAVelengthSWEepREPeat?
SOURcenCHANnelmWAVelengthSWEepSPEed
143
SOURce nCHANnel mWAVelengthSWEepSOFTtrigger
SOURcenCHANnelmWAVelengthSWEepSPEed?
SOURcenCHANnelmWAVelengthSWEepSTARt?
144
SOURce nCHANnel mWAVelengthSWEepSTARt
SOURcenCHANnelmWAVelengthSWEepSTOP
SOURcenCHANnelmWAVelengthSWEepSTOP?
If you enable lambda logging see
145
SOURcenCHANnelmWAVelengthSWEepSTATe
SOURcenCHANnelmWAVelengthSWEepSTEPNEXT
146
SOURcenCHANnelmWAVelengthSWEepSTATe?
SOURcenCHANnelmWAVelengthSWEepSTEPPREVious
147
SOURce nCHANnel mWAVelengthSWEepSTEPWIDTh?
148
Signal Conditioning
INPut and OUTput commands
INPut nCHANnel mATTenuation
INPutnCHANnelmOFFSet?
149
INPutnCHANnelmOFFSet
INPutnCHANnelmOFFSetDISPlay
INPutnCHANnelmATTenuationSPEed
INPutnCHANnelmOFFSetPOWermeter
150
INPutnCHANnelmATTenuationSPEed?
MAX DEF
151
INPutnCHANnelmWAVelength
INPutnCHANnelmWAVelength?
152
OUTPutnCHANnelmPOWer
OUTPutnCHANnelmPOWer?
OUTPut nCHANnel mAPMode?
OUTPutnCHANnelmPOWerREFerencePOWermeter
OUTPutnCHANnelmPOWerREFerence
OUTPutnCHANnelmPOWerREFerence?
153
OUTPutnCHANnelmPOWerOFFSetPOWermeter
OUTPutnCHANnelmPOWerOFFSet
OUTPutnCHANnelmPOWerOFFSet?
154
OUTPutnCHANnelmPOWerUNit
OUTPut nCHANnel mPOWerCONTRol
OUTPutnCHANnelmPOWerCONTRol?
155
156
OUTPut nCHANnel mPOWerUNit?
OUTPutnCHANnelmSTATeAPOWeron
OUTPut nCHANnel mSTATe
OUTPutnCHANnelmATIMe
OUTPutnCHANnelmSTATeAPOWeron?
157
OUTPutnCHANnelmATIMe?
OUTPutnCHANnelmCORRectionCOLLectionZEROALL
158
OUTPCORRCOLLZER0? → 0END
Table of wavelength-dependent offsets
159
160
CONFigurenCHANnelmOFFSetWAVelengthSTATe
CONFigurenCHANnelmOFFSetWAVelengthSTATe?
CONF1OFFSWAVSTAT on
161
CONFigurenCHANnelmOFFSetWAVelengthVALue
CONFigurenCHANnelmOFFSetWAVelengthREFerence
CONF1OFFSWAVREF 4,2
CONFigurenCHANnelmOFFSetWAVelengthVALueOFFSet?
CONFigurenCHANnelmOFFSetWAVelengthREFerence?
CONFigurenCHANnelmOFFSetWAVelengthVALueWAVelength?
162
CONFigurenCHANnelmOFFSetWAVelengthVALueDELeteALL
CONFigurenCHANnelmOFFSetWAVelengthVALuePAIR?
CONFigurenCHANnelmOFFSetWAVelengthVALueDELete
163
164
CONFigurenCHANnelmOFFSetWAVelengthTABle?
CONFigurenCHANnelmOFFSetWAVelengthTABleSIZE?
CONF1OFFSWAVTABSIZE? →
Slot Numbers
When the attenuator is hosted in Slot
TIP Query the Scpi error queue using SYSTERR?
165
Command Semantic
166
Ieee Commands
Display and System Commands
167
User Calibration Data
Status Commands
168
169
Signal Routing
Switch modules
ROUTe nCHANnel m
ROUTenCHANnelmCONFigROUTe?
ROUTenCHANnelmCONFig?
Syntax ROUTenCHANnelmCONFig? Description
170
Hardware
Triggering The TRIGger Subsystem
171
Software Triggering Data Acquisition Functions Sensfuncstat
172
Generating Output Triggers from Power Measurements
DISabled An output trigger will never be generated AVGover
Software Triggering Data Acquisition Functions
173
TRIGgernCHANnelmINPut?
174
TRIGgernCHANnelmINPutREARm
TRIGgernCHANnelmOFFSet
175
TRIGger nCHANnel mINPutREARm?
TRIGgernCHANnelmOFFSet value
Return loss modules
176
TRIGger nCHANnel mOUTPut
Continuous mode, wavswestepwidt is used for triggering, see
177
Output triggers using power measurements
TRIGgerCONFiguration
TRIGger nCHANnel mOUTPutREARm
TRIGgerCONFigurationFPEDal?
TRIGgerCONFiguration?
TRIGgerCONFigurationFPEDal
178
TRIGger
Extended Trigger Configuration
179
Bit unsigned integer , see below
Extended Trigger Configuration
180
Node B Input Configuration
Node a Input Configuration
181
Output Matrix Configuration
Extended Trigger Configuration Example
Output Trigger Connector or Individual module slots
182
Trigconfext #H2,#H0,#H0 is described by -1 and sets one bit
183
Sequence starts again at and continues until the sweep ends
184
Mass Storage, Display, and Print Functions
185
186
Display Operations
DISPlay Subsystem
Display
187
DISPlayENABle
DISPlayENABle?
DISPlayBRIGhtness?
Mass Storage, Display, and Print Functions
188
DISPlayLOCKout?
Same program
Instrument using Visa library calls
189
CD-ROM 08164-90BC4
190
How to Use Visa Calls
Visa Programming Examples
How to Use Visa Calls
191
How to Set up a Fixed Laser Source
192
How to Set up a Fixed Laser Source
193
194
How to Measure Power using FETCh and Read
How to Measure Power using FETCh and Read
195
196
197
198
How to Co-ordinate Two Modules
How to Co-ordinate Two Modules
199
200
201
202
How Power Varies with Wavelength
How Power Varies with Wavelength
203
204
205
206
How to Log Results
How to Log Results
207
208
209
210
211
212
Agilent 816x VXIplug&play Instrument Driver
213
214
Agilent 816x VXIplug&play Instrument Driver
Installing the Agilent 816x Instrument Driver
215
216
217
Program Folder Item Options
Gpib Interfacing in Agilent VEE
Using Visual Programming Environments
Getting Started with Agilent VEE
218
Enter the following information Name enter hp816X
Using Visual Programming Environments
219
Select hp816X from the Plug&play Driver Name drop-down list
220
221
Getting Started with LabView
This folder contains a subfolder named instr.lib
222
FP Conversion Options Box
LabView is a trademark of National Instruments Corporation
223
Instrument Driver with LabView
Getting Started with LabWindows
224
Features of the Agilent 816x Instrument Driver
Features of the Agilent Instrument Driver
225
Directory Structure
226
Successful completion of this function returns Visuccess
Opening an Instrument Session
227
Opening an Instrument Session
Closing an Instrument Session
228
229
Visa Data Types and Selected Constant Definitions
230
Error Handling
Check for an error or event after each function
ViStatus errStatus
Error Handling
231
VISA-Specific Information
Introduction to Programming
Example Programs
Development Environments
LabWindows CVI/ R 4.0 or higher
Microsoft Visual Basic 4.0 or higher
Agilent VEE 5.01 or higher
233
234
Online Information
Latest copy of this driver can be downloaded via
235
Lambda Scan Applications
Lambda Scan Applications
Equally Spaced Datapoints
236
Prepare Lambda Scan Function
How to Perform a Lambda Scan Application
237
238
Get Lambda Scan Parameters Function
Execute Lambda Scan Function
Get Lambda Scan Parameters
Power 8163A or B
How to Perform a Multi-Frame Lambda Scan Application
8164A or B Power
239
Unregister Mainframe Function
Equally Spaced Datapoints Function
Register Mainframe Function
240
Prepare Multi Frame Lambda Scan Function
241
Get Lambda Scan Result Function
Get MF Lambda Scan Parameters Function
Execute Multi Frame Lambda Scan Function
242
243
Get Number of PWM Channels Function
Get Channel Location Function
Maximum number of channels that may be specified is
244
Error Codes
257
Gpib Error Strings
258
Program mnemonic too long
259
Suffix too long
260
Standard 200
261
New 185
New 201
Old 212
262
Old 211
Old 213
Old 221
263
Standard 222
264
265
266
267
To -499 Query Errors
268
Standard 430
269
Standard 420
Standard 440
270
Overview for Unsupported Strings
Gpib Command Compatibility List
245
Command Change Affects
Compatibility Issues
These commands are incompatible
Gpib Bus Compatibility
247
Preset defaults are different
Preset Defaults
248
Removed Command
249
Old Command New Command Affects
Obsolete Commands
250
SOURAMFREQ/?
Changed Parameter Syntax Semantics
251
Dispbrig
TST
Changed Query Result Values
252
SENSPOWUNIT?
Details the ways in which timing behavior is different
Timing Behavior
253
Change Affects
Returned Value Affects
254
FLT/DBLMAX
Command Order
Command Order
255
Instrument Status Settings
256
Index
271
272
Slot
Page
Agilent Technologies, Deutschland GmbH 08164-90B64