1 #ifndef ALIHMPIDRAWSTREAM_H
2 #define ALIHMPIDRAWSTREAM_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
6 ///////////////////////////////////////////////////////////////////////////////
8 /// This is a class for reading raw data digits for HMPID.
9 /// The data format is taken from the document provided by Paolo Martinengo.
11 /// cvetan.cheshkov@cern.ch 19/07/2007
13 ///////////////////////////////////////////////////////////////////////////////
19 class AliHMPIDRawStream: public TObject {
21 AliHMPIDRawStream(AliRawReader* rawReader);
22 virtual ~AliHMPIDRawStream();
25 virtual Bool_t Next();
28 Int_t GetDDLNumber() const { return fDDLNumber; } // Provide current DDL number
29 Short_t GetCharge(Int_t row, Int_t dilogic, Int_t pad) const; // Provide the charge observed in certain row,dilogic,pad channel
31 enum EHMPIDRawStreamError {
46 kNRows = 25, // Number of rows (starting from 1 !)
47 kNDILOGICAdd = 11, // Number of DILOGIC addresses in a row (starting from 1 !)
48 kNPadAdd = 48, // Number of
49 kNRowsPerSegment = 8 // Number of rows per segment
54 AliHMPIDRawStream& operator = (const AliHMPIDRawStream& stream);
55 AliHMPIDRawStream(const AliHMPIDRawStream& stream);
59 Short_t fCharge[kNRows][kNDILOGICAdd][kNPadAdd]; // Array for charge values for all channels in one DDL
61 Int_t fDDLNumber; // index of current DDL number
63 AliRawReader* fRawReader; // object for reading the raw data
65 UChar_t* fData; // raw data
67 Int_t fPosition; // current position in fData
68 // Int_t fCount; // counter of words to be read for current trailer
70 ClassDef(AliHMPIDRawStream, 0) // base class for reading HMPID raw digits