Writing Test Data To ROOT Tree
LABELLING THE CONNECTORS ON
THE BACK OF THE PULSER BOX:
Connectors are labelled in order
of plane number they serve (i.e. the connector serving east side of plane
65 will be connector 1 on pulser box 2, west side of plane 100 will be
connector 36 on pulser box 3); Connector 65 on a box is the SPARE, 66 is
the LOW gain PIN and 67 is the HIGH gain PIN connector. (Also see LI mapping
page.)
Writing Pulser Box test data
to Root tree
On the Linux partition of the LI
laptop, in the directory /home/root/boxes, there is a file Box.C which
contains ROOT macros for writing the test data for a single pulser box
to a tree.
-
Make a new directory for the particular
box e.g. /home/root/boxes/box2 (where the box number follows the OMC labelling)
-
Copy the test data to this directory.
Make sure the filename follows the naming convention described on the LabView
page.
-
Start root. (Just type root at the command
prompt in the directory /home/root/boxes)
-
Type ".L Box.C" to load in the macros,
then type "BoxTreeMaker(supermodule,box);" where supermodule is 1 or 2
and box is the OMC pulser box number. This makes a tree with the data just
for that pulser box.
-
Then type "AddTree(box);" where box
is OMC box number. This adds the test data for the box to another tree
in the file /home/root/boxes/pulserboxes.root which contains all the data
for all the tested boxes. When the macro is finished it will tell you to
"move the file pulserboxes_new.root to pulserboxes.root". Check that the
expected updates were made, then do this.
Other macros in the file Box.C
are for making summary plots for a single box or selction of boxes. To
make histograms:
-
Type root at the command prompt in the
directory /home/root/boxes and at the root prompt type ".L Box.C"
-
To make a file containing histograms
for a single box type "PlotMaker(box);" where box is the OMC box number.
This writes a file called e.g. /home/root/boxes/box2/histos_box2.root
-
To make a file containing histograms
for a selection of boxes type "ConcatPlots(#boxes);" where #boxes is the
number of boxes to include. The macro will then wait for you to input the
box numbers wanted (press enter between each number). This will make the
file /home/root/boxes/histos_boxes.root (n.b. PlotMaker needs
to be run on each of the boxes before ConcatPlots can be run)
Writing Fibre Bundle Test
Data to Root Tree
The directory /home/root/plncables
on the Linux partition of the LI laptop contains all the test data, as
well as a file Fibre.C which contains some root macros. The file Fibres.root
contains the tree with all the test data entered into it. To add measurements
for a fibre bundle to this tree:
-
Copy the fibre bundle test data to /home/root/plncables
-
Type root in this directory, then type
".L Fibre.C"
-
Type "Fibre(plane,side,supermodule,relbox,relcon);"
where plane is just plane number, side is either "east" or "west" (need
to include the ""), supermodule is 1 or 2, relbox is the OMC box number
of the pulser box on which the fibre bundle was tested and relcon is the
connector on that box that was used for testing (typically the spare connector
will be used, so type 65. Otherwise see the numbering convention for connectors
at the top of this page.)
-
The macro will then ask you to "move
Fibres_new.root to Fibres.root". Do this when you're happy that it worked.
If Fibres.root is ever written
over accidently with a bad version of Fibres_new.root, the macro "MakeBasicTree();"
does what it says and makes a new empty tree which will need to be re-filled
for each fibre bundle using the method above.
Of course for anybody who knows root
at all, the above is simple stuff so feel free to change anything if it'll
make life easier.
Back to main
LI installation page.