The standalone TCS
This mode is analogous to the old style of working with the telescope. As discussed earlier, we do not envisage this to be a mode in which the telescope is used on the average night.
Starting the TCS.
Log on to the wt5tcs workstation as user tcs.
A number of panels should appear automatically. One the screen marks wt5tcs:0.1 you have the Main Control Panel for the telescope. For all practical purposes you should need no other panel to operate the telescope. This panel, is a busy panel designed to be used by the operators rather than the casual user.
On the other screen, the Status Panel should also start up. This panel contains most status information necessary when running the telescope.
The TCS should be in state STANDBY with sub state IDLE or ERROR. The global interlock status of the system can be found in the status display. However, you may also view the details of the entire interlock chain using the Interlock Status Panel. The telescope is started from the main panel by clicking on "START TCS" and answering positively to the `continue?' question. The Hydraulics Panel may be started manually from the ntt guihb panel. The pressure of the hydraulics is also displayed on the Status Panel.
When closing down, the only activity necessary is to click on `STOP TCS'. The natural state of the system is either ONLINE or STANDBY. Unlike the old system the telescope should NOT be taken into the OFF state without good reason. The telescope can be in STANDBY with the hydraulics off. Switching the telescope off requires the complete initialization of all modules taken to states below STANDBY.
The NTT GUIs
The Graphical User Interfaces used in the NTT do not form part of the control system per se. Quitting the GUI does not change any part of the underlying configuration nor does it stop any action started. No direct (hooked) communication between the GUIs and the underlying tasks exists. It is therefore impossible, for example, to move the guide probe continuously while holding down some button. This functionality does not exist in the new control system.
Note that for all sub modules of the NTT Graphical User Interfaces which directly connect to these modules are present. We use the nomenclature nttguiXXX where XXX is the name of the module. So, for example, the GUI for the adapter B is called nttguiadb and can be started directly from any terminal by typing its name or, better from the vue menu.
The NTT GUIs make extensive use of the 3-state buttons. The item in GOLD is indicating the current position of the function.
By clicking on the label the action is taken and the widget will reflect the new state of the system (i.e. the blue will disappear). You may therefore preselect a number of activities to take place while waiting for some task to complete and then change the system to the new configuration.
Entry fields are passive. No action is taken when hitting the key. The actions are taken on the basis of the entered information when the appropriate button is clicked upon.
No checking is done on the GUI level on the information provided (i.e. you may enter your name instead of the Declination and the GUI will not care). Incorrect specification of, for example, co-ordinates will return an error from the prsControl module rather than from the GUI.
All NTT GUIs are built using the panel editor. The TCS GUIs live in module nttgui which resides under ~nttmgr/NTTSourceMAY97/TCS/nttgui. Modifications to the GUIs are allowed if operations staff request them. In principle, panel editor procedures are preferred to user defined (and written) libraries.
The beating heart
If the heart is beating the polling is working and the panel is alive. A stopped heart pretty much reflects a system `heart attack'. The most likely cause is an overflow of errors or that the Rtap Message queue is full - a result of ome process being dead.
On the main panel you will find the Telescope Position and foremost the `STOP' button. This is a hard stop of the telescope axes. It is only marginally softer than pushing the emergency STOP on the wall.
The STOP button takes the main axes into immediate standby and put the brakes on. This is a position from which a simple `START TCS' should allow you to recover. However, this STOP should not be used if you have entered the wrong co-ordinates. To stop the tracking we have the button `STOP TRK' in the control area of the main panel.
In the rest of the status area you find the reference position (i.e. the preset position, without proper motions or preset offsets added) and the actual position of the telescope. The calculations are performed in the same equinox system. Whatever the equinox specified in the preset (see below) the same will be reflected in the back wards calculation.
The backwards calculation is done by trkwsControl. The encoder positions are read back from the axis modules and using the pointing model the trkwsControl task converts them to the telescope RA and Dec. At times of extreme system load (for example, extremely rapid auto guiding) the synchronization of the replies from the axis modules is imperfect. In these cases trkwsControl reports 0 (zero) in the backwards calculation. This does not mean the telescope has stopped tracking!
The format is HHMMSS.S and (S)DDMMSS.S for RA and Dec respectively. For the hour angle the format is (S)HHMMSS.S. Altitude and azimuth are specified in degrees while all other angles are in radians. The focus is in mm. The seeing defaults to -1.0 when no measurements are available.
The NTT control system reads directly the La Silla site monitor information and displays it on a number of GUIs. For all the available information you may use the Meteo Monitor Panel.
The moon and weather.
The NTT TCS continuously calculates the position of the moon in topocentric apparent co-ordinates as well as, of course, in Alt and Az. This information is displayed in a variety of formats. The most obvious is the Status Display showing not only where the telescope is but also the location of the moon. It is worth noting the arrow indicating the wind direction. When the arrow is green the wind is below 9m/s. Above 9 m/s the arrow will change to dark yellow. When the arrow turns red, CLOSE! Also you should close when the little clouds with rain drops appear.
This is the main interface to the TCS from the outside. The Telescope InterFace module lives two lives. TIFNA and TIFNB one for each focus. The instruments talk to the telescope via TIF.
TIF accepts commands such as SETUP and OFFSAD (OFFset Alpha Delta). Although in theory it is possible for the instruments to issue direct commands to modules on the wt5tcs workstation, this is NOT ALLOWED. In order to protect the telescope all instructions have to go via TIF.
Before you can do much with the telescope it needs to know the state of every sub system that is needed for the specific operation in question. For example, the telescope processes may be working for presetting and tracking but insufficient resources be available for auto guiding. In this context a resource is a subsystem. For example, if the TCCDs are off then the auto guiding conditions cannot be met (this is obvious).
Therefore, before any action that relies on other subsystems takes place, the mode switching software is interrogated for the status of the subsystems. This avoids a process sending commands to a non-existent process.
Mode switching itself does not have a user interface although its results are displayed in the main TCS GUIs. On the Main Status Panel you find the Module States area. From here you can switch module states, initialize the axes etc. etc. The panel also allows you to tell mode switching to ignore a module. This, of course, is dangerous since you may choose to ignore the Altitude modules and the telescope state will still be ONLINE. All actions, such as presetting, will work but only on the axes selected.
The hydraulics is usually in the ignore state. This is a safety precaution and does not reflect on any defect in the system. Selected modules show that they are actually initialized. When you issue the INIT command (from the option menu next to the function) the system state is LOADED. However, you have to wait until the INIT appears to right of the module name before moving the system to STANDBY.
The telescope should not be started by bringing all modules into ONLINE by hand. This bypasses mode switching and as discussed earlier you may end up in a confused state unless you really know what you are doing. Once the system is in STANDBY state (independently of the sub state) the start-up should be done via the `START TCS' button on nttguiTCS.
As you can see, you can ignore certain subsystems and still have a global state of ONLINE, as is the case displayed above. Modules in blue are selected as necessary by mode switching. In this case, we are in focus A so modules on side B are in black and not required. So, although the ignore flag on those modules is not selected and they are in STANDBY the global state is ONLINE.
As mentioned earlier, this task is undertaken by the prsControl module. Presetting can be done in two ways. Either by sending a set-up file (command) to prsControl or via direct command. The set-up file configuration is used when running the system through BOB.
The PRSCOOR command has the following parameters:
alpha, delta, epochSystem, epoch, equinox, pma, pmd, radvel, parallax, coordina teType, wavelength, offsetAlpha, offsetDelta, offsetRot.
It is important to distinguish here between offsets applied at preset time and all subsequent offsets. Offsets applied during preset define a specific place on the sky. A SETUP command using an offset will result in a new preset of the telescope no matter whether the RA and Dec remain unchanged.
Any SETUP command will in fact preset the telescope as long as the target type is set to COORDINATE.
Differential offsets (cumulative) are applied to the tracking software. Offsets at tracking time differ since they do not modify the base RA and Dec of the system (i.e. the reference to which you will preset).
A number of other commands are available in the prsControl module, such as PRSALTAZ, STOPTRK,... For a preset to be activated the telescope must be in state ONLINE and substate TRACKING or IDLE.
Illegal coordinates will be reported as an error by prsControl and no action will be taken.
There is no specific GUI for the prsControl module. Direct instructions are given from the main telescope GUI. Here a good example of the difference between commands issued to prsControl and trkwsControl can be found. The additional velocity specified in the entry fields is used by both modules. If the velocity is set and the preset action is initiated then the additional velocity is sent to the axes as soon as the preset completes.
If you wish to preset and then at your leisure start differentially tracking or you wish to change the additional velocities, then the button to right of the additional velocity fields (SETAV) passes these values to tracking. However, in this case 0you should have 0 (zero) entered in the additional velocity fields when presetting.
As mentioned earlier, the actual tracking calculation and control is executed directly at the LCU level. Each LCU has both a trkServer and an axisServer task running. The trkServer tasks takes care of all refraction, pointing modelling, pre cession and offset effects before giving the required reference position to the axisServer that has the servo control loop.
trkwsControl ensures that both axes are tracking the same target. The basic command for trkwsControl is OBJSTAR which has the following parameters:
alpha, delta, epochSystem, epoch, equinox, pma, pmd, radvel, parallax, coordinateType
Offsetting the telescope is done via the tracking software (unless it is included in the preset setup file). The commands depend on the kind of offset you wish to per form. A traditional offset in RA and Dec is done via the command OFFSAD. This command can only be issued when the telescope is tracking and the offsets are cumulative. If you issue 10 consecutive OFFSAD commands without waiting for the completion of any of them the telescope will in fact offset by the total requested offset (in this case 10 times the specified offsets). This means you can click as many times as you wish on the offset buttons and the telescope will offset by the number of clicks times the specified offset. You do not have to wait for each offset to complete.
Note that it is very straightforward to set the axes tracking different targets and with differ ent pointing model parameters if one issues the objstar command directly to the LCU trk Server processes.
The same applies for the rotator offsets applied during tracking. These are cumulative also. So if you offset the rotator by +90 degrees and then apply an offset of -10 degrees you will end up at +80 degrees. Differentiate to those applied during pre setting where every time you preset the telescope with a new rotator offset you will get that absolute angle.
On the main panel you find controls which allows you to offset the telescope (note the stars move the other way).
As mentioned above offsets in RA, Dec and rotator are only allowed in sub state TRACKING.
The tracking LCUs.
As discussed elsewhere in this document the tracking LCUs are lt5az, lt5alt, lt5ra and lt5rb. On these, three critical processes run (as well as a myriad of other support processes): the axisServer (called azServer, altServer and rotServer) and the tracking Server (called aztrkServer, alttrkServer and rottrkServer).
All encoder interaction and servo loops are executed by the axisServer tasks who receive a posSetPoint from the trkServer task. Encoder calibration is also per formed by the axisServer tasks where necessary (azimuth and altitude are cali brated but the rotators need not and therefore are not).
The trkServer tasks receive the OBJSTAR command via trkwsControl (or directly if you wish to be obtuse and use ccseiMsg). The tracking is split into a background and a foreground task to handle the different time scales that are involved in produc ing a new position set point.
The background task makes corrections for polar motion correcting for the change in the true longitude and latitude of the site and other slowly changing parameters. The task typically runs every few seconds but can be started at any time if needed.
The foreground task converts the mean position (adding the additional velocities, proper motions, offsets etc etc..) to calculate the apparent position which can then be converted to a position in altitude and azimuth.
Extensive use is made of the Slalib library in the foreground task. Fundamentally, the system does not care whether the telescope is equatorial or alt-az until the con version of the RA and Dec is made to Alt-Az using the slaAopq call (Apparent to Observed) before determining the position set point.
The foreground loop runs at 50 ms intervals set by a semaphore picked up from the TIM task. A new position set point is send to the axisServer task every 50 ms. The axisServer runs a 2 ms loop. It knows both where it is and where it has to end up (the foreground task gives it the position ahead of time - 100 ms ahead).
If the axisServer does not receive a position set point for 2 seconds (i.e. 40 loops of the foreground task fail to communicate with the axisServer) then it will set itself to STANDBY and apply the brakes. The telescope is deemed to be out of control.