[evla-sw-discuss] Command line Executor
Barry Clark
bclark at aoc.nrao.edu
Wed Jun 14 17:07:33 EDT 2006
I have created a new file to replace 'newrun' which keeps getting out
of date. The file name is clexec, for command line executor. It is
intended for use by software types, and maybe on rare occasions by
electronics engineers, not by operations. The file uses the logical
links suggested by Rich Moeser, and which I undertake to keep up-to-date.
Exactly which version of the software is used is controlled by
environment variables as described below. The executable may be
found through /home/mchost/evla/bin/clexec.
It is IMPORTANT to know the limitations of running more than one Executor
at a time. First and most obvious rule - you cannot have two Executors
trying to control any given antenna at the same time. But even if the list
of antennas given to two Executors have no antennas in common, problems
may arise. The 'antenna-on-source' signal from the Modcomps will be
captured on a first come first served basis. If two Executors are
running scripts on Mchost, only the first to be started will receive this
signal, and therefore fast switching and pointing modes, which depend on
this signal, will fail for the other one. If you are just running an
executor to check for syntax errors in the script, this can be done by
running clexec on a machine other than Mchost (it has to be a Linux/Intel
machine). If run on mctest, the commands that otherwise would be sent to
the antennas will be displayed on the terminal. If it is run on the aoc
subnet, a list of vla antennas may be supplied, and their commands will be
sent to the second CMP located in the AOC.
The general usage is
clexec <database_password> <script> "<list_of_antenna_ids>"
(The older newrun program required the script name to be within the double
quotes; either form will work with clexec.)
The version of the software to be run is controlled by environment variables.
If nothing special is done, this runs the same version of the software
that the operators are running. If you say
setenv EXECVER test
you will get the nightly compiles. If you say
setenv EXECVER old
you will get the version of the software that was running before the last
update.
For testing compiled software of your own, the jar file can be explicitly
given. In my .tcshrc file I have, at the moment,
setenv EVLAOBSJAR \
/home/mchost/bclark/NRAO/EVLA/OBSERVE/target/evla-observe-0.6-SNAPSHOT.jar
which specifies that that software is loaded from my personal area. Similar
usages are provided for EVLACOMJAR, NRAOCOMJAR, and CALCLIB, for the
NRAO/EVLA/COMMONS software, NRAO/COMMONS software, and the CALC C-and-Fortran
software, respectively.
Debugging facilities are also provided by the java software, and, again,
are driven through environment variables.
setenv DEBUG
will cause sending commands to the antennas to be suppressed. Useful for
testing scripts for syntax errors.
setenv DEBUG <antenna_id>
Will cause sending commands to the antennas to be suppressed, and instead
commands that would otherwise have been sent to the MIBs on that antenna
(or the CMP) are printed to the screen.
setenv DEBUG all
Will cause sending commands to the antennas to be suppressed, and instead
commands that would otherwise have been sent to the MIBs (or the CMP) are
printed to the screen.
setenv DEBUG cmp
Will cause sending commands to the antennas to be suppressed, and instead
commands that would otherwise have been sent to the dcs00 are printed to
the screen.
For use with the test rack or hardware in the AOC, we have the following
trio of variables, all of which must be set:
DEBUGDRIVER <antenna_id whose commands are to be used for debugging>
DEBUGMODULE <which module on that antenna whose commands are to be used>
DEBUGADDRESS <address of the module to which the commands are to be sent>
Example
setenv DEBUGDRIVER ea13
setenv DEBUGMODULE l302-1
setenv DEBUGADDRESS evla-mib-108
clexec <password> Csysstart.py ea13
This will cause the L302 commands to be sent to the module whose network
address is evla-mib-108. (In this case, every ten seconds, as they would
be to an L302.)
More information about the evla-sw-discuss
mailing list