Use of the teststand randomtest package
Intro
The software is part of the svtvme package and is mantained in the cvs
repository. It's derived from
the randomtest.c code, written by Bill to test the boards in the real
SVT crates. The code is still
compatible with Bill's version and command line parameters, but there
are new features which are
activated only if used in the teststand crate (currently tstsvt1.fnal.gov)
and if runned under the
VxWorks OS. Besides, to use the new features a command line switch
is necessary.
All the source code is still in the randomtest.c file.
To execute the test, the boards corresponding to 1/12 of the SVT have
to be installed in the
standard slots, plus an XTFA and an XTFB have to be present, to feed
the 1/12 with the XTRP
tracks ( the XTF system can be superseded through a command line switch)
. The same system
is defined in the code as SVTSIM modules and cables, so that the code
can automatically check
the TF output with the expected simulation, and if an error is present
it can dump the spy buffers content
of both the real boards and the simulated ones.
Use
Randomtest is automatically started in the teststand crate at the power-on.
The software flags
are set for a never ending loop of events, until the maximum number
of failing events is reached (1000 events,
hardwired in the code). Besides the XTF system is required. To
change the startup flags, just edit
from an online machine the file ~vxworks/boot/front-end/startup.svt-teststand
(use cdf_svt user)
and search for the code line:
rndtst = taskSpawn("randomtest",20,0x08,20000,svtvme_teststand_randomtest,0,100,41)
The final 41 is the sum of the requested bit flags.
The test writes a logfile, containing the spy buffers dumps for the
events found faulty, and also
a summary line every 10000 events, to check if the task is still alive
( or you can look at
the yellow LEDS in the real boards). The logfile is found in:
/cdf/people1/cdf_svt/vxworks/teststand_loop/teststand_logfile.txt
This file is overwritten every time the randomtest is runned. The first
lines contain the time & date
of the program start.
To stop the test, just login in the teststand crate CPU (rlogin tstsvt1
from an online linux machine,
user vxworks, password ... ) and type the command : <td rndtst>
Of course it is possible to run the test also by hand: just login in
the teststand CPU and
type the command:
svtvme_teststand_randomtest(0,100,41) or replace the parameters
as needed (see later for a
complete description)
If another set of maps is needed, you can use also the command:
svtvme_wedge_randomtest(0,"<mapset_name>",100,41)
The standard set of maps, used in the automatically runned test, is
named "teststand"
Parameters
svtvme_teststand_randomtest(wedge,nloops,flags)
wegde: from 0 to 11. The actual AMS in the crate is set for wedge 0
nloops: number of loops before stopping, used only if the never ending
loop is not selected.
flags:
bit <0> = load the boards with maps before looping
bit <1> = verbose mode
bit<2> = barrelcrossers in use or not. Used in the hits generation
bit<3> = teststand loop mode: necessary to run the test continuously
in the teststand
bit>4> = in teststand loop mode, do not stop the test even if the maximum
number of errors has been reached
bit<5> = use XTF system to feed the layer 5 tracks to the system
bit<6> = verbose dump of all spy buffers in case of error ( still
not completely inplemented)
stvme_wedge_randomtest(wedge,"<mapset_name>",nloops,flags)
This function is directly called from the previous one, which has the
mapset name hardwired to
"teststand". Each of the possible mapsets, including the one used in
the real SVT, can be used for
the teststand randomtest.