8#include <trg/cdc/dataobjects/CDCTriggerSegmentHit.h>
13 unsigned short priorityPosition,
14 unsigned short leftRight,
19 std::vector<float> hittime,
20 unsigned int hitpattern,
21 std::vector<float> adcinfo,
22 unsigned int adcpattern):
28 std::array<int, 9> nWiresInSuperLayer = {
29 160, 160, 192, 224, 256, 288, 320, 352, 384
31 unsigned short iSL = 0;
32 unsigned short iWire = segmentID;
33 while (iWire >= nWiresInSuperLayer[iSL]) {
34 iWire -= nWiresInSuperLayer[iSL];
38 if (priorityPosition == 1) {
40 iWire = nWiresInSuperLayer[iSL] - 1;
44 unsigned short iLayer = (iSL == 0) ? 3 : 2;
45 if (priorityPosition == 1 || priorityPosition == 2)
52 unsigned short priorityPosition,
53 unsigned short leftRight,
58 std::vector<float> hittime,
59 unsigned int hitpattern,
60 std::vector<float> adcinfo,
61 unsigned int adcpattern):
68 std::array<int, 9> nWiresInSuperLayer = {
69 160, 160, 192, 224, 256, 288, 320, 352, 384
72 for (
unsigned i = 0; i < iSL; ++i) {
76 if (priorityPosition == 1) {
78 iWire = nWiresInSuperLayer[iSL] - 1;
82 unsigned short iLayer = (iSL == 0) ? 3 : 2;
83 if (priorityPosition == 1 || priorityPosition == 2)
89 unsigned short segmentID,
90 unsigned short priorityPosition,
91 unsigned short leftRight,
96 std::vector<float> hittime,
97 unsigned int hitpattern,
98 std::vector<float> adcinfo,
99 unsigned int adcpattern):
110 std::array<int, 9> nWiresInSuperLayer = {
111 160, 160, 192, 224, 256, 288, 320, 352, 384
117 if (iWire == nWiresInSuperLayer[iSL]) {
Class containing the result of the unpacker in raw data and the result of the digitizer in simulation...
short priorityTime() const
get hit time of priority cell in trigger clocks
unsigned int m_hitpattern
hit pattern
unsigned short m_priorityPosition
position of the priority cell as an id: 0: no hit, 3: 1st priority, 1: 2nd right, 2: 2nd left
unsigned short m_eWire
Wire encoding of the priority wire.
std::vector< float > m_adcinfo
Full ADC information.
short m_priorityTime
hit time of priority cell in trigger clocks (~ 2ns)
unsigned short getIWire() const
get wire number of priority wire within layer.
short m_fastestTime
time of first hit in the track segment in trigger clocks (~ 2ns)
std::vector< float > m_hittime
hit pattern with hit time
unsigned short getID() const
get the encoded wire number of the priority wire.
unsigned short m_segmentID
continuous ID of the track segment
short fastestTime() const
get time of first hit in the track segment in trigger clocks
short m_foundTime
time when segment hit was found in trigger clocks (~ 2ns)
unsigned short getISuperLayer() const
get super layer number.
CDCTriggerSegmentHit()
default constructor.
unsigned int m_adcpattern
adc pattern
unsigned short m_leftRight
position of the priority cell relative to the track: 0: no hit, 1: right, 2: left,...
unsigned short getIWireCenter() const
get wire number of center wire within layer.
short foundTime() const
get time when segment hit was found in trigger clocks
Class to identify a wire inside the CDC.
unsigned short getEWire() const
Getter for encoded wire number.
Abstract base class for different kinds of events.