TOC PREV NEXT INDEX

Put your logo here!


6 REFERENCE

6.1 tplOBS

NAME
tplOBS - Observation interface class for a template.


SYNOPSIS
tplOBS obs <dbAlias>


DESCRIPTION
Observation interface for BOB templates.


PUBLIC METHODS
tplOBS <dbAlias>
dbAlias alias of the OS OLDB root point
Abort [-current]
Abort the observation.
Continue
Continue the observation.
End
End the observation.
Pause
Pause the observation.
Setup <buffer> [<expoId>]
Setup the observation.
expoId: value of the optional parameter -expoId
Default: current observation id or 0 if no active observation
SetupSubsys <subsystem> <buffer>
Forward a setup command to the specified OS subsystem
SetupKeys [<filterList>]
Return all OCS keywords except keywords present in <filterList>
SetupSave <dicList> <keyVal> <filename>
Save in the reference setup file <filename> (no extension) the contents of
<keyVal> ("<keyword1> <value1> .. <keywordN> <valueN>").
Keywords are checked against all dictionaries defined in <dicList>
and must be registered for class Setup
Library slxtcl is used and must therefore be linked
SetupLookup <dicList> <key> <filename>
Look in the reference setup file <filename> (no extension) for the
keyword <key> and return its value.
Keywords are checked against all dictionaries defined in <dicList>
and must be registered for class Setup
Library slxtcl is used and must therefore be linked
AddFits <buffer> [<detId>] [<expoId>]
Add FITS keywords to image header.
detId: value of the optional parameter -detId
expoId: value of the optional parameter -expoId
Default: current observation id
Start [<detId>] [<expoId>]
Start the observation.
detId: value of the optional parameter -detId
expoId: value of the optional parameter -expoId
Default: current observation id
Wait [<expoId>] [<options>]
Wait for the end of observation(s).
expoId: value of the optional parameter -expoId.
If "-all" is one of the <options>, <expoId> can have
any value (e.g. 0) since it is not used.
Default: current observation id
options: Optional parameter for additional options sent with WAIT command.
They correspond one-to-one to the boss WAIT command parameters.
If "-all" is one of the options, <expoId> is not used.
Therefore, any value of expoId (e.g. 0) can be passed instead.
Examples:
Wait $expoId "-cond CanStartNextObs"
Wait 0 "-all"
Timeout [<newTimeout>]
Set the normal timeout and return its value
PauseTimeout [<newTimeout>]
Set the PAUSE timeout and return its value
SetupTimeout [<newTimeout>]
Set the SETUP timeout and return its value
WaitTimeout
Return the WAIT timeout.
StopLoop dcs
Stop a loop of exposures possibly running on a dcs subsystem.
StartLoop dcs [<detIdFlag>]
Start a loop of exposures directly on a dcs subsystem.
detIdFlag: if 1, add option -detId to the START command. Default 0
ExpStatus [<n>]
Return the exposure status
n: exposure, if the observation has several exposures.
1: Off
2: Inactive
3: Setup
4: Started
5: Integrating
6: Paused
7: Reading out
8: Processing
9: Transfering
10: Storing
11: Completed
12: Failed
13: Aborted
Comment
Send Comment command.
ImgName [<tplId>] [<dprType>]
Build the default value of OCS.DETi.IMGNAME from TPL.ID and DPR.TYPE
tplId: template ID. Default: value of TPL.ID
dprType: data type. Default: value of DPR.TYPE
Expose <tplId> <dcsList> <funcS> <fileS> [<nrep>] [<imgLst>] [<idFlg>] [<waitArgs>]
Perform simple exposures (sequence SETUP+START+WAIT).
tplId: template ID (see $TPL(ID))
dcsList: list of dcs objects involved in the exposure
funcS: -function parameter string for SETUP
fileS: -file parameter string for SETUP (if "", no -file specified)
nrep: how many times the exposure must be repeated (default 1)
imgLst: list of image file names to be used (default: use ImgName method)
idFlg: if 1, add option -detId to the START command. Default 0
waitArgs: arguments for wait command like -cond CanStartNextObs
ExposeDark <tplId> <dcsList> <fileS> [<nrep>] [<imgLst>] [<idFlg>] [<waitArgs>]
Perform dark exposures (sequence SETUP+START+WAIT).
tplId: template ID (see $TPL(ID))
dcsList: list of dcs objects involved in the exposure
fileS: -file parameter string for SETUP (if "", no -file specified)
nrep: how many times the exposure must be repeated (default 1)
imgLst: list of image file names to be used (default $TPL(ID).fits)
idFlg: if 1, add option -detId to the START command. Default 0
waitArgs: arguments for wait command like -cond CanStartNextObs
Integrate [<expoId>] [<setupBuffer>] [<detId>]
Perform an integration on the specified detector for the specified
observation. If a setup buffer is specified, the corresponding
setup command is sent before starting the integration.
expoId: value of the optional parameter -expoId for the command START
setupBuffer: value of the parameters string for the command SETUP
detId: value of the optional parameter -detId for the command START
ExpoId
Return current exposure identifier (expoId).
InsMode
Return current INS.MODE value.


CAUTIONS
The first command of an observation must be always Setup.
The last command of an observation must be always either
Abort or Wait.


EXAMPLES
see xxoseq module and tpl/test/tplTest.seq




- - - - - -
Last change: 13/12/05-08:54

6.2 tplDCS

NAME
tplDCS - DCS calss interface for templates.


SYNOPSIS
tplDCS dcs <dbAlias> <subsystem> [<detIndex>] [<imageScale>]


DESCRIPTION
DCS interface for BOB templates.


PUBLIC METHODS
tplDCS <dbAlias> name subsystem [<detIndex>] [<imageScale>]
dbAlias - alias of the DCS point
subsystem - name of OS subsystem for this DCS
detIndex - value of DETi index (default "" = no index)
imageScale - value returned by ImageScale (deafult -1)
SetupKeys [<filterList>]
Return all INS keywords except keywords present in <filterList>
SetupMode [<speed>]
Set the mode according to the supplied parameters.
speed = readout speed (default "" = keep it unchanged)
SetupFullFrame
Set the read-out for full frame (no window)
ExpTime [<dit>] [<ndit>]
Set the exposure time and return the corresponding FITS keywords.
dit Intergation time (default -1 = keep it unchanged)
ndit Number of integrations (default -1 = keep it unchanged)
Repeat [<nrep>]
Set the FITS keywords definiting the number of repeated exposures
nrep number of repeated exposures (default 0 = infinite loop)
Mode [<speed>]
Return the mode according to the supplied FITS keywords.
speed = readout speed (default "" = keep it unchanged)
Modes
Return a list of accepted modes (DET.READ.SPEED values).
Filename
Return the image filename.
ImageScale
Return the image scale that should be used to display
an image with MIDAS (see tplMIDAS LoadImage).
'DET'
Returns 'DETi'.
Name
Returns the detector name.
Subsystem
Returns the DCS subsystem name, as known to OS.
ExpStatus
Returns the current exposure status.
IsImageReal
Return 1 if image is read from the chip, otherwise 0
IsWsOnlyUsed
Return 1 if only the WS part of DCS is used, otherwise 0
IsLoopRunning
Return 1 if exposure loop is running, otherwise 0
IsLoopSupported
Return 1 if exposure looping is supported, otherwise 0
IsFileNameFixed
Return 1 if the image file name cannot be specified by the user, otherwise 0
Wait [<expStatus>]
Waits till the exposure status reaches the specified value (default "-reading")
Values supported: "-integrating"
"-reading"
"-transfering"
"-reading&transfering"
"-finished"
"-loop_running"


EXAMPLES
see xxoseq module


SEE ALSO
tplACE tplFIERA tplIRACE




- - - - - -
Last change: 13/12/05-08:54

6.2.1 tplACE

NAME
tplACE - ACE detector class interface for templates.


SYNOPSIS
tplACE dcs <dbAlias> <subsystem> [<detIndex>] [<imageScale>]


DESCRIPTION
ACE detector interface for BOB templates.


PARENT
tplDCS


PUBLIC METHODS
see tplDCS man page.


EXAMPLES
see xxoseq module


SEE ALSO
tplDCS tplFIERA tplMIDAS




- - - - - -
Last change: 13/12/05-08:54

6.2.2 tplFIERA

NAME
tplFIERA - FIERA detector class interface for templates.


SYNOPSIS
tplFIERA dcs <dbAlias> <subsystem> [<detIndex>] [<imageScale>]


DESCRIPTION
FIERA detector interface for BOB templates.


PARENT
tplDCS


PUBLIC METHODS
see tplDCS man page.


EXAMPLES
see xxoseq module


SEE ALSO
tplACE tplDCS tplMIDAS




- - - - - -
Last change: 13/12/05-08:54

6.2.3 tplIRACE

NAME
tplIRACE - IRACE detector class interface for templates.


SYNOPSIS
tplIRACE dcs <dbAlias> <subsystem> [<detIndex>] [<imageScale>]


DESCRIPTION
IRACE detector interface for BOB templates.


PARENT
tplDCS


PUBLIC METHODS
see tplDCS man page.


EXAMPLES
see xxoseq module


SEE ALSO
tplACE tplDCS tplMIDAS




- - - - - -
Last change: 13/12/05-08:54

6.3 tplICS

NAME
tplICS - ICS class interface for templates.


SYNOPSIS
tplICS ics <icsDbPoint> <osDbAlias> <osSubsysName> <icsProcName>


DESCRIPTION
ICS interface for BOB templates.


PUBLIC METHODS
tplICS <icsDbPoint> <osDbAlias> <osSubsysName> <icsProcName>
icsDbPoint ICS OLDB root point in the Instrument Environment
osDbAlias alias of the OS point in the Instrument Environment
osSubsysName name of ICS subsystem as known to OS
icsProcName name of the ICS WS front-end process (e.g. xxiControl)
IsUsed
Returns 1 if ICS is available, 0 otherwise.
IsLcuSimulated
Returns 1 if ICS is in LCU_SIM, 0 otherwise.
EnvName
Returns the ICS environment
ProcName
Returns the ICS process
NoInternalFlatField
Returns 1 if the instrument does not support internal
flat-fields.
SetupKeys [<filterList>]
Return all INS keywords except keywords present in <filterList>
SetupMode [<mode>]
Set and return INS.MODE
SetupLamp
Setup and return the FITS keyword indicating the lamp on.


EXAMPLES
see xxoseq module




- - - - - -
Last change: 13/12/05-08:54

6.4 tplTCS

NAME
tplTCS - TCS class interface for templates.


SYNOPSIS
tplTCS tcs <tcsDbAlias> <osDbAlias> <osSubsysName> <focusId> <insId>


DESCRIPTION
TCS interface for BOB templates.


PUBLIC METHODS
tplTCS <tcsDbAlias> <osDbAlias> <osSubsysName> <focusId> <insId>
tcsDbAlias alias of the TCS point in the Instrument Environment
osDbAlias alias of the OS point in the Instrument Environment
osSubsysName name of TCS subsystem as known to OS
focusId ID of focus used (e.g. "CA", "NA", "NB")
insId ID of the instrument as known to TCS
IsUsed
Returns 1 if TCS is available, 0 otherwise.
EnvName
Returns the TCS environment, e.g. 'wt1tcs'.
ProcName
Returns the TIF process, e.g. 'tifCA'.
GetFocus
Returns the focus ID
GetAdapterPos
Returns the current adapter position
GetRotatorPos
Returns the current rotator position
GetTurnTablePos
Returns the current turntable position
GetInsRotAngle
Returns the instrument rotator angle
SendFocusOffset <insMode> <detName> <offset>
Send focus offset to TCS (command OFFSFM2).
It returns as soon the command to TCS is sent.
It returns the ID of the command sent to TCS
Method Wait must be called to wait for the last reply from TCS.
SendOffsad <raOffset> <decOffset>
Send command OFFSAD to TCS.
It returns as soon the command to TCS is sent.
It returns the ID of the command sent to TCS
Method Wait must be called to wait for the last reply from TCS.
SendOffsadg <raOffset> <decOffset>
Send command OFFSADG to TCS.
It returns as soon the command to TCS is sent.
It returns the ID of the command sent to TCS
Method Wait must be called to wait for the last reply from TCS.
SendOffsfm2 <how> <offset>
Send command OFFSFM2 to TCS.
It returns as soon the command to TCS is sent.
It returns the ID of the command sent to TCS
Method Wait must be called to wait for the last reply from TCS.
SendProbeFocusOffset <how> <offset>
Send command SETFOFF to TCS.
It returns as soon the command to TCS is sent.
It returns the ID of the command sent to TCS
Method Wait must be called to wait for the last reply from TCS.
SendSeqAO <flag>
Send command SEQAO to TCS.
It returns as soon the command to TCS is sent.
It returns the ID of the command sent to TCS
Method Wait must be called to wait for the last reply from TCS.
SendStopag
Send command STOPAG to TCS.
It returns as soon the command to TCS is sent.
It returns the ID of the command sent to TCS
Method Wait must be called to wait for the last reply from TCS.
Wait [<cmdId> <time>]
Wait the reply of command (default cmdId = -1 = last command)
for <time> milliseconds (default time = 920 sec (920000 ms).
SendPark
Park the calibration unit and guide probes
It returns as soon the command to TCS is sent.
It returns the ID of the command sent to TCS
Method WaitPark must be called to wait for the last reply from TCS.
WaitPark
Wait until everything is parked.
IsAgActive [-wait]
Returns 1 if the autoguider is active, 0 otherwise.
If the -wait option is used, then ask to start
autoguiding and wait.
IsAoActive [-wait|-waitRunning]
Returns 1 if active optics is active, 0 otherwise.
If the -wait option is used, then ask to start
active optics and wait until the first analysis
has been completed.
WaitforAO
Wait for Active Optics active
CheckVignetting
Check that the adapter is not vignetting the instrument field.
Parallatic
Return parallatic.
RotOnSky
Return rotOnSky.
SetRotOffset <insMode> <detName> <offset>
Send the rotator offset to TCS
It returns as soon the command to TCS is sent.
It returns the ID of the command sent to TCS
Method Wait must be called to wait for the last reply from TCS.


EXAMPLES
see xxoseq module


BUGS
GetInsRotAngle, SendPark, SendWait are not implemented.




- - - - - -
Last change: 13/12/05-08:54

6.5 tplUIF

NAME
tplUIF - UIF class for templates.


SYNOPSIS
tplUIF uif


DESCRIPTION
UIF methods for BOB templates.


PUBLIC METHODS
Confirm <title> [<labelYes>] [<labelNo>]
Pop ups a confirmation dialog.
Returns 0 or 1.
ConfirmOrRetry <title>
Pop ups a confirmation dialog with three buttons:
Yes, No, Retry. Returns 0, 1 or 2.
GetExpTimeAndContinue <title> <raOffset> <decOffset> <expTime>
Display a dialog window to modify the exptime
and ask to quit or continue interactive pointing.
Returns a list with the continue flag and with
the new exposure time.
GetValue <title> <value>
Display a dialog window to request a value to the user.
Returns the value entered by the user.
Sleep <time> [<doLog>]
Sleep for <time> seconds, while updating the UIFs.
If doLog = 1 (default) a tplLog call is done.


EXAMPLES
see xxoseq module




- - - - - -
Last change: 13/12/05-08:54

6.6 tplDR

NAME
tplDR - Data Reduction class for templates.


SYNOPSIS
tplDR dr [<unit>] [<startFlag>]


DESCRIPTION
Data Reduction procedures for BOB templates.
This Base Class uses MIDAS


PUBLIC METHODS
tplDR [<unit>] [<startFlag>]
unit MIDAS unit to be used. Default 11
start a session, if not running yet. Default: 1 (yes)
Start
Start DR session, if not running yet
Stop
Stop DR session, if not running yet
MeanLevel <file> [<procedure>]
Return the average value of the last exposure from file <file>
<procedure> indicates which procedure is used (default tplMeanLevel)
LoadImage <file> [<scale>] [<procedure>]
Load an image, contained in <file>, in MIDAS.
<scale> = image scale (default -2)
<procedure> indicates which procedure is used (default tplLoadImage)
TFocus <file> [<procedure>] [<params>]
Run the focus batch and return the best focus value.
<procedure> indicates which procedure is used (default tplTFocus)
<params> indicates which input parameters to pass to the procedure
(default "0. 1." to match the default procedure)
IsSimulated
Return flag indicating if DR is simulated or not (see DEBUG_MIDAS)


ENVIRONMENT
DEBUG_MIDAS - if set to non-zero, then no commands are
sent to MIDAS. Only logs are printed.


EXAMPLES
see xxoseq module




- - - - - -
Last change: 13/12/05-08:54


6.7 tplFITS

NAME
tplFITS - class to access a FITS file header


SYNOPSIS
tplFITS <filename> [-dic "<dict1> ... <dictN>"]
fits Name
fits GetValue <key> [<fits_ext>]
fits AddFits <key1> <value1> ... <keyN> <valueN>
fits AddFitsCatg <catg1> ... <catgN>
fits AddComment <text>
fits Save
fits Archive


DESCRIPTION
tplFITS allows to read/write to the FITS header of a
FITS file. The file is by default searched in the
$INS_ROOT/SYSTEM/DETDATA directory.

Note that normally OS is responsible of updating the
image FITS headers, therefore this class should not
be used to update normal image files. This class is
provided to process *.fits files created by technical
procedures (non-image files).

tplFITS (constructor)
Create a tplFITS instance, reading in the FITS header
of file <filename>. The dictionaries located in
$INS_ROOT, as well as dictionaries TPL, OBS and DPR
are loaded by default. Any other dictionaries have
to be specified with the -dic option.

Name
Returns the filename.

GetValue
Returns the value of the FITS keyword <key> located
in the main FITS header. If <fits_ext> is specified,
then the keyword is searched in the corresponding
FITS header extension.

AddFits
Add/change the keywords <keyN> to <valueN>.

AddFitsCatg
Add/change all the keywords of the categories <catgN>.
The values are obtained from the Tcl array of the same
name, e.g. category OBS from $OBS(ID), $OBS(NAME), etc.
Empty array entries are ignored (i.e. no empty values
are added to the FITS header). If the category is TPL,
then the following keywords are always ignored:
TPL.INSTRUM, TPL.EXECTIME, TPL.REFSUP, TPL.TYPE.

AddComment
Add a comment to the FITS header.

Save
Save the changes to the FITS file.

Archive
Save and archive the FITS file (with sendFiles).


CAUTIONS
This class should not be used to modify normal images.
Use the OS ADDFITS command instead.


SEE ALSO
tplLogFitsDictionary




- - - - - -
Last change: 13/12/05-08:54

6.8 tpltooTsfKeySort

NAME
tpltooTsfKeySort - Sorts the keywords within *.tsf files.


SYNOPSIS
tpltooTsfKeySort <name1>.tsf [... <nameN>.tsf] [<name>.isf] [-o <dest_dir>]

<nameN>.tsf
Template signature files to be processed.

<name>.isf
Instrument signature file
(it may be used to specify the keyword order, see below).

-o <dest_dir>
Destination directory for the ordered *.tsf files.
If option -o is not used, then the input files are
overwritten.


DESCRIPTION
This utility orders the template signature file parameters
as follows (by default):

- DET1.*
- INS1.*
...
- DETn.*
- INSn.*
- DET.*
- SEQ.*
- TEL.*
- INS.*

The instrument signature file may specify a different order
with the keyword: TPL.SORT.CATEGORY, e.g.:
TPL.SORT.CATEGORY "DET2 DET1 SEQ TEL INS"

The DET.* and TEL.* keywords are by default ordered
according an internal predefined sort order;
the INS.* keywords are by default ordered alphabetically.
The instrument signature file may use the TPL.SORT.PARAMS
keyword to specify a different order, e.g.:
TPL.SORT.PARAMS "INS.ADC.MODE INS.DROT.MODE INS.FILT1.NAME
INS.SLIT1.WID INS.SLIT1.LEN INS.FILT2.NAME
INS.SLIT2.WID INS.SLIT2.LEN INS.FILT3.NAME"

It is recommended to order the INS.* keywords according
to their position within the instrument lightpath.


ENVIRONMENT
INS_ROOT - Instrument root area


CAUTIONS
If option -o is not used, then the input files are overwritten.
PAF.DESC longer than 47 chars. are truncated.


EXAMPLES
tpltooTsfKeySort UVES.isf *.tsf


SEE ALSO
tsftooObdBuild(1)




- - - - - -
Last change: 13/12/05-09:18


6.9 tpltooObdBuild

NAME
tpltooObdBuild - Build *.obd test files for corresponding *.tsf files.


SYNOPSIS
tpltoobObdBuild <name1>.tsf [... <nameN>.tsf] [<name>.isf] [-a] [-o <dest>]

<nameN>.tsf
Template signature files to be processed.
If no directory is specified, then the file is searched in:
$INS_ROOT/SYSTEM/COMMON/TEMPLATES/TSF
$INTROOT/config/INS_ROOT/SYSTEM/COMMON/TEMPLATES/TSF

If file <nameN>.obdv exists, then it is also loaded
(to retrieve specific OB keyword values, see below).

<name>.isf
Instrument signature file used to obtain parameter values
for the test observation blocks.
If no directory is specified, then the file is searched in:
$INS_ROOT/SYSTEM/COMMON/CONFIGFILES
$INTROOT/config/INS_ROOT/SYSTEM/COMMON/CONFIGFILES

-a Produce a test observation block that contains an observation
for each template signature file supplied.

-o <dest>
Destination directory for the produced *.obd files, or
if option -a is used, then the destination *.obd file.
Default directory: $INS_ROOT/SYSTEM/COMMON/TEMPLATES/OBD



DESCRIPTION
For each template signature file received as input, tpltooObdBuild
creates one observation block file (*.obd) to allow to test the
template.

If option -a is used, then an observation block to test all
templates is created.

The observation parameters are obtained from the keywords present
in the *.tsf, *.obdv or *.isf files, according to the following
precedence:

- <keyword> (searched only in the *.obdv file)
- <keyword>.VALUE
- <keyword>.TEST.VALUE
- <keyword>.DEFAULT
- If non of the above keywords are present, then the value
"NODEFAULT" is used.


ENVIRONMENT
INS_ROOT - Instrument Root Area


CAUTIONS
If the output files already exist, then they are overwritten.


EXAMPLES
tpltooObdBuild UVES.isf *.tsf -o ../config


SEE ALSO
tsftooTsfKeySort(1)




- - - - - -
Last change: 13/12/05-09:18



6.10 tpltooTsfReport

NAME
tpltooTsfReport - TSF report tool


SYNOPSIS
tpltooTsfReport -tsf <name1>.tsf [... <nameN>.tsf] [-isf <name>.isf]
[-f <html|latex|txt>] [-dir <output dir>]

<nameN>.tsf
Template signature files to be processed.

<name>.isf
Instrument signature file
(it may be used to specify the keyword order, see below).

<format>
Output format of the report. The options are html,latex and txt
being the last one the default.

<output directory>
Output directory where to store the generated report.


DESCRIPTION
Multiformat report tool that provides ascii fixed format reports
about templates signature files.



ENVIRONMENT
INS_ROOT - Instrument root area


EXAMPLES
tpltooTsfReport -tsf *.tsf -isf AMBER.isf -f latex




- - - - - -
Last change: 13/12/05-09:18




Quadralay Corporation
http://www.webworks.com
Voice: (512) 719-3399
Fax: (512) 719-3606
sales@webworks.com
TOC PREV NEXT INDEX