Skip to content

Connecting to Keysight E4408B ESA-L by Agilent in Python

Instrument Card

E4408B ESA-L Basic Spectrum Analyzer, 9 kHz to 26.5 GHz

Keysight E4408B ESA-L

Device Specification: here

Manufacturer card: AGILENT

AGILENT

Keysight Technologies, or Keysight, is an American company that manufactures electronics test and measurement equipment and software

  • Headquarters: USA
  • Yearly Revenue (millions, USD): 5420
  • Vendor Website: here

Connect to the Keysight E4408B ESA-L in Python

PROTOCOLS > SCPI

from pymeasure.adapters import VISAAdapter
from pymeasure.instruments import AgilentE4408B
# Create a VISA adapter for the instrument
adapter = VISAAdapter("TCPIP::192.168.1.1::INSTR")
# Connect to the instrument
instrument = AgilentE4408B(adapter)
# Set the start and stop frequencies
instrument.start_frequency = 1e9 # 1 GHz
instrument.stop_frequency = 2e9 # 2 GHz
# Set the number of frequency points
instrument.frequency_points = 1001
# Set the frequency step
instrument.frequency_step = 1e6 # 1 MHz
# Set the center frequency
instrument.center_frequency = 1.5e9 # 1.5 GHz
# Set the sweep time
instrument.sweep_time = 0.1 # 100 ms
# Get the frequencies
frequencies = instrument.frequencies
# Get the trace data for trace 1
trace_data = instrument.trace(1)
# Get the trace data as a pandas DataFrame for trace 1
trace_df = instrument.trace_df(1)

This script connects to a Keysight E4408B ESA-L Spectrum Analyzer using a VISA adapter. It sets the start and stop frequencies, number of frequency points, frequency step, center frequency, and sweep time. It then retrieves the frequencies, trace data for trace 1, and trace data as a pandas DataFrame for trace 1.