How to configure an experiment in a MARaBOU environment



Contents

  1. Introduction
    1. About MARaBOU
    2. Structure of a configuration file
  2. How to define basic configuration objects
    1. The main configuration object
    2. Events and triggers
    3. Subevents
    4. Modules and parameters
  3. More configuration objects
    1. Histograms
    2. Variables
    3. Windows
  4. How to put things together
    1. Assign parameters to subevents
    2. Assign subevents to events
  5. How to add user code
  6. How to extend system code writing templates
  7. How to generate code files
  8. How to compile and link the whole thing
  9. Appendix - The MINIBALL experiment
    1. Subevents
    2. Modules
    3. Histograms
    4. User code
    5. Templates

Introduction

About MARaBOU

MARaBOU (MBS And ROOT a Based OnlineOffline Utility) is the data acquisition and analysis system used at the Tandem accelerator of the Maier-Leibnitz Laboratory.

As MARaBOU is based on the ROOT object-oriented framework a running ROOT system should be installed on your computer (version 3.05/05 or later).
To use the data acquisition part of MARaBOU you should have GSI's MBS (MultiBranchSystem) running, too.

Please visit MARaBOU's HomePage for an overview what the system is capable of.

Structure of a configuration file

A configuration file is a collection of MARaBOU and ROOT commands which will be executed by ROOT's C++-Interpreter Cint
The overall structure is as follows:
   #!/usr/local/bin/xrcm
   //_______________________________________________[MARaBOU configuration]
   ////////////////////////////////////////////////////////////////////////
   // Name:         Config.C
   // Purpose:      MARaBOU config file
   // Description:  Config file to define the experimental setup.
   //               Generates a C readout function to be used with MBS
   //               as well as C++ class definitions and methods for the
   //               data analysis with ROOT.
   // Author:
   // Revision:
   // Date:         Apr-2003
   // Keywords:
   ////////////////////////////////////////////////////////////////////////

   {
	gROOT->Macro("LoadConfigLibs.C");
	gROOT->Macro("LoadMbsSetupLibs.C");
	gROOT->Macro("LoadColors.C");

        // Any config definitions go here ....

   }
The first line directs the shell to invoke program xrcm which will pass the file contents to ROOT immediately.
So later on one may execute this file by simply typing
   ./Config.C
Any code has to be included in braces {...}. At the beginning statements gROOT->Macro(...) will load some libraries needed for the configuration process.

How to define basic configuration objects

The main configuration object

Each config file has to contain exactly one configuration object:
   TMrbConfig * cfg = new TMrbConfig("CfgName", "CfgTitle");
It will describe the whole configuration and will control any other config objects such as events, subevents, and histograms. In addition, the config's name CfgName will be prepended as prefix to all files written during the code generation process.

Events and triggers

For each trigger in the system there has to be an event definition:
   TMrbEvent_10_1 * evt = new TMrbEvent_10_1(Trigger, "EvtName", "EvtTitle");
It creates an event of type [10,1] as defined within MBS. This is the only MBS event type supported by MARaBOU.
Trigger is the trigger number given by the input to the MBS trigger module. It may be any number from 1 to 13 (triggers 14 and 15 are reserved for MBS). As the trigger module has 4 different inputs according to bits 1, 2, 4, 8 it is highly recommended to use these single-bit triggers only.
Multiple triggers will be ignored normally. By calling method HandleMultipleTriggers() the user may decide which combinations out of single triggers should be accepted:
   cfg->HandleMultipleTriggers();
   cfg->HandleMultipleTriggers(TrigPattern1, TrigPattern2, ...);
Calling this method without an argument will enable any trigger combination, otherwise patterns TrigPatternN give the valid combinations.

Subevents

As known from MBS an event may contain several subevents. A subevent definition looks like this:
   TMrbSubevent_10_1 * sevt = new TMrbSubevent_10_1("SevtName", "SevtTitle");
It creates the well-known MBS subevent type [10,1]: a list of pairs (channel, data).
For a full list of subevent types visit MARaBOU's HomePage. Subevent types used by the MINIBALL experiment are described in the Appendix

Modules and parameters

As a next step user has to define hardware modules he wants to use in the experiment. There are different definitions for CAMAC and VME modules, respectively:
   TMrbSilena_4418V * adc = new TMrbSilena_4418V("ModuleName", "Cx.Nyy");
   TMrbCaen_V785 * adc = new TMrbCaen_V785("ModuleName", BaseAddr);
The module's position in the crate is either given by crate and station numbers Cx.Nyy (CAMAC) or by its base addr (VME).
A list of modules known by MARaBOU may be seen in MARaBOU's HomePage, a detailed description of what is used in the MINIBALL experiment may be found in the Appendix