1 | #ifndef MARS_MRawEvtHeader
|
---|
2 | #define MARS_MRawEvtHeader
|
---|
3 |
|
---|
4 | #ifndef MARS_MParContainer
|
---|
5 | #include "MParContainer.h"
|
---|
6 | #endif
|
---|
7 |
|
---|
8 | // gcc 3.2
|
---|
9 | //class ifstream;
|
---|
10 | #include <iosfwd>
|
---|
11 |
|
---|
12 | class MTime;
|
---|
13 | class MArrayB;
|
---|
14 | class MRawRunHeader;
|
---|
15 |
|
---|
16 | class MRawEvtHeader : public MParContainer
|
---|
17 | {
|
---|
18 | public:
|
---|
19 | //
|
---|
20 | // Trigger Type (TT)
|
---|
21 | //
|
---|
22 | enum {
|
---|
23 | kTTEvent = 0,
|
---|
24 | kTTPedestal = 1,
|
---|
25 | kTTCalibration = 2
|
---|
26 | };
|
---|
27 |
|
---|
28 | private:
|
---|
29 | MTime *fTime; //! object to store the time in (ReadEvt)
|
---|
30 |
|
---|
31 | UInt_t fDAQEvtNumber; // Number of Event
|
---|
32 |
|
---|
33 | UInt_t fNumTrigLvl1; // Number of 1st level tiggers between 2 events
|
---|
34 | UInt_t fNumTrigLvl2; // Number of 2nd level tiggers between 2 events
|
---|
35 | UInt_t fTrigPattern[2]; // Trigger configuration
|
---|
36 |
|
---|
37 | UShort_t fNumLoGainOn; // Indicating if no pixel has a neglegible
|
---|
38 | // low gain signal (0), else it is the number
|
---|
39 | // of pixels with lo gain on
|
---|
40 |
|
---|
41 | //
|
---|
42 | // Informations only needed to read the raw file correctly
|
---|
43 | //
|
---|
44 | UShort_t fTrigType; //! Trigger Type of this event
|
---|
45 | MArrayB *fPixLoGainOn; //! Array which tell you which pixels have lo gain on
|
---|
46 |
|
---|
47 | Bool_t DecodeTime(UInt_t abstime[2]) const;
|
---|
48 |
|
---|
49 | Int_t GetNumBytes() const;
|
---|
50 |
|
---|
51 | public:
|
---|
52 | MRawEvtHeader(const char *name=NULL, const char *title=NULL);
|
---|
53 | ~MRawEvtHeader();
|
---|
54 |
|
---|
55 | void Init(MRawRunHeader *rh, MTime *t);
|
---|
56 |
|
---|
57 | void Clear(Option_t * = NULL);
|
---|
58 | void Print(Option_t * = NULL) const;
|
---|
59 |
|
---|
60 | void FillHeader(UInt_t, Float_t=0);
|
---|
61 |
|
---|
62 | UShort_t GetTrigType() const { return fTrigType; }
|
---|
63 | UInt_t GetNumTrigLvl1() const { return fNumTrigLvl1; }
|
---|
64 | UInt_t GetNumTrigLvl2() const { return fNumTrigLvl2; }
|
---|
65 | UInt_t GetDAQEvtNumber() const { return fDAQEvtNumber; }
|
---|
66 |
|
---|
67 | UInt_t GetTriggerID() const;
|
---|
68 |
|
---|
69 | Int_t ReadEvt(istream& fin, UShort_t ver);
|
---|
70 | void SkipEvt(istream& fin, UShort_t ver);
|
---|
71 |
|
---|
72 | ClassDef(MRawEvtHeader, 1) // Parameter Conatiner for raw EVENT HEADER
|
---|
73 | };
|
---|
74 |
|
---|
75 | #endif
|
---|