DataFormats
DTDigi
interface
DTDigi.h
Go to the documentation of this file.
1
#ifndef DTDigi_DTDigi_h
2
#define DTDigi_DTDigi_h
3
15
#include <cstdint>
16
17
class
DTDigi
{
18
public
:
19
// typedef uint32_t ChannelType;
20
23
explicit
DTDigi
(
int
wire
,
int
nTDC,
int
number
= 0,
int
base
= 32);
24
25
// Construct from the wire#, the time (ns) and the digi number.
26
// time is converted in TDC counts (1 TDC = 25./base ns)
27
// number should identify uniquely multiple digis in the same cell.
28
explicit
DTDigi
(
int
wire
,
double
tdrift,
int
number
= 0,
int
base
= 32);
29
30
// Construct from channel and counts.
31
// explicit DTDigi (ChannelType channel, int nTDC);
32
34
DTDigi
();
35
37
bool
operator==
(
const
DTDigi
& digi)
const
;
38
39
// The channel identifier and the digi number packed together
40
// ChannelType channel() const ;
41
43
int
wire
()
const
;
44
46
int
number
()
const
;
47
49
double
time
()
const
;
50
52
int32_t
countsTDC
()
const
;
53
55
double
tdcUnit
()
const
;
56
58
int
tdcBase
()
const
;
59
61
void
print
()
const
;
62
63
private
:
64
friend
class
testDTDigis
;
65
66
// The value of one TDC count in ns
67
static
const
double
reso
;
68
69
int32_t
theCounts
;
// TDC count, in units given by 1/theTDCBase
70
uint16_t
theWire
;
// channel number
71
uint8_t
theNumber
;
// counter for digis in the same cell
72
uint8_t
theTDCBase
;
// TDC base (counts per BX; 32 in Ph1 or 30 in Ph2)
73
};
74
75
#include <iostream>
76
#include <cstdint>
77
inline
std::ostream&
operator<<
(std::ostream&
o
,
const
DTDigi
& digi) {
78
return
o
<<
" "
<< digi.
wire
() <<
" "
<< digi.
time
() <<
" "
<< digi.
number
();
79
}
80
#endif
DTDigi::reso
static const double reso
Definition:
DTDigi.h:67
operator<<
std::ostream & operator<<(std::ostream &o, const DTDigi &digi)
Definition:
DTDigi.h:77
DTDigi::tdcUnit
double tdcUnit() const
Get the TDC unit value in ns.
Definition:
DTDigi.cc:45
DTDigi::number
int number() const
Identifies different digis within the same cell.
Definition:
DTDigi.cc:43
DTDigi::DTDigi
DTDigi()
Default construction.
Definition:
DTDigi.cc:26
DTDigi::theTDCBase
uint8_t theTDCBase
Definition:
DTDigi.h:72
DTDigi::time
double time() const
Get time in ns.
Definition:
DTDigi.cc:37
EcalTangentSkim_cfg.o
o
Definition:
EcalTangentSkim_cfg.py:36
DTDigi::wire
int wire() const
Return wire number.
Definition:
DTDigi.cc:41
DTDigi::theCounts
int32_t theCounts
Definition:
DTDigi.h:69
DTDigi::tdcBase
int tdcBase() const
Get the TDC base (counts per BX)
Definition:
DTDigi.cc:47
DTDigi::countsTDC
int32_t countsTDC() const
Get raw TDC count.
Definition:
DTDigi.cc:39
DTDigi::testDTDigis
friend class testDTDigis
Definition:
DTDigi.h:64
DTDigi::print
void print() const
Print content of digi.
Definition:
DTDigi.cc:49
DTDigi::theWire
uint16_t theWire
Definition:
DTDigi.h:70
DTDigi::operator==
bool operator==(const DTDigi &digi) const
Digis are equal if they are on the same cell and have same TDC count.
Definition:
DTDigi.cc:29
DTDigi
Definition:
DTDigi.h:17
newFWLiteAna.base
base
Definition:
newFWLiteAna.py:92
DTDigi::theNumber
uint8_t theNumber
Definition:
DTDigi.h:71
Generated for CMSSW Reference Manual by
1.8.16