Agilent Technologies 86121A User Manual page 100

Wdm channel analyzer
Table of Contents

Advertisement

Example Programs 4-33
Example 3. Measure WDM channel drift
This program measures the drift of channels in a WDM
system. It measures drift in both power and wavelength
of each line. First, the program sets the WDM channel
analyzer in the continuous-acquisition measurement
mode. Then, it measures drift using commands from the
CALCulate3 subsystem.
Notice the use of the Tempo subroutine to pause the
program for 10 seconds while the WDM channel ana-
lyzer measures the drift on the system.
The use of the Err_mngmt subroutine is optional. Refer
to the introduction to this section for a description of
each subroutine that is contained in this program.
COM /Instrument/ @Mwm
ASSIGN @Mwm TO 720
DIM Key$[1]
ON ERROR GOTO Error_msg
Set_ese
PRINT USING "37A,33A";"Multi-Wavelength Meter Identity is: "
;FNIdentity$
ON TIMEOUT 7,5 CALL Err_mngmt
Cmd_opc("*RST")
Cmd_opc(":INIT:IMM")
Cmd_opc("*OPC")
Cmd_opc(":CONF:ARR:POW:WAV")
! Turn on the drift calculation
Cmd_opc(":CALC3:DRIF:STAT ON")
Err_mngmt(":CALC3:DRIF:STAT ON")
! Turn off all drift states
Cmd_opc(":CALC3:DRIF:PRES")
Err_mngmt(":CALC3:DRIF:PRES")
! Turn on drift reference state
Cmd_opc(":CALC3:DRIF:REF:STAT ON")
Err_mngmt(":CALC3:DRIF:REF:STAT ON")
! Query the number of data points
OUTPUT @Mwm;":CALC3:POIN?"
ENTER @Mwm USING "#,K";Nb_pt
ALLOCATE Current_ref_wl(1:Nb_pt)
ALLOCATE Current_ref_pwr(1:Nb_pt)
! Query reference wavelengths and powers
OUTPUT @Mwm;":CALC3:DATA? WAV"
ENTER @Mwm USING "#,K";Current_ref_wl(*)
OUTPUT @Mwm;":CALC3:DATA? POW"

Advertisement

Table of Contents
loading

Table of Contents