TOC PREV NEXT INDEX

Put your logo here!


A - B - C - D - E - F - G - H - I - J - K - L - M - N - O - P - Q - R - S - T - U - V - W - X - Y - Z

10 REFERENCE

Only the most important man pages are described in this chapter. All man pages are available on-line.

10.1 PANELS

10.1.1 stooStartup

NAME
stooStartup - panel to configure and start instrument software


SYNOPSIS
stooStartup <instrument>


DESCRIPTION
This script starts the startup configuration panel for the
instrument and then starts the instrument software if the
START button is pressed.
When starting the instrument software stooStartup executes
the following command and terminates itself:

stooStart <instrument> -log -restart -nopopup &

The user can set several options in the startup panel
before starting the instrument software.

NOTE: If <instrument> is an SOS, stooStartup will call
stooSosStartup panel and terminate itself.
See stooSosStartup man pages for details.


Parameters:

<instrument>: Instrument identifier (e.g. XXXX, UVES, FLAMES etc.).


There is a number of configuration parameters that can be
changed from the stooStartup panel. They are located in the
sub-system groups listed below. The startup panel supports
multiple ICS's and DCS's.

Telescope (TCS):
- Available: Select if the telescope can be accessed or not.

Instrument (ICS):
- Available: Normally true.
- WS Simulation: Normally false, unless the instrument
is not available.
- User Interface: Start the ICS stand-alone panel.

Detectors (DCS):
- Available: Normally true; set to false, if the
detector should not be used.
- WS Simulation: Normally false; set to true, if the
detector hardware is not available.
- User Interface: Start the detector stand-alone panel.
- Start RTD: Start the detector RTD.

Miscelaneous:
- Start BOB: Start the BOB panel, normally true.
- Start Control Panel: Start the OS control panel.
- Start Alarm Display: Start the alarm display.
- Log Level: Set logging level, 0..5.


FILES
xxmcfgINS.cfg Instrument configuration file
xxmcfgSTART.cfg Start configuration file

Both files are in $INS_ROOT/SYSTEM/COMMON/CONFIGFILES
"xx" is the prefix of the instrument, e.g. "uv" for UVES.



EXAMPLES
stooStartup UVES Start UVES instrument software (an OS).

stooStartup FLAMES Start FLAMES instrument software (an SOS).
FLAMES instrument is an SOS consisting of
FP and GIRAFFE instruments. In this case
stooStartup panel will call stooSosStartup
and terminate itself. stooSosStartup panel provides
means of configuring individual sub-instruments
(by calling "stooStartup FP" and "stooStartup GIRAFFE"
and starting the complete FLAMES instrument software.
See stooSosStartup man pages for more details.



SEE ALSO
stooSosStartup stooStart stooStop




- - - - - -
Last change: 16/02/05-10:05


10.1.2 stooSosStartup

NAME
stooSosStartup - panel to configure and start an SOS instrument
software


SYNOPSIS
stooSosStartup <instrument>
stooStartup <instrument>


DESCRIPTION
This script starts the startup configuration panel for instruments
which have an SOS and then starts the instrument software if the
START button is pressed.
It is also automatically started by the stooStartup panel if the
instrument identifier passed to it belongs to an SOS.
See stooStartup man pages for details.

Only the sub-OS's that run in the same environment as the SOS
are shown on the panel, e.g. UVES OS is not shown on the FLAMES
startup panel.
When starting the instrument software stooSosStartup executes
the following command and terminates itself:

stooStart <instrument> -log -restart -nopopup &


NOTE: There are two ways of starting stooSosStartup panel:
1. stooStartup <SOSID> will recognize that the instrument
has an SOS and call stooSosStartup instead.
2. stooSosStartup <SOSID>

It is recommended that method 1. is used so every instrument,
regardless of having an SOS or not, is started the same way.


Parameters:

<instrument>: Instrument identifier of an SOS (e.g. FLAMES, SINFONI, etc.).


The user can set several options in the startup panel
before starting the instrument software.

For each sub-OS, a widget is created that allows to:
- Change the access to the OS. Keyword OCS.OSi.ACCESS is associated
with this check button (NORMAL/IGNORE).
- Start individual startup panels (e.g. stooStartup GIRAFFE), by
clicking on "Startup ..." button and configure their sub-systems,
e.g. ICS, DCS, etc.

Miscelaneous:
- Start BOB: Start the BOB panel, normally true.
- Start Control Panel: Start the OS control panel.
- Start Alarm Display: Start the alarm display.
- Log Level: Set logging level, 0..5.


FILES
xxmcfgINS.cfg Instrument configuration file
xxmcfgSTART.cfg Start configuration file

Both files are in $INS_ROOT/SYSTEM/COMMON/CONFIGFILES
"xx" is the prefix of the instrument, e.g. "fl" for FLAMES.



CAUTIONS
It is recommended that the following keywords are present in the
xxmcfgSTART.cfg configuration file:

- OCS.CON.LOGLEVEL # (0..5, default 0).
- OCS.OSi.ACCESS # One per each sub-OS (NORMAL/IGNORE, default NORMAL).
- START.ALARM.DEFAULT # (T/F, default F).
- START.BOB.DEFAULT # (T/F, default F).
- START.OSCTRL.DEFAULT # (T/F, default F).



EXAMPLES
stooSosStartup FLAMES Starts FLAMES startup panel.
stooStartup FLAMES Will call stooSosStartup FLAMES instead.


SEE ALSO
stooStartup stooStart stooStop




- - - - - -
Last change: 16/02/05-10:05


10.2 SCRIPTS

10.2.1 stooStart

NAME
stooStart - start VLT instrument application


SYNOPSIS
stooStart <instrument> [-log] [-nopopup] [-restart] [-loglevel <n>]
[-proc <appl>] [-panel <panel>]



DESCRIPTION
This script starts a VLT instrument application.
Refer to the specific instrument application documentation for details.

If the complete instrument or all instrument applications are started
and if the var. DISPLAY is defined, a confirmation dialog will pop up.
See examples below.

NOTE: If var. TAT_TEST is defined, there is no pop-up dialog!


Parameters:

<instrument>: Instrument identifier (e.g. XXXX, UVES, FLAMES etc.).


Options:

no option: Check that OS and its subsystems are running,
start them if necessary.
Restart default panels.
Output goes to log window if var. DISPLAY defined.
Otherwise, to the console.

-proc <name> Start the application <name>.
<name> may be the name of a subsystem
(e.g. ICS) or an OS.
To obtain a list of known applications, use e.g.:
'stooStart UVES -proc show'

-panel <name> Start the panel <name>.
To obtain a list of known panels, use e.g.:
'stooStart UVES -panel show'

Option modifiers:

-restart Restart the application.
OS and subsystems are stopped, then restarted.
Only default panels are stopped and restarted.

-log Opens a log window (if var. DISPLAY defined).
This is the default option if no other option
is given. It MUST be the first option if other
option is given.
To suppress the log window, use "-nopopup" option
or pass '-loglevel' option as the first option
to stooStart,
e.g. 'stooStart UVES -nopopup ...' or
'stooStart UVES -loglevel 1 ...'.

-loglevel <n> Set logging level, n = 0..5.
Default value: 0 (minimum logging).

-nopopup A confirmation dialog box will not pop up under
any condition.


FILES
xxmcfgINS.cfg Instrument configuration file
xxmcfgSTART.cfg Start configuration file

Both files are in $INS_ROOT/SYSTEM/COMMON/CONFIGFILES
"xx" is the prefix of the instrument, e.g. "uv" for UVES.



CAUTIONS
If var. TAT_TEST is defined, there is no pop-up dialog!



EXAMPLES
stooStart XXXX

Start XXXX instrument, loglevel set to 0.
If var. DISPLAY defined, output to log window
and pop-up confirmation dialog. Otherwise, output
to console and no pop-up confirmation dialog.


stooStart XXXX -nopopup

Start XXXX instrument, loglevel set to 0.
No pop-up confirmation dialog.
Output to console.


stooStart XXXX -log -nopopup

Start XXXX instrument, loglevel set to 0.
If var. DISPLAY defined, output to log window.
No pop-up confirmation dialog in any case.


stooStart XXXX -log -proc ICS

Start ICS application, loglevel set to 0.
If var. DISPLAY defined, output to log window.
No pop-up confirmation dialog.


stooStart XXXX -panel OS_CONTROL

Start OS control panel, loglevel set to 0.
Output to console.
No pop-up confirmation dialog.


stooStart XXXX -log -proc XXXX

Start all XXXX instrument applications (<instrument>==<appl>),
loglevel set to 0. If var. DISPLAY defined, output to log window
and pop-up confirmation dialog.


stooStart XXXX -log -nopopup -proc XXXX

Start all XXXX instrument applications (<instrument>==<appl>),
loglevel set to 0. If var. DISPLAY defined, output to log window.
No pop-up confirmation dialog.


stooStart XXXX -loglevel 2 -restart

Re-start XXXX instrument, loglevel set to 2, output to console.
No pop-up confirmation dialog.


stooStart XXXX -log -loglevel 1

Start XXXX instrument, loglevel set to 1, output to log window.
Pop-up confirmation dialog.





- - - - - -
Last change: 16/02/05-10:05


10.2.2 stooStop

NAME
stooStop - stop VLT instrument application


SYNOPSIS
stooStop <instrument> [-log] [-nopopup] [-standby] [-loglevel <n>]
[-proc <appl>] [-panel <panel>]


DESCRIPTION
This script stops a VLT instrument application.
Refer to the specific instrument application documentation for details.

If the complete instrument or all instrument applications are stopped
and if the var. DISPLAY is defined, a confirmation dialog will pop up.
See examples below.

NOTE: If var. TAT_TEST is defined, there is no pop-up dialog!


Parameters:

<instrument>: Instrument identifier (e.g. XXXX, UVES, FLAMES etc.).


Options:

no option: Place OS in state STANDBY, stop all panels
and stop OS and all subsystems.
Output goes to log window if var. DISPLAY defined.
Otherwise, to the console.

-proc <name> Stop the application <name>.
<name> may be the name of a subsystem
(e.g. ICS) or an OS.
To obtain a list of known applications, use e.g.:
'stooStop UVES -proc show'

-panel <name> Stop the panel <name>.
To obtain a list of known panels, use e.g.:
'stooStop UVES -panel show'

-standby Only place OS in state STANDBY.
Leave all panels and processes running.

Option modifiers:

-log Opens a log window (if var. DISPLAY defined).
This is the default option if no other option
is given. It MUST be the first option if other
option is given.
To suppress the log window, use "-nopopup" option
or pass '-loglevel' option as the first option
to stooStop,
e.g. 'stooStop UVES -nopopup ...' or
'stooStop UVES -loglevel 1 ...'.

-loglevel <n> Set logging level, n = 0..5.
Default value: 0 (minimum logging).

-nopopup A confirmation dialog box will not pop up under
any condition.


FILES
xxmcfgINS.cfg Instrument configuration file
xxmcfgSTART.cfg Start configuration file

Both files are in $INS_ROOT/SYSTEM/COMMON/CONFIGFILES
"xx" is the prefix of the instrument, e.g. "uv" for UVES.



CAUTIONS
If var. TAT_TEST is defined, there is no pop-up dialog!



EXAMPLES
stooStop XXXX

Stop XXXX instrument, loglevel set to 0.
If var. DISPLAY defined, output to log window
and pop-up confirmation dialog. Otherwise, output
to console and no pop-up confirmation dialog.


stooStop XXXX -nopopup

Stop XXXX instrument, loglevel set to 0.
No pop-up confirmation dialog. Output to console.


stooStop XXXX -standby

Place XXXX OS in state STANDBY, loglevel set to 0.
No pop-up confirmation dialog. Output to console.


stooStop XXXX -log -standby

Place XXXX OS in state STANDBY, loglevel set to 0.
If var. DISPLAY defined, output to log window.
No pop-up confirmation dialog.


stooStop XXXX -log -nopopup

Stop XXXX instrument, loglevel set to 0.
If var. DISPLAY defined, output to log window.
No pop-up confirmation dialog in any case.


stooStop XXXX -log -proc ICS

Stop ICS application, loglevel set to 0.
If var. DISPLAY defined, output to log window.
No pop-up confirmation dialog.


stooStop XXXX -panel OS_CONTROL

Stop OS control panel, loglevel set to 0.
Output to console.
No pop-up confirmation dialog.


stooStop XXXX -log -proc XXXX

Stop all XXXX instrument applications (<instrument>==<appl>),
loglevel set to 0. If var. DISPLAY defined, output to log window
and pop-up confirmation dialog.


stooStop XXXX -log -nopopup -proc XXXX

Stop all XXXX instrument applications (<instrument>==<appl>),
loglevel set to 0. If var. DISPLAY defined, output to log window.
No pop-up confirmation dialog.


stooStop XXXX -loglevel 2

Stop XXXX instrument, loglevel set to 2, output to console.
No pop-up confirmation dialog.


stooStop XXXX -log -loglevel 1

Stop XXXX instrument, loglevel set to 1,
If var. DISPLAY defined, output to log window and
pop-up confirmation dialog.





- - - - - -
Last change: 16/02/05-10:05


10.3 TCL CLASSES

10.3.1 stooAPPLICATION

NAME
stooAPPLICATION - start/stop an application


SYNOPSIS
stooAPPLICATION app


DESCRIPTION
stooAPPLICATION is the base class for applications
started/stopped by a main VLT application.


PUBLIC METHODS
Config <rep> <prefix>
Configure the application.

Start
Start the application.
All processes directly owned by this object are started.

Stop
Stop the application.
All processes directly owned by this object are stopped.

IsActive
Returns 1 if the application is running, 0 otherwise.
Returns 1 if all processes directly owned by this object
are active.


IsStopped
Returns 1 if no application process is running, 0 otherwise.
Returns 1 if all processes directly owned by this object
are stopped.

Standby
The application is placed in state Standby.
(default: do nothing).


SEE ALSO
stooStart stooStop




- - - - - -
Last change: 16/02/05-10:05


10.3.2 stooBASE

NAME
stooBASE - base for Tcl/Tk scripts


SYNOPSIS
stooBASE name [-dbPoint <text>]
[-infoHeader <text>]
[-infoWidget <widget>]
[-loglevel <level>]


DESCRIPTION
stooBASE contains useful methods for scripts.
Usually this class is inherited by a class containing
the actual script functionality.


PARENT
stooLOG


PUBLIC METHODS
-


PUBLIC DATA
dbPoint: point used to access OLDB data.


PROTECTED METHODS
IsWsEnvActive [<envName>]
Returns 1 if the RTAP environment is active, 0 otherwise.

AccSelect <select>
Apply an SQL SELECT instruction on the ACC database.
Return the result set.

Dialog <text>
Pop ups a dialog to show the text.

GetOptions optionList options
Reads command line options.
The accepted options are listed in optionList,
e.g.: {-proc <name> -all}, with -all a boolean.
The corresponding public class variables are set,
e.g.: configure proc "<name>", configure all 0|1.

ExecCmd <name> <execCmd>
Executes the shell command <execCmd>.
Command <execCmd> is expected to return 0. If this is
not the case, then <name> is printed. ExecCmd returns
the return status of command <execCmd>.

GetProcessId <name> [<grepFilter>]
Returns the pid of the process <name>.

DbRead <attr>
DbWrite <attr> <value>
Read/write an OLDB attribute. dbPoint is used
as the attribute name prefix.

DbWait <attr> <value> [<secs>]
Waits <secs> secs. (default: 10) for attribute
<attr> to have value <value>. Returns 1 if
<attr> equal <value>, 0 otherwise.

SendCommand <env> <proc> <cmd> <pars> <timeout>
MsgCall <env> <proc> <cmd> <pars> ?timeout?
Send a command and wait for all replies.
SendCommand and MsgCall are identical, except for
their return values.
MsgCall returns the last reply, while SendCommand
returns a boolean indicating if the the command
was successful or not.

Sleep <secs>
Sleep <secs> seconds. The method updates Tk
during the sleep.

Logical2Num value
Converts 'T'/'F' to 1/0.



FILES
$VLTDATA/tmp/$infoHeader.log - READ -- log file


EXAMPLES
See stooINSTRUMENT.


SEE ALSO
stooStart stooStop




- - - - - -
Last change: 16/02/05-10:05


10.3.3 stooLOG

NAME
stooLOG - log utilities


SYNOPSIS
stooLOG name [-infoHeader <text>]
[-infoWidget <widget>]
[-loglevel <level>]


DESCRIPTION
stooLOG provides log utilities for scripts.


PUBLIC METHODS
SetWidget <widget>
Sets the widget where the logs should appear.


PUBLIC DATA
infoHeader: header printed by method Info.
infoWidget: widget used by method Info.
loglevel: loglevel used by method Debug.


PROTECTED METHODS
Exit [<text>]
Prints the text (if supplied) and terminates the script.

Debug <text> [<level>]
Prints text using the Info method if the loglevel
is greater or equal level. The default level is 1.

Info <text>
Prints the text to stdout and to the log file.

Warning <text>
Prints the text to stdout and to the log file
and sets the public variable warning to 1.

Log <text>
Prints the text to the log file.


FILES
$VLTDATA/tmp/$infoHeader.log - READ -- log file




- - - - - -
Last change: 16/02/05-10:05


10.3.4 stooPANEL

NAME
stooPANEL - panel


SYNOPSIS
ctooPANEL name -name <name> -procName <procName>


DESCRIPTION
stooPANEL allows to start/stop a panel.


PARENT
ctooOBJ_BASE stooLOG


PUBLIC METHODS
Config <cfg> <index>
Configure a panel from a configuration file.
<cfg> should be an instance of type ctooCONFIG.
The following config. FITS keywords are expected
and stored in the public data described below:
START.PANEL<index>.NAME -> name
START.PANEL<index>.EXECMD -> execCmd
START.PANEL<index>.DESC -> desc (optional)
START.PANEL<index>.DIR -> dir (optional)
START.PANEL<index>.STOP -> stop (optional)
START.PANEL<index>.DEFAULT -> default (optional)

Start
Start a panel executing <execCmd>
A PID file $VLTDATA/tmp/<envName>.<procName>.pid is
associated to the panel.
If there is an error, then <desc> is printed along
with the error string.

Stop
Stops a panel killing the process <execName>.
If <execName> is empty, then <procName> is used to
search for the panel.
If <execName> is '-nokill', then only the pid in the
associated PID file is used to stop the panel.
If there is an error, then <desc> is printed along
with the error string.


PUBLIC DATA
name: panel name
execCmd: command to start the panel
desc: panel description (default: name)
dir: directory, where the pacel should be started
(default: current directory)
stop: stop panel before starting new one (default: 0).
default: start by default (default: 1).

The following data are provided only for special cases:
procName: part of the *.pid file (default: first word of execCmd)
envName: part of the *.pid file (default: $RTAPENV)
execName: alternative process name, used to stop the panel
grepFilter: grep filter used to find the panel to be stopped

Normally only name, execCmd and desc need to be set.


FILES
$VLTDATA/tmp/<envName>.<procName>.pid -- lock file


CAUTIONS
If optional options are used, then these must be
specified _after_ the option used as default value.
E.g. option -desc must be specified _after_ option -name.




- - - - - -
Last change: 16/02/05-10:05


10.3.5 stooPROCESS

NAME
stooPROCESS - process


SYNOPSIS
stooPROCESS name <options>


DESCRIPTION
stooPROCESS allows to start/stop processes.


PARENT
ctooOBJ_BASE stooLOG


PUBLIC METHODS
Start [<nocheck>]
Start process <name>.
<desc> is only used to print debug information.
The command <execCmd> is assumed to start the process
<procName> in the environment <envName>.
A PID file $VLTDATA/tmp/<envName>.<procName>.pid is
associated to the process. It contains the PID of the
process.

If the PID file already exists, then an error is issued.
If the PID file does not exist and a <execCmd> is supplied,
then the command is started with seq_waitTillActive.
PING commands are sent to the process until the process
is active or the default timeout (in msecs.) is reached.
If the process does not create the PID file, then the
PID file is created.
If the public variable useXterm is not 0, then the process
is executed in an xterm (for debugging). The xterm is
positioned according to the xtermPos value (1-4).

If <nocheck> is 1, then the method does not send PING
commands to the process to check if it has started
(i.e. this function does not wait, it returns
immediately). IsActive should be called to check
if the process started without problems.

Stop
Stop process <name>.
The EXIT command is sent to the process.
If the PID file $VLTDATA/tmp/<env>.<procName>.pid exists,
then a 'kill <pid>' signal is sent to the process.
The PID file is deleted.
<desc> is only used to print debug information.

IsActive [<timeout>] [<period>]
Send PING commands to process <procName> in environment
<envName> until the process answers or the timeout is
reached. The default period of the PINGs is 1 sec.
The method returns 1 if the process answers, 0 otherwise.
<desc> is only used to print debug information.

SendCommand <cmd> <pars> <timeout>
MsgCall <cmd> <pars> ?timeout?
Send a command and wait for all replies.
SendCommand and MsgCall are identical, except for
their return values.
MsgCall returns the last reply, while SendCommand
returns a boolean indicating if the the command
was successful or not.


PUBLIC DATA
name: process name
execCmd: command to start the process (default: name)
desc: process description (default: name)

procName: CCS process name (default: name)
envName: CCS environment (default: $RTAPENV)
startTimeout: timeout to wait the process to come up during
Start (default: 10000 msec).
wsSimOption: if the parent application option -wsSimulation
is true, then the wsSimOption contents is
appended to execCmd to start the process
in WS simulation (default: "").
xtermPos: xterm position (0-4)
(default: 0 = process never started in an xterm)
useXterm: start process in an xterm (if xtermPos = 1..4)
(default: 0).


FILES
$VLTDATA/tmp/<envName>.<procName>.pid -- lock file


CAUTIONS
If optional options are used, then these must be
specified _after_ the option used as default value.
E.g. option -desc must be specified _after_ option -name.




- - - - - -
Last change: 16/02/05-10:05






___oOo___



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