CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Member Functions | Private Attributes | Friends
L1GtBoardMaps Class Reference

#include <L1GtBoardMaps.h>

Public Member Functions

const std::vector< L1GtBoard > & gtBoardMaps () const
 get / set / print the L1 GT board map More...
 
 L1GtBoardMaps ()
 
void print (std::ostream &) const
 
void printGtBoardHexNameMap (std::ostream &myCout) const
 print L1 GT board name in hw record map More...
 
void printGtBoardSlotMap (std::ostream &myCout) const
 print L1 GT board - slot map More...
 
void printGtDaqActiveBoardsMap (std::ostream &myCout) const
 print L1 GT active boards map for DAQ record More...
 
void printGtDaqRecordMap (std::ostream &myCout) const
 print L1 GT DAQ record map More...
 
void printGtEvmActiveBoardsMap (std::ostream &myCout) const
 print L1 GT active boards map for EVM record More...
 
void printGtEvmRecordMap (std::ostream &myCout) const
 print L1 GT EVM record map More...
 
void printGtQuadToPsbMap (std::ostream &myCout) const
 print L1 quadruplet (4x16 bits)(cable) to PSB input map More...
 
void setGtBoardMaps (const std::vector< L1GtBoard > &)
 
virtual ~L1GtBoardMaps ()
 

Private Member Functions

template<class Archive >
void serialize (Archive &ar, const unsigned int version)
 

Private Attributes

std::vector< L1GtBoardm_gtBoardMaps
 L1 GT boards and their mapping. More...
 

Friends

class boost::serialization::access
 
template<typename CondSerializationT , typename Enabled >
struct cond::serialization::access
 
std::ostream & operator<< (std::ostream &, const L1GtBoardMaps &)
 output stream operator More...
 

Detailed Description

Description: map of the L1 GT boards.

Implementation: <TODO: enter implementation details>

Author
: Vasile Mihai Ghete - HEPHY Vienna

$Date$ $Revision$

Definition at line 33 of file L1GtBoardMaps.h.

Constructor & Destructor Documentation

L1GtBoardMaps::L1GtBoardMaps ( )

Definition at line 29 of file L1GtBoardMaps.cc.

30 {
31  // empty
32 }
L1GtBoardMaps::~L1GtBoardMaps ( )
virtual

Definition at line 35 of file L1GtBoardMaps.cc.

36 {
37  // empty
38 }

Member Function Documentation

const std::vector<L1GtBoard>& L1GtBoardMaps::gtBoardMaps ( ) const
inline

get / set / print the L1 GT board map

Definition at line 47 of file L1GtBoardMaps.h.

References m_gtBoardMaps.

Referenced by L1GlobalTrigger::produce().

48  {
49  return m_gtBoardMaps;
50  }
std::vector< L1GtBoard > m_gtBoardMaps
L1 GT boards and their mapping.
Definition: L1GtBoardMaps.h:85
void L1GtBoardMaps::print ( std::ostream &  myCout) const

Definition at line 50 of file L1GtBoardMaps.cc.

References m_gtBoardMaps.

Referenced by operator<<().

51 {
52  myCout << "\nL1 GT board map" << std::endl;
53 
54  myCout << " Size: " << m_gtBoardMaps.size() << " boards in L1 GT." << std::endl;
55 
56  for (std::vector<L1GtBoard>::const_iterator
57  cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
58 
59  cIt->print(myCout);
60  myCout << std::endl;
61  }
62 
63  myCout << std::endl;
64 
65 }
std::vector< L1GtBoard > m_gtBoardMaps
L1 GT boards and their mapping.
Definition: L1GtBoardMaps.h:85
void L1GtBoardMaps::printGtBoardHexNameMap ( std::ostream &  myCout) const

print L1 GT board name in hw record map

Definition at line 241 of file L1GtBoardMaps.cc.

References m_gtBoardMaps, and AlCaHLTBitMon_QueryRunRegistry::string.

242 {
243  myCout << "\nL1 GT board names in hw record map" << std::endl;
244 
245  int nrBoards = 0;
246  int posRec = -1;
247  boost::uint16_t boardId = 0;
248  std::string boardName;
249 
250  for (std::vector<L1GtBoard>::const_iterator
251  cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
252 
253  posRec = cIt->gtBoardHexName();
254  boardId = cIt->gtBoardId();
255  boardName = cIt->gtBoardName();
256 
257  if (posRec >=0) {
258  myCout
259  << " " << boardName << " " << std::hex << boardId << std::dec
260  << " has HexName " << std::hex << posRec << std::dec << std::endl;
261 
262  nrBoards++;
263  }
264  }
265 
266  myCout << "\n Size: " << nrBoards << " boards in the record" << std::endl;
267  myCout << std::endl;
268 
269 
270  myCout << std::endl;
271 
272 }
std::vector< L1GtBoard > m_gtBoardMaps
L1 GT boards and their mapping.
Definition: L1GtBoardMaps.h:85
void L1GtBoardMaps::printGtBoardSlotMap ( std::ostream &  myCout) const

print L1 GT board - slot map

Definition at line 207 of file L1GtBoardMaps.cc.

References m_gtBoardMaps, and AlCaHLTBitMon_QueryRunRegistry::string.

208 {
209  myCout << "\nL1 GT board - slot map" << std::endl;
210 
211  int nrBoards = 0;
212  int posRec = -1;
213  boost::uint16_t boardId = 0;
214  std::string boardName;
215 
216  for (std::vector<L1GtBoard>::const_iterator
217  cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
218 
219  posRec = cIt->gtBoardSlot();
220  boardId = cIt->gtBoardId();
221  boardName = cIt->gtBoardName();
222 
223  if (posRec >=0) {
224  myCout
225  << " " << boardName << " " << std::hex << boardId << std::dec
226  << " in slot " << posRec << std::endl;
227 
228  nrBoards++;
229  }
230  }
231 
232  myCout << "\n Size: " << nrBoards << " boards in the slot map" << std::endl;
233  myCout << std::endl;
234 
235 
236  myCout << std::endl;
237 
238 }
std::vector< L1GtBoard > m_gtBoardMaps
L1 GT boards and their mapping.
Definition: L1GtBoardMaps.h:85
void L1GtBoardMaps::printGtDaqActiveBoardsMap ( std::ostream &  myCout) const

print L1 GT active boards map for DAQ record

Definition at line 138 of file L1GtBoardMaps.cc.

References m_gtBoardMaps, and AlCaHLTBitMon_QueryRunRegistry::string.

139 {
140  myCout << "\nL1 GT DAQ \"active boards\" record map" << std::endl;
141 
142  int nrBoards = 0;
143  int posRec = -1;
144  boost::uint16_t boardId = 0;
145  std::string boardName;
146 
147  for (std::vector<L1GtBoard>::const_iterator
148  cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
149 
150  posRec = cIt->gtBitDaqActiveBoards();
151  boardId = cIt->gtBoardId();
152  boardName = cIt->gtBoardName();
153 
154  if (posRec >=0) {
155  myCout
156  << " " << boardName << " " << std::hex << boardId << std::dec
157  << " at bit " << posRec << std::endl;
158 
159  nrBoards++;
160  }
161  }
162 
163  myCout << "\n Size: " << nrBoards << " boards in the record" << std::endl;
164  myCout << std::endl;
165 
166 
167  myCout << std::endl;
168 
169 }
std::vector< L1GtBoard > m_gtBoardMaps
L1 GT boards and their mapping.
Definition: L1GtBoardMaps.h:85
void L1GtBoardMaps::printGtDaqRecordMap ( std::ostream &  myCout) const

print L1 GT DAQ record map

Definition at line 68 of file L1GtBoardMaps.cc.

References m_gtBoardMaps, and AlCaHLTBitMon_QueryRunRegistry::string.

69 {
70  myCout << "\nL1 GT DAQ record map" << std::endl;
71 
72  int nrBoards = 0;
73  int posRec = -1;
74  boost::uint16_t boardId = 0;
75  std::string boardName;
76 
77  for (std::vector<L1GtBoard>::const_iterator
78  cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
79 
80  posRec = cIt->gtPositionDaqRecord();
81  boardId = cIt->gtBoardId();
82  boardName = cIt->gtBoardName();
83 
84  if (posRec >=0) {
85  myCout
86  << " " << boardName << " " << std::hex << boardId << std::dec
87  << " at position " << posRec << std::endl;
88 
89  nrBoards++;
90  }
91  }
92 
93  myCout << "\n Size: " << nrBoards << " boards in the record" << std::endl;
94  myCout << " Header and trailer are automatically added to the hardware record.\n"
95  << std::endl;
96 
97 
98  myCout << std::endl;
99 
100 }
std::vector< L1GtBoard > m_gtBoardMaps
L1 GT boards and their mapping.
Definition: L1GtBoardMaps.h:85
void L1GtBoardMaps::printGtEvmActiveBoardsMap ( std::ostream &  myCout) const

print L1 GT active boards map for EVM record

Definition at line 172 of file L1GtBoardMaps.cc.

References m_gtBoardMaps, and AlCaHLTBitMon_QueryRunRegistry::string.

173 {
174  myCout << "\nL1 GT EVM \"active boards\" record map" << std::endl;
175 
176  int nrBoards = 0;
177  int posRec = -1;
178  boost::uint16_t boardId = 0;
179  std::string boardName;
180 
181  for (std::vector<L1GtBoard>::const_iterator
182  cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
183 
184  posRec = cIt->gtBitEvmActiveBoards();
185  boardId = cIt->gtBoardId();
186  boardName = cIt->gtBoardName();
187 
188  if (posRec >=0) {
189  myCout
190  << " " << boardName << " " << std::hex << boardId << std::dec
191  << " at bit " << posRec << std::endl;
192 
193  nrBoards++;
194  }
195  }
196 
197  myCout << "\n Size: " << nrBoards << " boards in the record" << std::endl;
198  myCout << std::endl;
199 
200 
201  myCout << std::endl;
202 
203 }
std::vector< L1GtBoard > m_gtBoardMaps
L1 GT boards and their mapping.
Definition: L1GtBoardMaps.h:85
void L1GtBoardMaps::printGtEvmRecordMap ( std::ostream &  myCout) const

print L1 GT EVM record map

Definition at line 103 of file L1GtBoardMaps.cc.

References m_gtBoardMaps, and AlCaHLTBitMon_QueryRunRegistry::string.

104 {
105  myCout << "\nL1 GT EVM record map" << std::endl;
106 
107  int nrBoards = 0;
108  int posRec = -1;
109  boost::uint16_t boardId = 0;
110  std::string boardName;
111 
112  for (std::vector<L1GtBoard>::const_iterator
113  cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
114 
115  posRec = cIt->gtPositionEvmRecord();
116  boardId = cIt->gtBoardId();
117  boardName = cIt->gtBoardName();
118 
119  if (posRec >=0) {
120  myCout
121  << " " << boardName << " " << std::hex << boardId << std::dec
122  << " at position " << posRec << std::endl;
123 
124  nrBoards++;
125  }
126  }
127 
128  myCout << "\n Size: " << nrBoards << " boards in the record" << std::endl;
129  myCout << " Header and trailer are automatically added to the hardware record.\n"
130  << std::endl;
131 
132 
133  myCout << std::endl;
134 
135 }
std::vector< L1GtBoard > m_gtBoardMaps
L1 GT boards and their mapping.
Definition: L1GtBoardMaps.h:85
void L1GtBoardMaps::printGtQuadToPsbMap ( std::ostream &  myCout) const

print L1 quadruplet (4x16 bits)(cable) to PSB input map

Definition at line 275 of file L1GtBoardMaps.cc.

References CenJetQ, ESumsQ, ForJetQ, Free, HfQ, IsoEGQ, JetCountsQ, m_gtBoardMaps, MQB1, MQB10, MQB2, MQB5, MQB6, MQB9, MQF11, MQF12, MQF3, MQF4, MQF7, MQF8, NoIsoEGQ, PSB, AlCaHLTBitMon_QueryRunRegistry::string, TauJetQ, and TechTr.

276 {
277 
278  myCout << "\nL1 GT \"cables to PSB\" input map (4x16 bits per cable) - DEPRECATED" << std::endl;
279 
280  int nrBoards = 0;
281  int nrCable = 0;
282 
283  for (std::vector<L1GtBoard>::const_iterator
284  cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
285 
286  if (cIt->gtBoardType() == PSB) {
287 
288  myCout << "\n PSB_" << cIt->gtBoardIndex() << "\n ";
289 
290  nrBoards++;
291 
292  std::vector<L1GtPsbQuad> quadInPsb = cIt->gtQuadInPsb();
293  std::string objType;
294 
295  for (std::vector<L1GtPsbQuad>::const_iterator
296  cItQuad = quadInPsb.begin(); cItQuad != quadInPsb.end(); ++cItQuad) {
297 
298  nrCable++;
299 
300  if ( *cItQuad == TechTr ) {
301  objType = "TechTr";
302  } else if ( *cItQuad == IsoEGQ ) {
303  objType = "IsoEGQ";
304  } else if ( *cItQuad == NoIsoEGQ ) {
305  objType = "NoIsoEGQ";
306  } else if ( *cItQuad == CenJetQ ) {
307  objType = "CenJetQ";
308  } else if ( *cItQuad == ForJetQ ) {
309  objType = "ForJetQ";
310  } else if ( *cItQuad == TauJetQ ) {
311  objType = "TauJetQ";
312  } else if ( *cItQuad == ESumsQ ) {
313  objType = "ESumsQ";
314  } else if ( *cItQuad == JetCountsQ ) {
315  objType = "JetCountsQ";
316  } else if ( *cItQuad == MQB1 ) {
317  objType = "MQB1";
318  } else if ( *cItQuad == MQB2 ) {
319  objType = "MQB2";
320  } else if ( *cItQuad == MQF3 ) {
321  objType = "MQF3";
322  } else if ( *cItQuad == MQF4 ) {
323  objType = "MQF4";
324  } else if ( *cItQuad == MQB5 ) {
325  objType = "MQB5";
326  } else if ( *cItQuad == MQB6 ) {
327  objType = "MQB6";
328  } else if ( *cItQuad == MQF7 ) {
329  objType = "MQF7";
330  } else if ( *cItQuad == MQF8 ) {
331  objType = "MQF8";
332  } else if ( *cItQuad == MQB9 ) {
333  objType = "MQB9";
334  } else if ( *cItQuad == MQB10 ) {
335  objType = "MQB10";
336  } else if ( *cItQuad == MQF11 ) {
337  objType = "MQF11";
338  } else if ( *cItQuad == MQF12 ) {
339  objType = "MQF12";
340  } else if ( *cItQuad == Free ) {
341  objType = "Free";
342  } else if ( *cItQuad == HfQ ) {
343  objType = "HfQ";
344  } else {
345  myCout << "\n\nError: no such member " << (*cItQuad)
346  << " in enum L1GtPsbQuad\n\n" << std::endl;
347  objType = "ERROR";
348  }
349 
350  myCout << objType << " ";
351  }
352 
353 
354  }
355  }
356 
357 
358  myCout << "\n\n Size: " << nrCable << " cables for " << nrBoards << " PSB boards"
359  << std::endl;
360 
361  myCout << std::endl;
362 
363 }
std::vector< L1GtBoard > m_gtBoardMaps
L1 GT boards and their mapping.
Definition: L1GtBoardMaps.h:85
template<class Archive >
void L1GtBoardMaps::serialize ( Archive &  ar,
const unsigned int  version 
)
private
void L1GtBoardMaps::setGtBoardMaps ( const std::vector< L1GtBoard > &  gtBoardMapsValue)

Definition at line 43 of file L1GtBoardMaps.cc.

References m_gtBoardMaps.

44 {
45 
46  m_gtBoardMaps = gtBoardMapsValue;
47 
48 }
std::vector< L1GtBoard > m_gtBoardMaps
L1 GT boards and their mapping.
Definition: L1GtBoardMaps.h:85

Friends And Related Function Documentation

friend class boost::serialization::access
friend

Definition at line 88 of file L1GtBoardMaps.h.

template<typename CondSerializationT , typename Enabled >
friend struct cond::serialization::access
friend

Definition at line 88 of file L1GtBoardMaps.h.

std::ostream& operator<< ( std::ostream &  os,
const L1GtBoardMaps result 
)
friend

output stream operator

Definition at line 366 of file L1GtBoardMaps.cc.

367 {
368  result.print(os);
369  return os;
370 
371 }
void print(std::ostream &) const

Member Data Documentation

std::vector<L1GtBoard> L1GtBoardMaps::m_gtBoardMaps
private