AliRoot Core  v5-06-15 (45dab64)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Go to the documentation of this file.
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice */
6 /*$Id$*/
12 // Author Christian Finck
14 #include <TObject.h>
15 #include <TClonesArray.h>
17 class AliMUONRegHeader;
19 class AliMUONDarcHeader : public TObject {
21 public:
23  AliMUONDarcHeader(TRootIOCtor* dummy);
27  virtual ~AliMUONDarcHeader();
31  UInt_t GetWord() const {return fWord;}
33  UInt_t GetGlobalInput(Int_t n) const {return fGlobalInput[n];}
35  UChar_t GetGlobalOutput() const {return (fGlobalOutput & 0xFF);}
37  UShort_t GetGlobalConfig() const {return ((fGlobalOutput >> 16) & 0xFFFF);}
39  //MBZ:1, phys trig:1, type:3, ,SerialNb:4,Version:8,VME trig:1,
40  //GlobalFlag:1, CTP trig:1, DAQ:1, Reg pattern:8;
43  //Bool_t GetEventType() const {return (fWord & 0x40000000);}
44  Bool_t GetEventType() const;
46  UChar_t GetDarcType() const {return (UChar_t)(fWord >> 24) & 0x7;}
48  UChar_t GetSerialNb() const {return (UChar_t)(fWord >> 20) & 0xF;}
50  UChar_t GetVersion() const {return (UChar_t)(fWord >> 12) & 0xFF;}
52  Bool_t GetVMETrig() const {return (fWord & 0x800);}
54  Bool_t GetGlobalFlag() const {return (fWord & 0x400);}
56  Bool_t GetCTPTrig() const {return (fWord & 0x200);}
58  Bool_t GetDAQFlag() const {return (fWord & 0x100);}
60  UChar_t GetRegPattern() const {return (UChar_t)(fWord & 0xFF);}
63  void SetWord(UInt_t w) {fWord = w;}
65  void SetGlobalInput(UInt_t in, Int_t n) {fGlobalInput[n] = in;}
67  void SetGlobalOutput(Int_t out) {fGlobalOutput = out;}
70  Int_t GetDarcHeaderLength() const {return fgkDarcHeaderLength;}
75  UInt_t* GetHeader() {return &fWord;}
77  UInt_t* GetGlobalInput() {return &fGlobalInput[0];}
79  // DARC get methods
81  UInt_t GetDarcL0R() const {return fDarcL0R;}
83  UInt_t GetDarcL1P() const {return fDarcL1P;}
85  UInt_t GetDarcL1S() const {return fDarcL1S;}
87  UInt_t GetDarcL2A() const {return fDarcL2A;}
89  UInt_t GetDarcL2R() const {return fDarcL2R;}
91  UInt_t GetDarcClock() const {return fDarcClk;}
93  UInt_t GetDarcHold() const {return fDarcHold;}
95  // don't use setting methods but memcpy
97  UInt_t* GetGlobalScalers() {return &fGlobalL0;}
99  UInt_t* GetDarcScalers() {return &fDarcL0R;}
101  // global get methods
103  UInt_t GetGlobalL0() const {return fGlobalL0;}
105  UInt_t GetGlobalClock() const {return fGlobalClk;}
107  const UInt_t* GetGlobalScaler() const {return fGlobalScaler;}
109  UInt_t GetGlobalHold() const {return fGlobalHold;}
111  UInt_t GetGlobalSpare() const {return fGlobalSpare;}
116  Int_t GetDarcScalerLength() const {return fgkDarcScalerLength;}
119  UInt_t GetEndOfDarc() const {return fgkEndOfDarc;}
121  UInt_t GetEndOfGlobal() const {return fgkEndOfGlobal;}
124  UInt_t GetDarcDefaultType() const {return fgkDarcDefaultType;}
126  UInt_t GetDarcVadohrType() const {return fgkDarcVadorhType;}
128  // set random numbers to fill variable
129  void SetScalersNumbers();
132  TClonesArray* GetRegHeaderArray() const {return fRegHeaderArray;}
135  Int_t GetRegHeaderEntries() const {return fRegHeaderArray->GetEntriesFast();}
139  return (AliMUONRegHeader*)fRegHeaderArray->At(i);}
141  // clear
142  void Clear(Option_t* opt);
144  private:
146  UInt_t fWord;
147  UInt_t fGlobalInput[4];
150  static const Int_t fgkDarcHeaderLength;
151  static const Int_t fgkGlobalHeaderLength;
154  // global card scalers
155  UInt_t fGlobalL0;
156  UInt_t fGlobalClk;
157  UInt_t fGlobalScaler[6];
158  UInt_t fGlobalHold;
159  UInt_t fGlobalSpare;
160  static const Int_t fgkGlobalScalerLength;
162  // DARC Scalers
163  UInt_t fDarcL0R;
164  UInt_t fDarcL1P;
165  UInt_t fDarcL1S;
166  UInt_t fDarcL2A;
167  UInt_t fDarcL2R;
168  UInt_t fDarcClk;
169  UInt_t fDarcHold;
170  UInt_t fDarcSpare;
172  static const Int_t fgkDarcScalerLength;
174  static const UInt_t fgkEndOfDarc;
175  static const UInt_t fgkEndOfGlobal;
177  static const UInt_t fgkDarcDefaultType;
178  static const UInt_t fgkDarcVadorhType;
181  TClonesArray* fRegHeaderArray;
183  ClassDef(AliMUONDarcHeader,2) // MUON DDL Trigger
184 };
185 #endif
Bool_t GetCTPTrig() const
Return CPT trigger.
Int_t GetGlobalHeaderLength() const
Return global header length.
static const UInt_t fgkDarcVadorhType
default type for DARC vadorh
UChar_t GetGlobalOutput() const
Return global output.
Int_t GetRegHeaderEntries() const
get entries
UInt_t GetGlobalHold() const
Return global hold (dead time)
static const UInt_t fgkDarcDefaultType
default type for DARC def.
UInt_t GetDarcL2R() const
Return DARC L2 reject.
TClonesArray * fRegHeaderArray
container for regional header
UInt_t fGlobalL0
global L0
UInt_t GetGlobalL0() const
Return global L0.
UInt_t GetDarcL1P() const
Return DARC L1 physics.
UInt_t GetGlobalClock() const
Return global clock.
UInt_t fDarcClk
DARC clock.
UInt_t fGlobalClk
global clock
UInt_t * GetDarcScalers()
Return DARC L0 received and used.
UInt_t GetWord() const
Return first word.
Int_t GetDarcScalerLength() const
Return length of DARC scaler in word.
static const Int_t fgkGlobalScalerLength
length of global scaler in word
UInt_t fDarcHold
DARC hold (dead time)
Int_t GetGlobalScalerLength() const
Return length of global scaler in word.
UInt_t fGlobalInput[4]
global input
void Clear(Option_t *opt)
UShort_t GetGlobalConfig() const
Return global config.
MUON regional header for trigger.
static const UInt_t fgkEndOfDarc
end of darc info word
UChar_t GetSerialNb() const
Return serial number.
UInt_t GetDarcClock() const
Return DARC clock.
UChar_t GetVersion() const
Return version.
UInt_t fDarcL2R
DARC L2 reject.
UInt_t GetEndOfDarc() const
Return end of darc info word.
UInt_t GetDarcL2A() const
Return DARC L2 accept.
UInt_t fDarcL2A
DARC L2 accept.
UInt_t * GetHeader()
Return header.
UInt_t GetDarcL0R() const
Return DARC L0 received and used.
Bool_t GetDAQFlag() const
Return DAQ flag.
void SetGlobalOutput(Int_t out)
Set global output.
TClonesArray * GetRegHeaderArray() const
get TClonesArray
UChar_t GetDarcType() const
Return Darc type.
static const Int_t fgkGlobalHeaderLength
global header length
MUON Darc header for Trigger.
void SetWord(UInt_t w)
Set first word.
void SetGlobalInput(UInt_t in, Int_t n)
Set global input.
UInt_t GetDarcHold() const
Return DARC hold (dead time)
UInt_t fGlobalScaler[6]
global ouput
UInt_t GetGlobalInput(Int_t n) const
Return global input.
Int_t fGlobalOutput
global ouput
UInt_t GetDarcDefaultType() const
Return default type for DARC def.
UInt_t GetDarcVadohrType() const
Return default type for DARC def.
static const Int_t fgkDarcScalerLength
length of DARC scaler in word
Bool_t GetEventType() const
Return event type.
UInt_t * GetGlobalInput()
Return global input.
static const UInt_t fgkEndOfGlobal
end of global info word
UInt_t GetGlobalSpare() const
Return global spare.
UInt_t fDarcSpare
DARC Empty slot (for the moment)
UInt_t fWord
first word
AliMUONRegHeader * GetRegHeaderEntry(Int_t i) const
get entry
AliMUONDarcHeader & operator=(const AliMUONDarcHeader &event)
UInt_t fGlobalHold
global hold (dead time)
UChar_t GetRegPattern() const
Return reg pattern.
Bool_t GetVMETrig() const
Return VME trig.
UInt_t GetDarcL1S() const
Return DARC L1 software.
const UInt_t * GetGlobalScaler() const
Return global scaler.
UInt_t fDarcL0R
DARC L0 received and used.
UInt_t GetEndOfGlobal() const
Return end of global info word.
UInt_t fDarcL1P
DARC L1 physics.
UInt_t * GetGlobalScalers()
Return global L0.
UInt_t fGlobalSpare
global spare
UInt_t fDarcL1S
DARC L1 software.
static const Int_t fgkDarcHeaderLength
darc header length
Int_t GetDarcHeaderLength() const
Return darc header length.
Bool_t GetGlobalFlag() const
Return global flag.