CMS 3D CMS Logo

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::L1GtBoardMaps ( )

Definition at line 29 of file L1GtBoardMaps.cc.

29  {
30  // empty
31 }

◆ ~L1GtBoardMaps()

L1GtBoardMaps::~L1GtBoardMaps ( )
virtual

Definition at line 34 of file L1GtBoardMaps.cc.

34  {
35  // empty
36 }

Member Function Documentation

◆ gtBoardMaps()

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

◆ print()

void L1GtBoardMaps::print ( std::ostream &  myCout) const

Definition at line 41 of file L1GtBoardMaps.cc.

41  {
42  myCout << "\nL1 GT board map" << std::endl;
43 
44  myCout << " Size: " << m_gtBoardMaps.size() << " boards in L1 GT." << std::endl;
45 
46  for (std::vector<L1GtBoard>::const_iterator cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
47  cIt->print(myCout);
48  myCout << std::endl;
49  }
50 
51  myCout << std::endl;
52 }

References m_gtBoardMaps.

Referenced by L1GtBoardMapsTester::analyze().

◆ printGtBoardHexNameMap()

void L1GtBoardMaps::printGtBoardHexNameMap ( std::ostream &  myCout) const

print L1 GT board name in hw record map

Definition at line 190 of file L1GtBoardMaps.cc.

190  {
191  myCout << "\nL1 GT board names in hw record map" << std::endl;
192 
193  int nrBoards = 0;
194  int posRec = -1;
195  uint16_t boardId = 0;
196  std::string boardName;
197 
198  for (std::vector<L1GtBoard>::const_iterator cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
199  posRec = cIt->gtBoardHexName();
200  boardId = cIt->gtBoardId();
201  boardName = cIt->gtBoardName();
202 
203  if (posRec >= 0) {
204  myCout << " " << boardName << " " << std::hex << boardId << std::dec << " has HexName " << std::hex << posRec
205  << std::dec << std::endl;
206 
207  nrBoards++;
208  }
209  }
210 
211  myCout << "\n Size: " << nrBoards << " boards in the record" << std::endl;
212  myCout << std::endl;
213 
214  myCout << std::endl;
215 }

References amcDumpToRaw_cfi::boardId, TauDecayModes::dec, m_gtBoardMaps, and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by L1GtBoardMapsTester::analyze().

◆ printGtBoardSlotMap()

void L1GtBoardMaps::printGtBoardSlotMap ( std::ostream &  myCout) const

print L1 GT board - slot map

Definition at line 163 of file L1GtBoardMaps.cc.

163  {
164  myCout << "\nL1 GT board - slot map" << std::endl;
165 
166  int nrBoards = 0;
167  int posRec = -1;
168  uint16_t boardId = 0;
169  std::string boardName;
170 
171  for (std::vector<L1GtBoard>::const_iterator cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
172  posRec = cIt->gtBoardSlot();
173  boardId = cIt->gtBoardId();
174  boardName = cIt->gtBoardName();
175 
176  if (posRec >= 0) {
177  myCout << " " << boardName << " " << std::hex << boardId << std::dec << " in slot " << posRec << std::endl;
178 
179  nrBoards++;
180  }
181  }
182 
183  myCout << "\n Size: " << nrBoards << " boards in the slot map" << std::endl;
184  myCout << std::endl;
185 
186  myCout << std::endl;
187 }

References amcDumpToRaw_cfi::boardId, TauDecayModes::dec, m_gtBoardMaps, and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by L1GtBoardMapsTester::analyze().

◆ printGtDaqActiveBoardsMap()

void L1GtBoardMaps::printGtDaqActiveBoardsMap ( std::ostream &  myCout) const

print L1 GT active boards map for DAQ record

Definition at line 109 of file L1GtBoardMaps.cc.

109  {
110  myCout << "\nL1 GT DAQ \"active boards\" record map" << std::endl;
111 
112  int nrBoards = 0;
113  int posRec = -1;
114  uint16_t boardId = 0;
115  std::string boardName;
116 
117  for (std::vector<L1GtBoard>::const_iterator cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
118  posRec = cIt->gtBitDaqActiveBoards();
119  boardId = cIt->gtBoardId();
120  boardName = cIt->gtBoardName();
121 
122  if (posRec >= 0) {
123  myCout << " " << boardName << " " << std::hex << boardId << std::dec << " at bit " << posRec << std::endl;
124 
125  nrBoards++;
126  }
127  }
128 
129  myCout << "\n Size: " << nrBoards << " boards in the record" << std::endl;
130  myCout << std::endl;
131 
132  myCout << std::endl;
133 }

References amcDumpToRaw_cfi::boardId, TauDecayModes::dec, m_gtBoardMaps, and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by L1GtBoardMapsTester::analyze().

◆ printGtDaqRecordMap()

void L1GtBoardMaps::printGtDaqRecordMap ( std::ostream &  myCout) const

print L1 GT DAQ record map

Definition at line 55 of file L1GtBoardMaps.cc.

55  {
56  myCout << "\nL1 GT DAQ record map" << std::endl;
57 
58  int nrBoards = 0;
59  int posRec = -1;
60  uint16_t boardId = 0;
61  std::string boardName;
62 
63  for (std::vector<L1GtBoard>::const_iterator cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
64  posRec = cIt->gtPositionDaqRecord();
65  boardId = cIt->gtBoardId();
66  boardName = cIt->gtBoardName();
67 
68  if (posRec >= 0) {
69  myCout << " " << boardName << " " << std::hex << boardId << std::dec << " at position " << posRec << std::endl;
70 
71  nrBoards++;
72  }
73  }
74 
75  myCout << "\n Size: " << nrBoards << " boards in the record" << std::endl;
76  myCout << " Header and trailer are automatically added to the hardware record.\n" << std::endl;
77 
78  myCout << std::endl;
79 }

References amcDumpToRaw_cfi::boardId, TauDecayModes::dec, m_gtBoardMaps, and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by L1GtBoardMapsTester::analyze().

◆ printGtEvmActiveBoardsMap()

void L1GtBoardMaps::printGtEvmActiveBoardsMap ( std::ostream &  myCout) const

print L1 GT active boards map for EVM record

Definition at line 136 of file L1GtBoardMaps.cc.

136  {
137  myCout << "\nL1 GT EVM \"active boards\" record map" << std::endl;
138 
139  int nrBoards = 0;
140  int posRec = -1;
141  uint16_t boardId = 0;
142  std::string boardName;
143 
144  for (std::vector<L1GtBoard>::const_iterator cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
145  posRec = cIt->gtBitEvmActiveBoards();
146  boardId = cIt->gtBoardId();
147  boardName = cIt->gtBoardName();
148 
149  if (posRec >= 0) {
150  myCout << " " << boardName << " " << std::hex << boardId << std::dec << " at bit " << posRec << std::endl;
151 
152  nrBoards++;
153  }
154  }
155 
156  myCout << "\n Size: " << nrBoards << " boards in the record" << std::endl;
157  myCout << std::endl;
158 
159  myCout << std::endl;
160 }

References amcDumpToRaw_cfi::boardId, TauDecayModes::dec, m_gtBoardMaps, and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by L1GtBoardMapsTester::analyze().

◆ printGtEvmRecordMap()

void L1GtBoardMaps::printGtEvmRecordMap ( std::ostream &  myCout) const

print L1 GT EVM record map

Definition at line 82 of file L1GtBoardMaps.cc.

82  {
83  myCout << "\nL1 GT EVM record map" << std::endl;
84 
85  int nrBoards = 0;
86  int posRec = -1;
87  uint16_t boardId = 0;
88  std::string boardName;
89 
90  for (std::vector<L1GtBoard>::const_iterator cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
91  posRec = cIt->gtPositionEvmRecord();
92  boardId = cIt->gtBoardId();
93  boardName = cIt->gtBoardName();
94 
95  if (posRec >= 0) {
96  myCout << " " << boardName << " " << std::hex << boardId << std::dec << " at position " << posRec << std::endl;
97 
98  nrBoards++;
99  }
100  }
101 
102  myCout << "\n Size: " << nrBoards << " boards in the record" << std::endl;
103  myCout << " Header and trailer are automatically added to the hardware record.\n" << std::endl;
104 
105  myCout << std::endl;
106 }

References amcDumpToRaw_cfi::boardId, TauDecayModes::dec, m_gtBoardMaps, and AlCaHLTBitMon_QueryRunRegistry::string.

Referenced by L1GtBoardMapsTester::analyze().

◆ printGtQuadToPsbMap()

void L1GtBoardMaps::printGtQuadToPsbMap ( std::ostream &  myCout) const

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

Definition at line 218 of file L1GtBoardMaps.cc.

218  {
219  myCout << "\nL1 GT \"cables to PSB\" input map (4x16 bits per cable) - DEPRECATED" << std::endl;
220 
221  int nrBoards = 0;
222  int nrCable = 0;
223 
224  for (std::vector<L1GtBoard>::const_iterator cIt = m_gtBoardMaps.begin(); cIt != m_gtBoardMaps.end(); ++cIt) {
225  if (cIt->gtBoardType() == PSB) {
226  myCout << "\n PSB_" << cIt->gtBoardIndex() << "\n ";
227 
228  nrBoards++;
229 
230  std::vector<L1GtPsbQuad> quadInPsb = cIt->gtQuadInPsb();
232 
233  for (std::vector<L1GtPsbQuad>::const_iterator cItQuad = quadInPsb.begin(); cItQuad != quadInPsb.end();
234  ++cItQuad) {
235  nrCable++;
236 
237  if (*cItQuad == TechTr) {
238  objType = "TechTr";
239  } else if (*cItQuad == IsoEGQ) {
240  objType = "IsoEGQ";
241  } else if (*cItQuad == NoIsoEGQ) {
242  objType = "NoIsoEGQ";
243  } else if (*cItQuad == CenJetQ) {
244  objType = "CenJetQ";
245  } else if (*cItQuad == ForJetQ) {
246  objType = "ForJetQ";
247  } else if (*cItQuad == TauJetQ) {
248  objType = "TauJetQ";
249  } else if (*cItQuad == ESumsQ) {
250  objType = "ESumsQ";
251  } else if (*cItQuad == JetCountsQ) {
252  objType = "JetCountsQ";
253  } else if (*cItQuad == MQB1) {
254  objType = "MQB1";
255  } else if (*cItQuad == MQB2) {
256  objType = "MQB2";
257  } else if (*cItQuad == MQF3) {
258  objType = "MQF3";
259  } else if (*cItQuad == MQF4) {
260  objType = "MQF4";
261  } else if (*cItQuad == MQB5) {
262  objType = "MQB5";
263  } else if (*cItQuad == MQB6) {
264  objType = "MQB6";
265  } else if (*cItQuad == MQF7) {
266  objType = "MQF7";
267  } else if (*cItQuad == MQF8) {
268  objType = "MQF8";
269  } else if (*cItQuad == MQB9) {
270  objType = "MQB9";
271  } else if (*cItQuad == MQB10) {
272  objType = "MQB10";
273  } else if (*cItQuad == MQF11) {
274  objType = "MQF11";
275  } else if (*cItQuad == MQF12) {
276  objType = "MQF12";
277  } else if (*cItQuad == Free) {
278  objType = "Free";
279  } else if (*cItQuad == HfQ) {
280  objType = "HfQ";
281  } else {
282  myCout << "\n\nError: no such member " << (*cItQuad) << " in enum L1GtPsbQuad\n\n" << std::endl;
283  objType = "ERROR";
284  }
285 
286  myCout << objType << " ";
287  }
288  }
289  }
290 
291  myCout << "\n\n Size: " << nrCable << " cables for " << nrBoards << " PSB boards" << std::endl;
292 
293  myCout << std::endl;
294 }

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

Referenced by L1GtBoardMapsTester::analyze().

◆ serialize()

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

◆ setGtBoardMaps()

void L1GtBoardMaps::setGtBoardMaps ( const std::vector< L1GtBoard > &  gtBoardMapsValue)

Definition at line 39 of file L1GtBoardMaps.cc.

39 { m_gtBoardMaps = gtBoardMapsValue; }

References m_gtBoardMaps.

Friends And Related Function Documentation

◆ boost::serialization::access

friend class boost::serialization::access
friend

Definition at line 77 of file L1GtBoardMaps.h.

◆ cond::serialization::access

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

Definition at line 77 of file L1GtBoardMaps.h.

◆ operator<<

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

output stream operator

Definition at line 297 of file L1GtBoardMaps.cc.

297  {
298  result.print(os);
299  return os;
300 }

Member Data Documentation

◆ m_gtBoardMaps

std::vector<L1GtBoard> L1GtBoardMaps::m_gtBoardMaps
private
CenJetQ
Definition: L1GtDefinitions.h:43
amcDumpToRaw_cfi.boardId
boardId
Definition: amcDumpToRaw_cfi.py:9
PSB
Definition: L1GtDefinitions.h:27
MQF4
Definition: L1GtDefinitions.h:51
TauJetQ
Definition: L1GtDefinitions.h:45
MQB5
Definition: L1GtDefinitions.h:52
ESumsQ
Definition: L1GtDefinitions.h:46
L1GtBoardMaps::m_gtBoardMaps
std::vector< L1GtBoard > m_gtBoardMaps
L1 GT boards and their mapping.
Definition: L1GtBoardMaps.h:75
ForJetQ
Definition: L1GtDefinitions.h:44
MQF12
Definition: L1GtDefinitions.h:59
MQB2
Definition: L1GtDefinitions.h:49
MQF11
Definition: L1GtDefinitions.h:58
NoIsoEGQ
Definition: L1GtDefinitions.h:42
Free
Definition: L1GtDefinitions.h:39
MQB10
Definition: L1GtDefinitions.h:57
IsoEGQ
Definition: L1GtDefinitions.h:41
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
electrons_cff.objType
objType
Definition: electrons_cff.py:491
MQF7
Definition: L1GtDefinitions.h:54
TechTr
Definition: L1GtDefinitions.h:40
MQB9
Definition: L1GtDefinitions.h:56
MQB6
Definition: L1GtDefinitions.h:53
MQF8
Definition: L1GtDefinitions.h:55
MQB1
Definition: L1GtDefinitions.h:48
mps_fire.result
result
Definition: mps_fire.py:303
MQF3
Definition: L1GtDefinitions.h:50
TauDecayModes.dec
dec
Definition: TauDecayModes.py:143
HfQ
Definition: L1GtDefinitions.h:61
JetCountsQ
Definition: L1GtDefinitions.h:47