1 #ifndef ALIPHOSTRURAWREADER_H
2 #define ALIPHOSTRURAWREADER_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
8 class AliCaloRawStreamV3;
13 * Class for reading TRU data from a bunch from a raw datastream.
14 * Author: Henrik Qvigstad <henrik.qvigstad@cern.ch>
16 class AliPHOSTRURawReader : public TObject
19 AliPHOSTRURawReader();
20 virtual ~AliPHOSTRURawReader();
22 Short_t GetTriggerSignal(Int_t xIdx, Int_t zIdx, Int_t timeBin) const {return fSignals[xIdx][zIdx][timeBin];}
23 Bool_t GetTriggerFlag(Int_t xIdx, Int_t zIdx, Int_t timeBin) const {return fFlags[xIdx][zIdx][timeBin];}
24 bool IsActive() {return fActive;}
25 bool IsActive(Int_t timeBin) {return fActiveTime[timeBin];}
27 void ReadFromStream(AliCaloRawStreamV3* );
31 AliPHOSTRURawReader(const AliPHOSTRURawReader &); // not implemented
32 AliPHOSTRURawReader& operator= (const AliPHOSTRURawReader &); // not implemented
35 const static Int_t kDefaultSignalValue = 512; // Default/Ideal TRU amplitude pedestal
39 const static Int_t kNTimeBins = 128; // Number of timeBins
40 const static Int_t kN2x2XPrTRURow = 8; // (=64/2/4) Number of 2x2 pr. row
41 const static Int_t kN2x2ZPrBranch = 14; // (=56/2/2) Number of 2x2 pr. branch
42 const static Int_t kN4x4XPrTRURow = 7; // (=64/2/4 -1) Number of 4x4 pr. row
43 const static Int_t kN4x4ZPrBranch = 13; // (=56/2/2) -1 Number of 4x4 pr. branch
45 Short_t fSignals[kN2x2XPrTRURow][kN2x2ZPrBranch][kNTimeBins]; // 2x2 Trigger Signal Sum, [x][z][t]
46 Bool_t fFlags[kN4x4XPrTRURow][kN4x4ZPrBranch][kNTimeBins]; // 4x4 Trigger Flag, [x][z][t]
48 Bool_t fActive; // Active
49 Bool_t fActiveTime[kNTimeBins]; // Active [t]
51 ClassDef(AliPHOSTRURawReader, 0)
54 #endif // ALIPHOSTRURAWREADER_H