FairRoot/PandaRoot
ReadMainzProto60v4.h
Go to the documentation of this file.
1 /****************************************************
2  * ReadMainzProto60v4 class to read data files from
3  * the proto60 tests at mami
4  *
5  * author: chammann@hiskp.uni-bonn.de
6  * date: 6.1.2010
7  *
8  * *************************************************/
9 
10 #ifndef ReadMainzProto60v4_h
11 #define ReadMainzProto60v4_h
12 #include "TObject.h"
13 #include "ReadMainzProto60.h"
14 
16  public:
17  void GetEnergies(Double_t *energies); //energies has to be at least 60 long
18  void GetTimes(Double_t *times); //times has to be at least 60 long
19  void GetADCValues(Double_t *ADCs); //ADCs has to be at least 60 long
20  void GetTaggerTimes(Double_t *taggertimes); //taggertimes has to be at least 16 long
21  void GetTaggerEnergies(Double_t *taggerEnergies); //taggertimes has to be at least 16 long
22 
23  void Reset();
24 
25  void PrintEvent();
26 
27  Long_t ReadNextEvent(); //returns total number of events read, -1 if no event could be read (end of file)
28  Long_t GetNumberOfEvents();
29 
31  ReadMainzProto60v4(const char *datafilename, const char *calibrationfilename);
33  private:
34  FILE * in;
35  unsigned int read_one_event();
37  void convert_60(void);
38  void calibrate_60(void);
39  void read_energy_factor(const char *filename);
41 
42  double LG[60];
43  double TIME[60];
44  double TAGGER[16];
45  double TP;
46  double MU;
47  double VETO;
48 
49  double LG_CAL[60];
50  double TIME_CAL[60];
51  double TAGGER_CAL[16];
52  double TP_CAL;
53  double MU_CAL;
54  double VETO_CAL;
55 
56  unsigned int rawdata[32][16];
57  unsigned int noe_of_board[16];
58  int no_of_boards, what[16], geos[16];
59  unsigned int geo_to_bnr[32];
60  char versionsstr[15];
61 
62  int RANGE, BINS;
64  int central;
65 
66  double lg_factor[60];
67  double lg_ped[60];
68  double ctime_factor;
70 
71  ClassDef(ReadMainzProto60v4,1)
72 };
73 #endif
74 
unsigned int noe_of_board[16]
unsigned int geo_to_bnr[32]
void GetEnergies(Double_t *energies)
unsigned int rawdata[32][16]
Double_t
void GetTaggerEnergies(Double_t *taggerEnergies)
void GetTimes(Double_t *times)
unsigned int read_one_event()
void GetTaggerTimes(Double_t *taggertimes)
void read_energy_factor(const char *filename)
void GetADCValues(Double_t *ADCs)
const string filename