Help files for correlator control commands as of Jan 3, 2007.

------------------------------- freq -----------------------------
freq(frest, sb1, fif, dopplerSource, quick=False)
 -Sets the first LO frequency, placing a Doppler shifted rest frequency
    at a specific IF frequency. The IF frequency should be chosen to maximize
    receiver sensitivity or avoid image bleed through.
    After the initial setup, Doppler tracking will cause small changes
    in the IF frequency. Freq and configbands can be run in any order.
    For engineering work it is sometimes desirable to set LO1 directly;
    use frest=LO1, sb=USB or LSB, fif=0, dopplersource=None.
    For reference:
      flo1 = dopplerFactor*(frest - S1*fifrest)
      fifrest = fif/dopplerFactorIni
    where
      flo1: first LO freq
      frest: rest frequency
      fifrest : IF frequency where rest frequency is initially mapped
      S1 : LO1 sideband factor; USB=1, LSB=-1
      dopplerFactorIni: Initial doppler factor used for fifIni
    This command implements the following sequence:
     o Sets LO reference synthesizer in control building
     o Sends LO freq to correlators
     o Sends LO freq to loberotators
     o Sends Yig and Gunn freq to antennas
     o Waits for antennas to tune
     o Puts in ambient load
     o Sets antenna IF power level (PAM)
     o Sets downconverter power to preset level
     o Removes ambient load
    Parameters:
     frest: rest frequency for setup in GHz, OR, a molecular line
       name from the catalog (/opt/rt/conf/catalogs/SpectralLine.cat).
       The line name must be a string, enclosed in quotes, case insensitive.
       See the linefreq() command to get the frequency for a spectral line.
     sb1: first LO sideband for the restfreq: USB or LSB
     fif: IF freq to map rest freq to, in GHz. After initial setup, will
       vary slightly due to doppler tracking. Should be chosen to be within
       IF band of rx, taking into account Tsys performance within the IF band.
       Can also affect ability to place other lines in image sideband.
       Usually a value of 2.0 GHz is used, but can be 1.75. See web page ref
       at the end of this help.
     dopplerSource: doppler source name,
       The velocity and position of the source from the catalog are used
       to compute the doppler correction to apply to the first LO rest
       frequency. To not change the doppler source, use a source of NOCHANGE.
       To not use doppler tracking, use a doppler of None. These two names
       are special and do not require quotes.
    See also: configband, qfreq, linefreq, transitionfreq, checkbands

-------------------------------- configband -----------------------------
 configband(band, bw, frest, sb2, imagefrest='none')
 -Setup the correlator bandwidth, 2nd LO frequency and sideband
    for a spectral band. This command will block (wait) until the
    correlator hardware configuration is complete.
    The Doppler shifted frest will be placed in the center
    of the baseband (0.75GHz); the center of the image sideband will also
    be Doppler tracked (the 2nd LO is Doppler tracked). To place the line
    elsewhere in the baseband, add an offset to frest. This command should
    be issued for each band. The sideband for the specified rest frequency,
    after the Doppler shift is applied, is chosen automatically using
    the 1st LO (setup with the freq command). It is possible to choose
    parameters that will result in hardware settings that are out of range.
    Use the 'checkbands()' command after all freq and configbands have been
    issued to check if the setup is self-consistent. Freq and configbands
    can be run in any order.
    For reference:
     flo2 = S1*dopplerFactor*frest - S1*flo1 - S2*(0.75)
    where
     flo1: first LO freq
     flo2: second LO freq
     frest: rest frequency
     S1: LO1 sideband factor; USB=1, LSB=-1
     S2: LO2 sideband factor; USB=1, LSB=-1
    Parameters:
     band: band number, starting at one
     bw: bandwidth selection for the bandwidth in MHz. One of
           BW500, BW62, BW31, BW8, BW2
     frest: rest frequency for setup in GHz, OR, a molecular line
       name from the catalog (/opt/rt/conf/atalog/SpectralLine.cat).
       The line name must be a string, enclosed in quotes, case insensitive.
       See the linefreq() command to get the freq for a spectral line.
       A restfreq of 'offline' will take the band offline.
       This parameter specifies the rest frequency that will be Doppler
       tracked by the 2nd LO.
       To place bands next to each other, just offset frest by the bandwidth,
       or less if you want some overlap. If you want the line to not be
       centered in the band, just add an offset to the actual line frequency.
       This can be done programmatically with something like:
        configband(2, BW31, linefreq('myFavLine') + 0.010, LSB)
     sb2:  2nd LO downconversion sideband (USB or LSB). This sideband should
       be chosen to keep the 2nd LO in range (1.75 to 4.25 GHz).
     imagefrest: rest frequency to use in labeling image sideband. Like the
       frest parameter, a line name may be entered.
    The setup status for a band may be seen in RTD->spectralCorrelator->Setup
    See also: freq, linefreq, transitionfreq, checkbands

-------------------------------- checkbands -----------------------------
checkbands()
 -Checks that all correlator bands have valid configurations.
    Throws an exception if any band is online and has an invalid
    configuration (2nd LO out of range). See RTD=>spectralCorrelator=>Setup
    for details on individual bands.
    It is recommended that all observing scripts include this command after
    the spectral setup has been completed (all freq and configband commands
    issued).
    See also: freq, configband,  RTD=>spectralCorrelator=>Setup

-------------------------------- linefreq -----------------------------
linefreq(transition)
 -Get the frequency for a molecular line transition.
    The transitions are listed in /opt/rt/conf/catalogs/SpectralLine.cat
    as aliases near the top of the file.
    If the transition is not found an exception will be thrown
    Parameters:
     transition: a molecular line transition name, case insensitive.
         examples:   'CO', '12CO', '12CO(1-0)', 'HCN', 'C18O(1-0)'