CARMA C++
|
Drive system control interface More...
import "carma/antenna/common/DriveControl.idl";
Classes | |
struct | RaDecEpoch |
Time-Tagged Ra/Dec value. More... | |
Public Types | |
enum | Aperture { OPTICAL, RADIO1MM, RADIO3MM, RADIO1CM } |
Enumerate apertures to use for selecting pointing models. More... | |
enum | AzWrapMode { ZERO, ADD, SUB } |
The azimuth drive can operate over more than a full circle, and the wrap logic dictates how the ambiguities are resolved when requesting RA/Dec positions. More... | |
enum | Position { ZENITH, SERVICE, SAFE } |
Enumerate valid fixed positions for Stow. More... | |
typedef sequence< RaDecEpoch, 3 > | RaDecTriplet |
Public Member Functions | |
void | selectAperture (in DriveControl::Aperture ap) raises (carma::util::UserException) |
void | setAntLocation (in double longitude, in double latitude, in double altitude) raises (carma::util::UserException) |
Specify the absolute antenna location Used in the computation of az and el for celestial sources. More... | |
void | setAperturePointingConstants (in DriveControl::Aperture ap, in float azOffset, in float elOffset, in float sag) raises (carma::util::UserException) |
Sets aperature pointing constants. More... | |
void | setAz (in double az, in unsigned long seq) raises (carma::util::UserException) |
Go to requested azimuth. More... | |
void | setAzel (in double az, in double el, in unsigned long seq) raises (carma::util::UserException) |
Go to requested az/el, setting the drive to horizon (azel) mode. More... | |
void | setAzMaxRate (in float azRate) raises (carma::util::UserException) |
Sets the maximum azimuth drive rate that can be requested. More... | |
void | setAzMountOffset (in double az, in unsigned long seq) raises (carma::util::UserException) |
Az mount offsets. More... | |
void | setAzOffset (in double az, in unsigned long seq) raises (carma::util::UserException) |
Az transient astronomical offsets. More... | |
void | setEl (in double el, in unsigned long seq) raises (carma::util::UserException) |
Go to requested elevation. More... | |
void | setElMaxRate (in float elRate) raises (carma::util::UserException) |
Sets the maximum elevation drive rate that can be requested. More... | |
void | setElMountOffset (in double el, in unsigned long seq) raises (carma::util::UserException) |
El mount offsets. More... | |
void | setElOffset (in double el, in unsigned long seq) raises (carma::util::UserException) |
El transient astronomical offsets. More... | |
void | setMaxRate (in float azRate, in float elRate) raises (carma::util::UserException) |
Sets the maximum drive rate that can be requested by the drive system software. More... | |
void | setMountOffset (in double az, in double el, in unsigned long seq) raises (carma::util::UserException) |
Az/El mount offsets. More... | |
void | setOffset (in double az, in double el, in unsigned long seq) raises (carma::util::UserException) |
Az/El transient astronomical offsets. More... | |
void | setSafeRange (in float azLow, in float azHigh, in float elLow, in float elHigh) raises (carma::util::UserException) |
Set the azimuth and elevation ranges within which this antenna is safe from collisions with other antennas. More... | |
void | setTiltmeterZero (in float aftForward, in float leftRight) raises (carma::util::UserException) |
Sets the zero point for the tiltmeter. More... | |
void | setTolerance (in float toleranceInArcsecs) raises (carma::util::UserException) |
void | stop () raises (carma::util::UserException) |
Stop the antenna immediately. More... | |
void | stow (in DriveControl::Position pos, in unsigned long seq) raises ( carma::util::UserException ) |
Go to a fixed position, such as vertical, safe or stow. More... | |
void | track (in string source, in RaDecTriplet positionTriplet, in DriveControl::AzWrapMode mode, in boolean overTheTop, in unsigned long seq) raises (carma::util::UserException) |
Set a new RA/Dec tracking position. More... | |
void | trackSnow () raises (carma::util::UserException) |
Starts tracking to minimize snow accumulation on dish surface. More... | |
void | trackWind () raises (carma::util::UserException) |
Starts tracking to minimize impact of heavy wind. More... | |
void | updateRaDec (in RaDecEpoch position, in DriveControl::AzWrapMode mode) raises ( carma::util::UserException ) |
Update tracking with a new time-tagged Ra/Dec position. More... | |
void | updateWeather (in float ambientTemp, in float barometricPressure, in float relativeHumidity, in float dewpointTemp, in float windSpeed, in float windDirection) raises (carma::util::UserException) |
Update weather parameters. More... | |
Drive system control interface
Quadratic interpolation is always used for equatorial coordinates, and may optionally be used for horizon coordinates. If the coefficients are updated every 800 seconds, the fastest comet, (Hyakutake), will have a position error of one arcsecond. The equatorial positions that are sent have a time tag and should be full apparent topocentric positions for the current location of the antenna, including equatorial offsets, ephemeris and proper motion, parallax, precession, nutation, polar motion, and diurnal and annual aberration. Only refraction is excluded. Horizon coordinate (azimuth and elevation) positions may also be used to point at terrestrial objects, like a pointing fiducial or transmitter. These positions will include any parallax. In all drive modes, the pointing model, aperture constants, and mount offsets are used as corrections to the encoder readings to get the actual position while the ra/dec and azel offsets are added to the requested position. The signs are such that a positive offset or model coefficient will increase the encoder reading for the affected axis.
All offsets take effect immediately, unless the drive is stopped or stowed, in which case they are just stored.
In the horizon coordinate system, azimuth is defined with zero to the north, increasing toward the east.
The drive system has an underlying construct of "drive mode" that is automatically changed by many of these commands. The drive modes are defined in the monitor system, and correspond to:
Many commands set a sequence number monitor point upon completion. These commands must also set an associated "driveSeqNumSuccess" boolean monitor point to indicate whether the command completed because of success (acquiring the position) or failure (the drive is disabled, local, etc).
Definition at line 80 of file DriveControl.idl.
Enumerate apertures to use for selecting pointing models.
Enumerator | |
---|---|
OPTICAL |
Optical telescopes. |
RADIO1MM |
Radio 1 mm. |
RADIO3MM |
Radio 3 mm. |
RADIO1CM |
Radio 1 cm. |
Definition at line 85 of file DriveControl.idl.
The azimuth drive can operate over more than a full circle, and the wrap logic dictates how the ambiguities are resolved when requesting RA/Dec positions.
The steps for converting an RA/Dec into an azimuth are:
Enumerator | |
---|---|
ZERO |
Don't add or subtract anything to the azimuth. |
ADD |
Add a turn to azimuth if result is inside physical range. |
SUB |
Subtract turn from az if result is inside physical range. |
Definition at line 118 of file DriveControl.idl.
Enumerate valid fixed positions for Stow.
Enumerator | |
---|---|
ZENITH |
Pointed toward zenith. |
SERVICE |
A predefined service position. |
SAFE |
A collision-free position - currently implemented as the safe range midpoint.
|
Definition at line 95 of file DriveControl.idl.
void carma::antenna::common::DriveControl::setAntLocation | ( | in double | longitude, |
in double | latitude, | ||
in double | altitude | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Specify the absolute antenna location Used in the computation of az and el for celestial sources.
longitude | East longitude in radians, 0 to 2pi (increasing from Greenwich toward the east) |
latitude | in radians, -pi to pi |
altitude | in meters above sea level |
void carma::antenna::common::DriveControl::setAperturePointingConstants | ( | in DriveControl::Aperture | ap, |
in float | azOffset, | ||
in float | elOffset, | ||
in float | sag | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Sets aperature pointing constants.
An aperture is a radio receiver beam or optical telescope. These constants represent a collimation error and a sag and their effect has the same sign as setOffset(). In general all apertures offsets are relative to the mount model, with the exception of the 1mm aperture for the 6m & 10m antennas which are relative to the 3mm aperture because they are in a common dewar.
aperture | |
azOffset | in arcmin, on the sky (collimation) |
elOffset | in arcmin |
sag | in arcmin. Elevation correction = sag*cosEl |
void carma::antenna::common::DriveControl::setAz | ( | in double | az, |
in unsigned long | seq | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Go to requested azimuth.
Convenience method for direct control.
az | azimuth in degrees |
seq | Sequence number inserted into monitor system upon completion Also sets antennaCommon.driveSeqNumSuccess as true/false |
void carma::antenna::common::DriveControl::setAzel | ( | in double | az, |
in double | el, | ||
in unsigned long | seq | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Go to requested az/el, setting the drive to horizon (azel) mode.
If the drive is in equatorial mode or stopped and a single axis is selected (
az | azimuth in degrees |
el | elevation in degrees |
seq | Sequence number inserted into monitor system upon completion Also sets antennaCommon.driveSeqNumSuccess as true/false |
void carma::antenna::common::DriveControl::setAzMaxRate | ( | in float | azRate | ) | |
raises | ( | carma::util::UserException | |||
) |
Sets the maximum azimuth drive rate that can be requested.
azRate | max rate in azimuth (degrees/sec). This is an "on the sky" rate, not on the encoder |
void carma::antenna::common::DriveControl::setAzMountOffset | ( | in double | az, |
in unsigned long | seq | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Az mount offsets.
az | azimuth offset on the sky (not encoder) (arcmin) |
void carma::antenna::common::DriveControl::setAzOffset | ( | in double | az, |
in unsigned long | seq | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Az transient astronomical offsets.
Previous elevation offset is reused.
az | azimuth offset on the sky (not encoder) (arcmin) |
void carma::antenna::common::DriveControl::setEl | ( | in double | el, |
in unsigned long | seq | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Go to requested elevation.
Convenience method for direct control.
el | elevation in degrees |
seq | Sequence number inserted into monitor system upon completion Also sets antennaCommon.driveSeqNumSuccess as true/false |
void carma::antenna::common::DriveControl::setElMaxRate | ( | in float | elRate | ) | |
raises | ( | carma::util::UserException | |||
) |
Sets the maximum elevation drive rate that can be requested.
elRate | max rate in elevation (degrees/sec) |
void carma::antenna::common::DriveControl::setElMountOffset | ( | in double | el, |
in unsigned long | seq | ||
) | |||
raises | ( | carma::util::UserException | |
) |
void carma::antenna::common::DriveControl::setElOffset | ( | in double | el, |
in unsigned long | seq | ||
) | |||
raises | ( | carma::util::UserException | |
) |
El transient astronomical offsets.
Previous azimuth offset is reused.
el | elevation offset (arcmin) |
void carma::antenna::common::DriveControl::setMaxRate | ( | in float | azRate, |
in float | elRate | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Sets the maximum drive rate that can be requested by the drive system software.
A temporary rate less than the full slew rate that is used to keep collidable antennas from moving too rapidly.
azRate | max rate in azimuth (degrees/sec). This is an "on the sky" rate, not on the encoder |
elRate | max rate in elevation (degrees/sec) |
void carma::antenna::common::DriveControl::setMountOffset | ( | in double | az, |
in double | el, | ||
in unsigned long | seq | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Az/El mount offsets.
Slowly varying optics offsets with respect to the mount (collimation). These are set as the result of a pointing peak-up, etc. and may change on the time-scale of hours. These are redundant with some terms of the pointing model, but are exposed to conveniently track the delta's of these terms. These offsets are used in both equatorial and horizon modes. Behaves with the same sign as the setOffset() command.
az | azimuth offset on the sky (not encoder) (arcmin) |
el | elevation offset (arcmin) |
void carma::antenna::common::DriveControl::setOffset | ( | in double | az, |
in double | el, | ||
in unsigned long | seq | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Az/El transient astronomical offsets.
Horizon offsets used for engineering or astronomy. These offsets are used in both equatorial and horizon modes, and are set to zero when a new source is selected with track(). The offset is added to the az/el from the setAzel() command or derived from the track() command.
az | azimuth offset on the sky (not encoder) (arcmin), interpreted as a collimation error |
el | elevation offset (arcmin) |
void carma::antenna::common::DriveControl::setSafeRange | ( | in float | azLow, |
in float | azHigh, | ||
in float | elLow, | ||
in float | elHigh | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Set the azimuth and elevation ranges within which this antenna is safe from collisions with other antennas.
Note: an invocation stow(SAFE) must throw an exception if valid safe ranges have not been set with this command beforehand.
azLow | - the low end of the safe azimuth range, in degrees. |
azHigh | - the high end of the safe azimuth range, in degrees. |
elLow | - the low end of the safe elevation range, in degrees. |
elHigh | - the high end of the safe elevation range, in degrees. |
void carma::antenna::common::DriveControl::setTiltmeterZero | ( | in float | aftForward, |
in float | leftRight | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Sets the zero point for the tiltmeter.
aftForward | aft/forward zero in arcmin |
leftRight | left/right zero in arcmin |
void carma::antenna::common::DriveControl::stop | ( | ) | ||
raises | ( | carma::util::UserException | ||
) |
Stop the antenna immediately.
On the OVRO antennas, this means de-energizing the drive controllers and applying the brakes. For BIMA, this means not applying any stepper motor drive pulses.
void carma::antenna::common::DriveControl::stow | ( | in DriveControl::Position | pos, |
in unsigned long | seq | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Go to a fixed position, such as vertical, safe or stow.
After the stow position is achieved, disable the drive system. The drive system will automatically be re-energized when any command is given to go to a new position. For an OVRO antenna, disabling the drives means turning off the controllers and applying the brakes. For a BIMA antenna it means not emitting stepper motor pulses.
position | The requested fixed position |
seq | Sequence number inserted into monitor system upon completion Also sets antennaCommon.driveSeqNumSuccess as true/false |
void carma::antenna::common::DriveControl::track | ( | in string | source, |
in RaDecTriplet | positionTriplet, | ||
in DriveControl::AzWrapMode | mode, | ||
in boolean | overTheTop, | ||
in unsigned long | seq | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Set a new RA/Dec tracking position.
An array of three time-tagged equatorial positions are stored and used as the basis for quadratic interpolation to obtain the current position.
Use the updateRaDec method to update RA/Dec values.
Positions are FK5 for the current epoch, with any proper motion applied. Precession, nutation, polar motion, aberration, parallax, and any equatorial offsets have also been applied. Refraction has not been applied. Automatically changes tracking mode to equatorial (ra/dec). The offsets set with setOffset are reset to zero. If the requested position is beyond the software limits then the antenna goes to the software limits and the appropriate designation is set in the monitor stream.
source | Source name for information purposes only. |
positionTriplet | Sequence of three TimeTaggedRaDec values. |
azWrapMode | azWrapMode, see AzWrapMode |
overTheTop | whether to use an elevation greater than 90 degrees. This parameter is currently ignored and is included as a placeholder in case it is needed in the future. |
seq | Sequence number inserted into monitor system upon completion Also sets antennaCommon.driveSeqNumSuccess as true/false |
void carma::antenna::common::DriveControl::trackSnow | ( | ) | ||
raises | ( | carma::util::UserException | ||
) |
Starts tracking to minimize snow accumulation on dish surface.
Implementation uses wind direction sent with the weather commands. For ovro antennas tracking is done into the wind at a 60 degree offset from the wind vector. Bima antennas track with their backs to the wind (opposite the wind vector).
void carma::antenna::common::DriveControl::trackWind | ( | ) | ||
raises | ( | carma::util::UserException | ||
) |
Starts tracking to minimize impact of heavy wind.
Ovro antennas are stowed during a wind track and bima dishes track with their backs to the wind (opposite the wind vector).
void carma::antenna::common::DriveControl::updateRaDec | ( | in RaDecEpoch | position, |
in DriveControl::AzWrapMode | mode | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Update tracking with a new time-tagged Ra/Dec position.
When a new update is received it replaces the oldest of the triplet values stored in memory. This routine is for updates only, use track to start tracking a new source or position.
TimeTaggedRaDec | New RA/Dec value and corresponding timestamp. |
void carma::antenna::common::DriveControl::updateWeather | ( | in float | ambientTemp, |
in float | barometricPressure, | ||
in float | relativeHumidity, | ||
in float | dewpointTemp, | ||
in float | windSpeed, | ||
in float | windDirection | ||
) | |||
raises | ( | carma::util::UserException | |
) |
Update weather parameters.
Used to compute refraction correction The dewpoint/relative humidity is redundant, but allows the antennas to use whichever they want.
ambientTemp | ambient temperature in Celsius (air temp at the antenna or weather station) |
barometricPressure | in millibars |
relativeHumidity | in percent (a number between 0 and 100) |
dewpointTemp | in Celsius |
windSpeed | in miles/hour |
windDirection | direction wind is coming from, in degrees, with north at 0, increasing to the east. This is not the direction that the wind vector points, but the direction that a vane would point and is the common weather definition |