ATLAS Offline Software
Loading...
Searching...
No Matches
Pad.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef TrigT1RPChardware_Pad_H
6#define TrigT1RPChardware_Pad_H
7
9
10class Pad {
11public:
12 Pad(int run, int event, CMAword debug, ubit16 subsys, ubit16 sect, ubit16 padad, ubit16 lowhig, bool oldSimulation, int NOBXS);
13 // ubit16 padInput[2][2][2][NOBXS][2]);
14 ~Pad();
15 void reset();
17 void setProjectionLogic(ubit16 prologic);
18 void load(ubit16 lowhig, ubit16 etaphi, ubit16 CMadd, ubit16 BX, ubit16 thres, ubit16 overl);
19 void execute();
20 void display(int flag);
21 //
22 // readout method
23 //
24 int get_PADID();
26 ubit16 getRoI(ubit16 bunch);
28 ubit16 getOPL(ubit16 bunch);
33 bool isOldSimulation(); // M.C. 3/3/2010
34 void setOldSimulation(bool value);
35
36 // M.Corradi Jan 9, 2015
37 void setFeetOn(bool feet) { m_feet_on = feet; };
38 void setFeetThresholds(unsigned short int ith, unsigned short int th) { m_feet_thresholds[ith] = th; };
39
40private:
41 int m_run;
43 bool m_oldSimulation; // M.C. 3/3/2010
45 unsigned short int m_feet_thresholds[3];
46
47 //
48 // pad parameters
49 //
50 // Load the "Hit in Outer Plane" flag
51 //
52 ubit16 m_nBunMax; // Maximum number of Bunch crossings to be cons.
53 ubit16 m_thHitOuterPlane; // gives the address from 1 to 3 of the
54 // threshold used for Outer Plane Confirmation
55 // 0 = no hit In Outer Plane required
56 //
57 // store this information in hitInOuterPlane
58 //
59 ubit16 m_hitInOuterPlane[3]; // hitInOuterPlane[i] i=0,1,2 threshold address
60 // = 0 => no Outer Plane coincidence required
61 // > 0 => Outer Plane coincidence required
62 //
63 // pad attributes: subsystem, sector, padadd, low/high-pt;
64 //
65 ubit16 m_subsystem; // subsystem 0,1
66 ubit16 m_sector; // sector address
67 ubit16 m_padadd; // pad address
68 ubit16 m_lowhigh; // lowhigh_pt type, 0=low; 1=high
69 //
71
72 // in the data and with the new cabling (m_oldSimulation==false)
73 // the local RoI definition is
74 // roi = phi_id*2+eta_id
75 // and does not correspond to a simple geometrical order
76 //
77 // the drawing below reports the old roi numbering convention
78 // which is consistent with the simulation with RPCcablingSim (m_oldSimulation==true)
79 //
80 // RoI numbering
81 //
82 // CM0 CM1
83 // | | |
84 // | | |
85 // | ROI 1 | ROI 3 | CM1
86 // | | |
87 // +---------------+------------------
88 // | | | ^ phi
89 // | ROI 0 | ROI 2 | CM0 |
90 // | | | |
91 // | | | |
92 // ==================== SECTOR GEOMETRICAL AXIS =====================> eta
93 // | | | |
94 // | | | |
95 // | ROI 0 | ROI 2 | CM0 |
96 // | | | |
97 // +---------------+------------------ V phi
98 // | | |
99 // | ROI 1 | ROI 3 | CM1
100 // | | |
101 // | | |
102 // CM0 CM1
103 //
104 // padIn[i][j][k][l][m]
105 // ^ ^ ^ ^ ^
106 // | | | | |
107 // | | | | --- 0=threshold; 1=overlap
108 // | | | ------ bunch-crossing identifier (in NOBXS bunches range)
109 // | | --------- matrix local address (0,1)
110 // | ------------ eta-phi matrix: 0=eta; 1=phi.
111 // --------------- low-pt=0, high-pt=1;
112 //
113 ubit16 m_padIn[2][2][2][8][2]; //assumes max NOBXS=8
114 //
115 // PAD LOGIC STEP n. 2
116 //
117 // padStep2[i][j][k]
118 // ^ ^ ^
119 // | | |
120 // | | ----- results summary data as follows:
121 // | | j= 0,1 highest threshold satisfied by CM with local
122 // | | address "j"
123 // | | j= 2 highest satisfied threshold by pad logic
124 // | | j= 3 CM local address with highest threshold
125 // | | j= 4 number of CMs with any threshold satisfied
126 // | | j= 5 overlap flag
127 // | | j= 6 hit in outer plane
128 // | | j= 7 Roi ambiguity
129 // | |
130 // | ----- eta-phi
131 // -------- bunch-crossing identifier (in NOBXS bunches range)
132 //
133 //
134 ubit16 m_padStep2[8][2][8]; //m_padStep2[NOBXS][2][8], assumes NOBXS=8 at most
135 //
136 // PAD LOGIC OUTPUT
137 //
138 // padOut[i][j]
139 // ^ ^
140 // | |
141 // | ---- pad logic output:
142 // | j=0 RoI address in the pad region
143 // | j=1 pT coding (three low-pT thresh. + three high-pt thresh.)
144 // | 1,2,3 increasing low-pt thresholds
145 // | 4,5,6 increasing hig-pt thresholds
146 // | j=2 OPL (hit in outer plane)
147 // | j=3 Overlap phi flag to be solved by MUCTPI
148 // | j=4 Overlap eta flag to be solved by Sector Logic
149 // | j=5 RoI Ambiguity
150 // | j=6 BCID counter
151 // |
152 // ------- bunch-crossing identifier (in NOBXS bunches range)
153 //
154 //
155 //
156 ubit16 m_padOut[8][7]; //assumes NOBXS=8 at most
157 //
158 void threshold();
159 void overlap();
160 void makeOut();
161 void makeOutEta();
162 void makeOutPhi();
163 void makeOutEtaAndPhi();
164 void makeOutEtaOrPhi();
165 void makeFeet();
166
167}; // end-of-class Pad
168#endif
uint32_t CMAword
Definition Lvl1Def.h:17
const bool debug
unsigned short int ubit16
void load(ubit16 lowhig, ubit16 etaphi, ubit16 CMadd, ubit16 BX, ubit16 thres, ubit16 overl)
Definition Pad.cxx:121
bool m_oldSimulation
Definition Pad.h:43
void display(int flag)
Definition Pad.cxx:307
ubit16 getPTCoding(ubit16 bunch)
Definition Pad.cxx:410
void makeFeet()
Definition Pad.cxx:300
bool m_feet_on
Definition Pad.h:44
ubit16 m_nBunMax
Definition Pad.h:52
void setDefaultConfiguration()
Definition Pad.cxx:93
void overlap()
Definition Pad.cxx:194
void threshold()
Definition Pad.cxx:153
ubit16 getBCIDCounter(ubit16 bunch)
Definition Pad.cxx:460
void makeOutPhi()
Definition Pad.cxx:240
void makeOutEtaAndPhi()
Definition Pad.cxx:259
bool isOldSimulation()
Definition Pad.cxx:470
ubit16 m_padStep2[8][2][8]
Definition Pad.h:134
Pad(int run, int event, CMAword debug, ubit16 subsys, ubit16 sect, ubit16 padad, ubit16 lowhig, bool oldSimulation, int NOBXS)
Definition Pad.cxx:16
void setOldSimulation(bool value)
Definition Pad.cxx:473
~Pad()
Definition Pad.cxx:59
void reset()
Definition Pad.cxx:64
ubit16 getRoI(ubit16 bunch)
Definition Pad.cxx:400
ubit16 getOPL(ubit16 bunch)
Definition Pad.cxx:420
void setFeetThresholds(unsigned short int ith, unsigned short int th)
Definition Pad.h:38
ubit16 m_lowhigh
Definition Pad.h:68
ubit16 m_projectionLogic
Definition Pad.h:70
ubit16 m_padadd
Definition Pad.h:67
void makeOutEtaOrPhi()
Definition Pad.cxx:284
ubit16 m_padIn[2][2][2][8][2]
Definition Pad.h:113
void makeOutEta()
Definition Pad.cxx:221
void setProjectionLogic(ubit16 prologic)
Definition Pad.cxx:112
void makeOut()
Definition Pad.cxx:209
ubit16 m_sector
Definition Pad.h:66
int m_run
Definition Pad.h:41
ubit16 getRoIAmbiguity(ubit16 bunch)
Definition Pad.cxx:450
ubit16 m_subsystem
Definition Pad.h:65
int get_PADID()
Definition Pad.cxx:396
ubit16 m_hitInOuterPlane[3]
Definition Pad.h:59
ubit16 m_padOut[8][7]
Definition Pad.h:156
void setFeetOn(bool feet)
Definition Pad.h:37
int m_event
Definition Pad.h:42
void execute()
Definition Pad.cxx:141
ubit16 getOverlapPhi(ubit16 bunch)
Definition Pad.cxx:430
ubit16 getOverlapEta(ubit16 bunch)
Definition Pad.cxx:440
unsigned short int m_feet_thresholds[3]
Definition Pad.h:45
ubit16 m_thHitOuterPlane
Definition Pad.h:53
CMAword padDebug
Definition Pad.h:25
Definition run.py:1