CMS 3D CMS Logo

RPCBasicTrigConfig.cc
Go to the documentation of this file.
3 
6 
9 
13  if (towNum >= 0)
14  return towNum;
15  else
16  return 0x3F + towNum + 1;
17 }
18 
19 //#############################################################################################
20 //
21 // Simple getters and setters
22 //
23 //#############################################################################################
30 
37 
44 int RPCBasicTrigConfig::getTCNum(const RPCConst::l1RpcConeCrdnts& coneCrdnts) { return coneCrdnts.m_LogSector; }
50 int RPCBasicTrigConfig::getTowsCntOnTB(int tbNum) { return m_TOWERS_CNT_ON_TB[tbNum]; }
55  if (m_TOW_ADDR_2_TOW_NUM[towAddr] == -99 || towAddr < 0 || towAddr > 35) {
56  throw RPCException("RPCBasicTrigConfig::towAddr2TowNum - wrong towAddr");
57  //edm::LogError("RPC")<< "RPCBasicTrigConfig::towAddr2TowNum - wrong towAddr";
58  }
59 
60  return m_TOW_ADDR_2_TOW_NUM[towAddr];
61 }
62 
64  return m_TOWER_ON_TB[RPCConst::ITOW_MAX + coneCrdnts.m_Tower];
65 }
66 
68  return m_PacManager->getPac(coneCrdnts.m_Tower, coneCrdnts.m_LogSector, coneCrdnts.m_LogSegment);
69 }
70 
72  return m_TB_NUM_FOR_TOWER[RPCConst::ITOW_MAX + coneCrdnts.m_Tower];
73 }
74 //#############################################################################################
75 //
76 // Constants
77 //
78 //#############################################################################################
80 
82  //-16 -15 -14 -13
83  0,
84  1,
85  2,
86  3, //tbn4
87  //-12 -11 -10 -9
88  0,
89  1,
90  2,
91  3, //tbn3
92  //-8 -7 -6 -5
93  0,
94  1,
95  2,
96  3, //tbn2
97  //-4 -3 -2
98  0,
99  1,
100  2, //tbn1
101  //-1 0 1
102  0,
103  1,
104  2, //tb0
105  //2 3 4
106  0,
107  1,
108  2, //tbp1
109  //5 6 7 8
110  0,
111  1,
112  2,
113  3, //tbp2
114  //9 10 11 12
115  0,
116  1,
117  2,
118  3, //tbp3
119  //13 14 15 16
120  0,
121  1,
122  2,
123  3, //tbp4
124  0 //one more extra
125 };
126 
127 const int RPCBasicTrigConfig::m_TOWERS_CNT_ON_TB[m_TB_IN_TC_CNT] = {4, 4, 4, 3, 3, 3, 4, 4, 4};
128 
130  //-16 -15 -14 -13 -12 -11 -10 -9 -8 -7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
131  0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 4, 4, 4, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8};
132 
134  //0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
135  -16,
136  -15,
137  -14,
138  -13,
139  -12,
140  -11,
141  -10,
142  -9,
143  -8,
144  -7,
145  -6,
146  -5,
147  -4,
148  -3,
149  -2,
150  -99,
151  -1,
152  0,
153  //18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35
154  1,
155  -99,
156  2,
157  3,
158  4,
159  -99,
160  5,
161  6,
162  7,
163  8,
164  9,
165  10,
166  11,
167  12,
168  13,
169  14,
170  15,
171  16};
RPCException.h
RPCPacManager::getPac
TPacType * getPac(int m_tower, int logSector, int logSegment) const
Definition: RPCPacManager.h:161
RPCConst::l1RpcConeCrdnts::m_Tower
int m_Tower
Definition: RPCConst.h:119
RPCBasicTrigConfig::towNum2TowNum2Comp
int towNum2TowNum2Comp(int towNum) override
Definition: RPCBasicTrigConfig.cc:12
RPCBasicTrigConfig::m_TOWERS_CNT_ON_TB
static const int m_TOWERS_CNT_ON_TB[m_TB_IN_TC_CNT]
Definition: RPCBasicTrigConfig.h:60
RPCBasicTrigConfig::m_TB_NUM_FOR_TOWER
static const int m_TB_NUM_FOR_TOWER[2 *RPCConst::ITOW_MAX+1]
Definition: RPCBasicTrigConfig.h:62
RPCBasicTrigConfig::m_TRIGGER_CRATES_CNT
static const int m_TRIGGER_CRATES_CNT
Definition: RPCBasicTrigConfig.h:54
RPCConst::l1RpcConeCrdnts
The coordinates of Logic Cone: m_Tower, m_LogSector, m_LogSegment.
Definition: RPCConst.h:118
RPCBasicTrigConfig.h
RPCBasicTrigConfig::m_TOW_ADDR_2_TOW_NUM
static const int m_TOW_ADDR_2_TOW_NUM[36]
Definition: RPCBasicTrigConfig.h:64
RPCBasicTrigConfig::getTBNum
int getTBNum(const RPCConst::l1RpcConeCrdnts &coneCrdnts) override
Returns the index of TB (in TC) that should run given LogCone.
Definition: RPCBasicTrigConfig.cc:71
RPCBasicTrigConfig::getTCNum
int getTCNum(const RPCConst::l1RpcConeCrdnts &coneCrdnts) override
Returns the index of TC that should run given LogCone.
Definition: RPCBasicTrigConfig.cc:44
RPCBasicTrigConfig::getTowerNumOnTb
int getTowerNumOnTb(const RPCConst::l1RpcConeCrdnts &coneCrdnts) override
Definition: RPCBasicTrigConfig.cc:63
RPCConst::l1RpcConeCrdnts::m_LogSegment
int m_LogSegment
Definition: RPCConst.h:121
RPCBasicTrigConfig::m_TB_IN_TC_CNT
static const int m_TB_IN_TC_CNT
Definition: RPCBasicTrigConfig.h:56
RPCException
Definition: RPCException.h:21
RPCBasicTrigConfig::m_TOWER_ON_TB
static const int m_TOWER_ON_TB[2 *RPCConst::ITOW_MAX+1+1]
Definition: RPCBasicTrigConfig.h:58
RPCBasicTrigConfig::getPac
const RPCPacData * getPac(const RPCConst::l1RpcConeCrdnts &coneCrdnts) const override
Returns pointer to m_PAC that should run given LogCone. The PACs are holded by L1PacManager.
Definition: RPCBasicTrigConfig.cc:67
RPCBasicTrigConfig::getTCsCnt
int getTCsCnt() override
returns count of Trigger Crates in system.
Definition: RPCBasicTrigConfig.cc:29
RPCBasicTrigConfig::m_PacManager
RPCPacManager< RPCPacData > * m_PacManager
Definition: RPCBasicTrigConfig.h:66
RPCBasicTrigConfig::getTBsInTC
int getTBsInTC() override
returns number og Trigger Boards in one Trigger Crate.
Definition: RPCBasicTrigConfig.cc:36
RPCConst::l1RpcConeCrdnts::m_LogSector
int m_LogSector
Definition: RPCConst.h:120
RPCBasicTrigConfig::RPCBasicTrigConfig
RPCBasicTrigConfig()
Ctor.
Definition: RPCBasicTrigConfig.cc:8
RPCBasicTrigConfig::towAddr2TowNum
int towAddr2TowNum(int towAddr) override
Definition: RPCBasicTrigConfig.cc:54
RPCPacData
Definition: RPCPacData.h:33
RPCPacManager< RPCPacData >
RPCConst::ITOW_MAX
Maximal number of abs(m_tower_number)
Definition: RPCConst.h:27
RPCBasicTrigConfig::getTowsCntOnTB
int getTowsCntOnTB(int tbNum) override
Returns the count of Towers (3 or 4), that are covered by given TB.
Definition: RPCBasicTrigConfig.cc:50