public class PointingGrabber extends AbstractRmiListener implements RmiErrorListener, Initializable
RmiErrorListener with the sole purpose
to send
status commands to the telescope and retrieve the pointing information
from the telescope out of the received TelescopeStatus status.
The proceedure is as follows:
Start the pointing model with
java stella.util.PointingModel\$Crutch [pointing.prop]The properties file contains info needed to connect to the telescope server. For a pure listening setup, you can rely on the default properties, thus starting the pointing model without any argument. Then, incomming
TelescopeStatus is parsed
for the necessary information and displayed on the screen as well as writtn
into the #KEY_POINTINGFILE in plain ascii. Once you've recorded
enough data, press exit and use the data file as input in the pointing
model. If you are brave, you can hand-edit the pointing data file and
add some errors to it, per default we write all 1s.java stella.util.PointingModel pointing.dataFeed the fitting values into pilar's classical pointing model (~observer/pilar/config/pilar.pm.prop), considering
| Modifier and Type | Class and Description |
|---|---|
static class |
PointingGrabber.Crutch
Stats the pointing grabber.
|
PropertyResources.Load, PropertyResources.URLResource| Modifier and Type | Field and Description |
|---|---|
private static DecimalFormat |
DEFDATAFORMAT
The default offset data formatter.
|
private static SimpleDateFormat |
DEFPOINTINGDATE
The key to a file containing a (long) list of all jcommands.
|
private static String |
DEFPOINTINGEXT
The key to a file containing a (long) list of all jcommands.
|
private static String |
DEFPOINTINGHEAD
The key to a file containing a (long) list of all jcommands.
|
private static String |
DEFTELESCOPE
The key to the rmi-error caster to bind to, resolvable URL.
|
static String |
KEY_DATAFORMAT
The data formt how to write data.
|
static String |
KEY_POINTINGDATE
The name of the file we write pointing data into.
|
static String |
KEY_POINTINGEXT
The name of the file we write pointing data into.
|
static String |
KEY_POINTINGHEAD
The name of the file we write pointing data into.
|
static String |
KEY_TELESCOPE
The binding name of the telescope that send errors.
|
private PrintWriter |
out
The print writer that prints into a file.
|
KEY_ALIVE, KEY_EXPORTPORT, KEY_INIT, KEY_LISTENERNAME, KEY_RETRY, KEY_RETRYSLEEP, KEY_SHUTDOWNDELAYKEY_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| Constructor and Description |
|---|
PointingGrabber(Map prop)
Constructs a new pointing grabber object.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
addPointingData(String dataline)
Adds a single pointing data line to our data file.
|
protected File |
compose()
Composes the file we write data to.
|
protected boolean |
deregisterAtCaster(RmiCaster rmi,
Class single)
Deregisters at caster.
|
void |
exit()
On exit, we have to close the data file.
|
void |
init()
Register at the appropriate casters found in the various lists.
|
protected boolean |
registerAtCaster(RmiCaster rmi,
Class single)
Registers at the specified caster if the caster is one of the four
possible caster instances this class listens to.
|
void |
rmiErrorOccured(ErrorEvent ee)
The receiving edge of the error listener.
|
allBound, blockBinding, blockBinding, disconnect, getIP, getListenerName, isConnected, listenerName, releaseBinding, releaseBinding, rescanned, startBinding, startBindingcontainsRemoteProperty, getRemoteProperties, getRemoteProperty, setRemotePropertyclone, 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, setObject, setProperties, setProperty, stringProperties, toStringequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetListenerNamedisconnect, isConnecteddefaultBoolean, 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 KEY_POINTINGHEAD
public static final String KEY_POINTINGDATE
public static final String KEY_POINTINGEXT
public static final String KEY_TELESCOPE
public static final String KEY_DATAFORMAT
private static final String DEFTELESCOPE
private static final String DEFPOINTINGHEAD
private static final String DEFPOINTINGEXT
private static final SimpleDateFormat DEFPOINTINGDATE
private static final DecimalFormat DEFDATAFORMAT
private PrintWriter out
public PointingGrabber(Map prop) throws RemoteException
RemoteExceptionprotected boolean registerAtCaster(RmiCaster rmi, Class single)
registerAtCaster in class AbstractRmiListenerprotected boolean deregisterAtCaster(RmiCaster rmi, Class single)
deregisterAtCaster in class AbstractRmiListenerpublic void init()
init in interface Initializableprotected File compose()
public void rmiErrorOccured(ErrorEvent ee) throws RemoteException
rmiErrorOccured in interface RmiErrorListenerRemoteExceptionprotected void addPointingData(String dataline)
public void exit()
exit in interface ExitCleaningexit in class AbstractRmiListener