# This function provides the measuremeent of the peak amplitude on the spectrum analyzer
# HP8590 analyzer while sweeping the excitation frequency on the function generator.
# Alberto Stochino 2008
from optparse import OptionParser
from socket import *
## sweepfrequency.py [-f filename] [-i ip_address] [-a startFreq] [-z endFreq] [-s stepFreq] [-m numAvg]
## This script sweeps the frequency of a Marconi local oscillator, within the range
## delimited by startFreq and endFreq, with a step set by stepFreq. An arbitary
## signal is monitored on a HP8590 spectrum analyzer and the scripts records the
## amplitude of the spectrum at the frequency injected by the Marconi at the moment.
## The GPIB address of the Marconi is assumed to be 17, that of the HP Spectrum Analyzer to be 18
## Alberto Stochino, October 2008
% FP Cavity HOM Frequencies Estimate
% Alberto Stochino, October 2008
R1 = 7280; % Mirror1 radius of curvature
R2 = 57.57; % Mirror2 radius of curvature
L = 38.458; % Length of the FP Cavity
n = 1; % X Order of the Mode
m = 0; % Y Order of the Mode
c = 299792458; % Speed of Light
The first column is distance from the front face of the laser in cm.
The second column is beam diameter in the horizontal direction in microns.
The third column is the beam diameter in the vertical direction in microns.