Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
oncsSub_idfnalmwpcv2.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file oncsSub_idfnalmwpcv2.h
1 #ifndef __ONCSSUB_IDFNALMWPCV2_H__
2 #define __ONCSSUB_IDFNALMWPCV2_H__
3 
4 #include <vector>
5 #include "oncsSubevent.h"
6 
7 #include "oncsSub_idfnalmwpc.h"
8 
9 #ifndef __CINT__
11 #else
13 #endif
14 
15 public:
18 
19 
20  int iValue(const int n, const char *);
21 
22 
23  // for a given trigger, information about the TDC
24  int iValue(const int trigger, const int tdc, const char * what);
25 
26  // this returns the wire number
27  int iValue(const int trigger, const int tdc, const int index);
28 
29  // this is the workhorse interface
30  int iValue(const int trigger, const int tdc, const int index, const char *what);
31 
32 
33  void dump ( OSTREAM& os = COUT) ;
34 
35 protected:
36  int *decode (int *);
37 
38  int _decoded;
39 
40 #define MAXNROFTDCS 16
41 
42 
43  typedef struct {
44  int wire;
45  int timestamp;
46  } TDC_hit;
47 
48 
49  typedef struct {
50  int hits;
51  short words;
52  short TDC;
53  short EventStatus;
54  short trigger_nr;
55  short triggertype;
56  unsigned short evt_timestamp;
57  unsigned short local_ts_upper;
58  unsigned short local_ts_lower;
59  unsigned long long absolute_time;
60  std::vector<TDC_hit *> TDCHitlist;
61  } TDCData;
62 
63 
64  typedef struct {
66  unsigned short evt_timestamp;
67  unsigned short local_ts_upper;
68  unsigned short local_ts_lower;
69  unsigned long long absolute_time;
71  } TDCEvent;
72 
73  typedef struct {
76  short year;
77  short month;
78  short day;
79  short hour;
80  short minute;
81  short second;
85  } SpillInfo;
86 
87 
88  typedef struct {
90  short TDC;
92  short spillstatus;
94 
95 
96  int tdcmask;
97  int n_tdcs;
98  int length;
99 
101 
103 
104 
105  std::vector<TDCEvent *> TDCEventVector;
106 
107 };
108 
109 #endif