Marker Example


This example shows how to create and move Delta Markers.

Note:  In the following example:

"-p" indicates a user prompt.

"#"  indicates a comment

This example can be copied into a text editor, saved as a *.txt file, and run using the free Keysight Instrument Console program. Learn more.

 

# Preset Instrument and Hold

*RST

# Change to NA Mode and wait until changed

INST:SEL "NA";*OPC?

# Set Center Freq

SENS:FREQ:CENT 2e9

# Set Freq Span

SENS:FREQ:SPAN 500e6

# Setup the instrument to measure Insertion Loss

CALC:PAR:DEF S21

# Set to single trigger

INIT:CONT 0

# Take a single sweep at new freq and measurement

INIT:IMM;*OPC?

# Create reference marker

CALC:MARK1 NORM

# Move the marker to 1.75 GHz

CALC:MARK1:X 1.75e9

# Change to Delta Marker

CALC:MARK1 DELT

# Move the delta marker to 2.0 GHz

CALC:MARK1:X 2e9

# Take a sweep

INIT:IMM;*OPC?

# Read the Y axis values of the marker

# First value is mag, second is zero

CALC:MARK1:Y?