stella.jview
Class JPointingGrabber
java.lang.Object
util.PropertyContainer
util.PropertyResources
util.PropertyBundles
util.rmi.RmiPropertyContainer
util.rmi.AbstractRmiListener
stella.util.PointingGrabber
stella.jview.JPointingGrabber
- All Implemented Interfaces:
- Cloneable, Remote, EventListener, Displayable, RmiErrorListener, ExitCleaning, Initializable, LocalizedSupplying, PropertySupplying, ResourceSupplying, RmiEventListener, RmiListener, RmiPropertyBearing
public class JPointingGrabber
- extends PointingGrabber
- implements Displayable
A simple extension to a JLaunchBox 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.jview.JPointingModel\$Crutch [pointing.prop]
The properties file contains info needed to connect to the
atis server. For a pure listening setup,
you can rely on the default properties, thus starting the pointing
model without any argument. A typical window looks like this:

Then, select a star, e.g. using xephem, insert its coordinates in the PILAR
gui and slide the telescope to this position, using no offsets. You can
also use a prepared master mind to do this job for you, using a target
manager table.
Now, try to center the star using the bottle or whatever necessary in
the field of view. Once you are satisfied, press the single
STATUS_TELESCOPE button, or, if working with a special master
mind, slide the 'RequestPointing' slider to true.
A request is sent to the telescope
to tell its position. The 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.
Now, feed the data into the pointing model calculator (issue without
arguments for a description):
java stella.util.PointingModel pointing.data
Feed the fitting values into pilar's classical pointing model
(~observer/pilar/config/pilar.pm.prop), considering
- c_AN: constant to [sin(az)*tan(h)] in azimuth model and
constant to [cos(az)] in altitude model.
- c_AE: constant to [-cos(az)*tan(h)] in azimuth model and
constant to sin(az)] in altitude model. Pilar uses identical values here,
so try with the average.
- c_NPAE: constant to [tan(h)-0.5/PI] in azimuth model.
- c_BNP: constant to [-1./cos(h)-0.25] in azimuth model.
- c_AOFS: constant of the azimuth model. Note that pilar is not using
normalized coeff., so you have to account for -0.5/PI etc.
- c_EOFS: constant of the altitude model. Note that pilar is not using
normalized coeff., so you have to account for -0.5/PI etc.
- c_TF: constant to [cos(h)-0.125].
What to do if something does not work:
- Check the registry is running (issue rmiregistry on prompt before
starting the pointing model.
- Check if the atis server is running.
- Check if the pointing grabber can locate its resources. Set the
urlresources property accordingly.
- Check IP-number on port of the atis server. Note that the
pointing model has to know the IP address of the atis server and the
port it is listening. Additionally, the pointing model acts as an error
server, thus the port where it accepts connections must also be stated.
The Atis server, on the other hand, must know the IP address of the
pointing model as well as its error-erver port. Additionally, the IP
address of the tcs-computer, where Pilar is running must be known to
the ATIS server. The information the pointing model uses here is
split into two files. The command property points to a file that
contains a receiver and a port property. These is the ATIS server.
Note that binding must be enabled in the telescope client, the name
must be identical to the acknowledge, done, and error property in the
pointing grabber. The telescope client also has a property errorserver.
This points to a file that contains the serverport ATIS connects to.
- If all this is correct, and you have permission to write files
and open windows on the pointing model host, and still the thing is
not working, contact the author.
|
Method Summary |
protected void |
addPointingData(String dataline)
Adds a single pointing data line to our data file. |
Icon |
getIcon()
Might return an icon, if one was stated in the properties |
Component |
getRepresentation()
Returns a panel where the status panel and the jdisplayables are
combined. |
void |
init()
Additionally construct the data text area and open the output
file. |
| Methods inherited from class util.rmi.AbstractRmiListener |
allBound, blockBinding, blockBinding, disconnect, getIP, getListenerName, isConnected, listenerName, releaseBinding, releaseBinding, rescanned, startBinding, startBinding |
| Methods inherited from class util.PropertyResources |
createFrom, createFrom, createFrom, getApplet, getAsResources, getLocalClassLoader, getPropertiesToKey, getPropertiesToKey, getResource, getResourceAsStream, getResourceFromKey, getResources, keyCreate, keyCreate, reload, setApplet |
| Methods inherited from class util.PropertyContainer |
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, reload, removeProperty, setObject, setProperties, setProperty, stringProperties, toString |
| Methods inherited from interface util.PropertySupplying |
defaultBoolean, 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, stringProperties |
KEY_TITLE
public static final String KEY_TITLE
- The key to this launch box title. Should be related to the server.
- See Also:
- Constant Field Values
KEY_DATASIZE
public static final String KEY_DATASIZE
- The pixel size of the data sheet display.
- See Also:
- Constant Field Values
DEFTITLE
private static final String DEFTITLE
- The key to this launch box title. Should be related to the server.
- See Also:
- Constant Field Values
DEFDATASIZE
private static final Dimension DEFDATASIZE
- The default data size.
data
private JTextArea data
- A text field where I issue the pointing model data.
JPointingGrabber
public JPointingGrabber(Map prop)
throws RemoteException
- Constructs a new pointing grabber object.
- Throws:
RemoteException
init
public void init()
- Additionally construct the data text area and open the output
file. If the ouput file exists, we read in the data and display it
in the text area. New data is appended. If the file does not exist,
we write header information.
- Specified by:
init in interface Initializable- Overrides:
init in class PointingGrabber
getIcon
public Icon getIcon()
- Might return an icon, if one was stated in the properties
- Specified by:
getIcon in interface Displayable
getRepresentation
public Component getRepresentation()
- Returns a panel where the status panel and the jdisplayables are
combined. The data text area is constructed in the
init()
section.
- Specified by:
getRepresentation in interface Displayable
addPointingData
protected void addPointingData(String dataline)
- Description copied from class:
PointingGrabber
- Adds a single pointing data line to our data file.
- Overrides:
addPointingData in class PointingGrabber