CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
CamacTBDataFormatter.h
Go to the documentation of this file.
1 #ifndef CamacTBDataFormatter_H
2 #define CamacTBDataFormatter_H
3 
9 #include <vector>
10 #include <iostream>
11 
14 
20 
22 
24 public:
27  LogDebug("EcalTBRawToDigi") << "@SUB=CamacTBDataFormatter"
28  << "\n";
29  };
30 
31  void interpretRawData(const FEDRawData& data,
32  EcalTBEventHeader& tbEventHeader,
33  EcalTBHodoscopeRawInfo& hodoRaw,
34  EcalTBTDCRawInfo& tdcRawInfo);
35 
36  // for tests based on standalone file
37  /* void interpretRawData(unsigned long * buffer, unsigned long bufferSize, */
38  /* EcalTBEventHeader& tbEventHeader, */
39  /* EcalTBHodoscopeRawInfo & hodo, */
40  /* EcalTBTDCRawInfo & tdc); */
41 
42 private:
43  bool checkStatus(unsigned long word, int wordNumber);
44 
45  int nWordsPerEvent; // Number of fibers per hodoscope plane
46 
47  static const int nHodoFibers = 64; // Number of fibers per hodoscope plane
48  static const int nHodoscopes = 2; // Number of different mappings between fiber and electronics
49  static const int nHodoPlanes = 4; // Number of hodoscopes along the beam
50  static const int hodoRawLen = 4; // The raw data is stored as 4 integers for each hodo plane
51 
55  bool statusWords[148 + 4];
56 
57  std::vector<int> scalers_;
58 };
59 #endif
int nHodoHits[nHodoPlanes]
std::vector< int > scalers_
int hodoAll[nHodoPlanes *nHodoFibers]
uint64_t word
bool checkStatus(unsigned long word, int wordNumber)
static const int nHodoFibers
int hodoHits[nHodoPlanes][nHodoFibers]
static const int nHodoscopes
static const int nHodoPlanes
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:79
static const int hodoRawLen
#define LogDebug(id)
void interpretRawData(const FEDRawData &data, EcalTBEventHeader &tbEventHeader, EcalTBHodoscopeRawInfo &hodoRaw, EcalTBTDCRawInfo &tdcRawInfo)