public abstract class AuxiliaryUnit extends PropertyResources implements Guiding.RawFrame, Initializable
AdapterUnit on telescopes with an auxiliary
guiding telescope. Currently, a AuxiliaryPinholeUnit, an
AuxiliaryAcquireUnit and a AuxiliaryGuiderUnit exits.PropertyResources.Load, PropertyResources.URLResource| Modifier and Type | Field and Description |
|---|---|
static String |
COARSETYPE
Acquire frames start with this header, followed by date and count.
|
private static boolean |
DEFUSETILING
Default we use the tiler.
|
static String |
FINETYPE
Acquire frames start with this header, followed by date and count.
|
private AuxiliaryGuider |
guider
The image-processing unit.
|
static String |
GUIDERTYPE
Guiding frames start with this header, followed by date and count.
|
static String |
KEY_BINNING
The fallback unit window binning.
|
static String |
KEY_FALLBACK
The fallback unit window read-out size.
|
static String |
KEY_GUIDERTILE
The tile number to use on the guider ccd.
|
static String |
KEY_USETILING
If true and tiler is ready, we use tiling instead of centering.
|
private boolean |
manual
If true, we are in manual mode and do not generate status events.
|
private AuxiliaryMaster |
master
The master controling the auxiliary unit, used for unique & errors.
|
static String |
PINHOLETYPE
Pinhole frames start with this header, followed by date and count.
|
private OffsetCaster |
telescope
The communicator to send offset commands.
|
KEY_NOINITONCREATE, POSTFIX_ALPHABET, POSTFIX_BYTES, POSTFIX_DIR, POSTFIX_EXT, POSTFIX_FILE, POSTFIX_LIST, POSTFIX_MODTIME, POSTFIX_URLKEY_LISTSEPARATOR, KEY_MAPKEYVALUECHAR, KEY_MAPSEPARATORKEY_URLRESOURCES, KEY_URLUSECONFIG, KEY_URLUSECURRENT, KEY_URLUSEHOMECONFIG, KEY_CLASS| Modifier | Constructor and Description |
|---|---|
protected |
AuxiliaryUnit(Map<String,String> prop)
No default settings.
|
| Modifier and Type | Method and Description |
|---|---|
protected abstract ErrorEvent |
doAuxiliaryTask(String mode)
Commits the task of this unit.
|
private Guiding.RawFrame |
fromTiler(Point2D around)
This method returns the
Guiding#RawFrame this auxiliar unit is
currently focusing on. |
protected abstract String |
getAuxiliaryType()
Returns the type of this unit.
|
File |
getBiasFrame()
Returns the file holding the bias image.
|
long |
getBiasTime()
Returns the exposure time of the bias frame.
|
Dimension |
getBinning()
Returns the auxiliary binning that should be used.
|
File |
getDarkFrame()
Returns the file holding the dark image.
|
long |
getDarkTime()
Returns the exposure time of the dark frame.
|
protected abstract Point2D |
getFocusPoint()
This method returns a pixel-point on the guider-ccd that is or that is
close to the focus of interest.
|
protected AuxiliaryGuider |
getGuider()
Get the adapter helper that can be used for calculating image-realted
quantities.
|
protected AuxiliaryMaster |
getMaster()
Get the adapter helper that can be used for calculating image-realted
quantities.
|
Rectangle |
getReadoutFrame()
This method returns the
Rectangle this auxiliar unit is currently
focusing on. |
protected OffsetCaster |
getTelescope()
Get the telescope communication.
|
void |
init() |
protected boolean |
isManual()
Returns the manual status, normally inherited from the adapter master.
|
protected boolean |
isValid()
Checks if all the required quantities are set and non-null.
|
protected void |
setGuider(AuxiliaryGuider calculus)
Sets the adapter helper who knows everything image related.
|
protected void |
setManual(boolean nostatus)
Sets manual mode, in which case we should not send status event, but
rather use syslog.
|
protected void |
setMaster(AuxiliaryMaster chef)
Sets the adapter helper who knows everything image related.
|
protected void |
setTelescope(OffsetCaster sendto)
Set the telescope communication.
|
clone, createFrom, createFrom, createFrom, createInstance, getApplet, getAsResources, getLocate, getPropertiesToKey, getPropertiesToKey, getResource, getResourceAsStream, getResourceFromKey, getResources, hasLocalURLs, initProperties, keyCreate, keyCreate, reload, setAppletaugment, augment, augment, augment, augment, defaultBoolean, defaultChar, defaultDouble, defaultFloat, defaultInt, defaultLong, defaultObject, defaultObject, defaultProperties, defaultProperty, getAsBoolean, getAsChar, getAsDouble, getAsEnums, getAsFloat, getAsInt, getAsList, getAsLong, getAsMap, getAsMap, getAsObject, getAsObject, getProperties, getProperty, has, isNew, parseObject, parseObject, reload, removeProperty, requires, rescanned, setObject, setProperties, setProperty, stringProperties, toStringequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitdefaultBoolean, defaultChar, defaultDouble, defaultFloat, defaultInt, defaultLong, defaultObject, defaultObject, defaultProperties, defaultProperty, getAsBoolean, getAsChar, getAsDouble, getAsFloat, getAsInt, getAsList, getAsLong, getAsMap, getAsObject, getAsObject, getProperties, getProperty, has, parseObject, removeProperty, setObject, setProperty, stringPropertiespublic static final String COARSETYPE
public static final String FINETYPE
public static final String GUIDERTYPE
public static final String PINHOLETYPE
public static final String KEY_GUIDERTILE
public static final String KEY_USETILING
public static final String KEY_FALLBACK
public static final String KEY_BINNING
private static final boolean DEFUSETILING
private boolean manual
private OffsetCaster telescope
private AuxiliaryGuider guider
private AuxiliaryMaster master
public void init()
throws InitException
init in interface InitializableInitExceptionprotected void setManual(boolean nostatus)
protected boolean isManual()
protected void setTelescope(OffsetCaster sendto)
protected OffsetCaster getTelescope()
isValid() returns true, this
will never return null.protected void setGuider(AuxiliaryGuider calculus)
protected AuxiliaryGuider getGuider()
isValid() returns true, this will never return
null.protected void setMaster(AuxiliaryMaster chef)
protected AuxiliaryMaster getMaster()
isValid() returns true, this will never return
null.protected boolean isValid()
public Rectangle getReadoutFrame()
Rectangle this auxiliar unit is currently
focusing on. If the Guider#RawFrame is defined, we use it,
otherwise we default to a frame of size KEY_FALLBACK centered
around the rotational center.getReadoutFrame in interface Guiding.RawFramepublic Dimension getBinning()
getBinning in interface Guiding.RawFramepublic File getBiasFrame()
getBiasFrame in interface Guiding.RawFramepublic long getBiasTime()
getBiasTime in interface Guiding.RawFramepublic long getDarkTime()
getDarkTime in interface Guiding.RawFramepublic File getDarkFrame()
getDarkFrame in interface Guiding.RawFrameprivate Guiding.RawFrame fromTiler(Point2D around)
Guiding#RawFrame this auxiliar unit is
currently focusing on. It uses the value of the KEY_GUIDERTILE
plus the master's DarkTiler to return the correct frame and
binning. If the point on the ccd is null, at least the binning should be
applicable.protected abstract Point2D getFocusPoint()
protected abstract ErrorEvent doAuxiliaryTask(String mode)
mode - An integer specifying the action to be taken.protected abstract String getAuxiliaryType()