CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
L1GtParameters.cc
Go to the documentation of this file.
1 
17 // this class header
19 
20 // system include files
21 #include <iomanip>
22 
23 // user include files
24 // base class
25 
26 // forward declarations
27 
28 // constructor
30  // empty
31 }
32 
33 // destructor
35  // empty
36 }
37 
38 // set the total Bx's in the event
39 void L1GtParameters::setGtTotalBxInEvent(const int& totalBxInEventValue) { m_totalBxInEvent = totalBxInEventValue; }
40 
41 // set active boards for L1 GT DAQ record
42 void L1GtParameters::setGtDaqActiveBoards(const uint16_t& activeBoardsValue) { m_daqActiveBoards = activeBoardsValue; }
43 
44 // set active boards for L1 GT EVM record
45 void L1GtParameters::setGtEvmActiveBoards(const uint16_t& activeBoardsValue) { m_evmActiveBoards = activeBoardsValue; }
46 
47 // set number of Bx for L1 GT DAQ record
48 void L1GtParameters::setGtDaqNrBxBoard(const std::vector<int>& nrBxBoardValue) { m_daqNrBxBoard = nrBxBoardValue; }
49 
50 // set number of Bx for L1 GT EVM record
51 void L1GtParameters::setGtEvmNrBxBoard(const std::vector<int>& nrBxBoardValue) { m_evmNrBxBoard = nrBxBoardValue; }
52 
53 void L1GtParameters::setGtBstLengthBytes(const unsigned int& bstLengthBytesValue) {
54  m_bstLengthBytes = bstLengthBytesValue;
55 }
56 
57 // print all the L1 GT parameters
58 void L1GtParameters::print(std::ostream& myCout) const {
59  myCout << "\nL1 GT Parameters" << std::endl;
60 
61  myCout << "\n Total Bx's in the event = " << m_totalBxInEvent << std::endl;
62 
63  myCout << "\n Active boards in L1 GT DAQ record (hex format) = " << std::hex
64  << std::setw(sizeof(m_daqActiveBoards) * 2) << std::setfill('0') << m_daqActiveBoards << std::dec
65  << std::setfill(' ') << std::endl;
66 
67  myCout << "\n Active boards in L1 GT EVM record (hex format) = " << std::hex
68  << std::setw(sizeof(m_evmActiveBoards) * 2) << std::setfill('0') << m_evmActiveBoards << std::dec
69  << std::setfill(' ') << std::endl;
70 
71  myCout << "\n"
72  << " Number of bunch crosses per board in L1 GT DAQ record\n"
73  << " Board bit gives the position of the board in the \"active boards\" word.\n"
74  << std::endl;
75 
76  int iBit = 0;
77  for (std::vector<int>::const_iterator cIt = m_daqNrBxBoard.begin(); cIt != m_daqNrBxBoard.end(); ++cIt) {
78  myCout << " Board active bit " << iBit << ": " << (*cIt) << " BXs" << std::endl;
79  iBit++;
80  }
81 
82  myCout << "\n"
83  << " Number of bunch crosses per board in L1 GT EVM record\n"
84  << " Board bit gives the position of the board in the \"active boards\" word.\n"
85  << std::endl;
86 
87  iBit = 0;
88  for (std::vector<int>::const_iterator cIt = m_evmNrBxBoard.begin(); cIt != m_evmNrBxBoard.end(); ++cIt) {
89  myCout << " Board active bit " << iBit << ": " << (*cIt) << " BXs" << std::endl;
90  iBit++;
91  }
92 
93  myCout << "\n Length of the BST message = " << m_bstLengthBytes << std::endl;
94 
95  myCout << "\n" << std::endl;
96 }
97 
98 // output stream operator
99 std::ostream& operator<<(std::ostream& os, const L1GtParameters& result) {
100  result.print(os);
101  return os;
102 }
virtual ~L1GtParameters()
void setGtDaqNrBxBoard(const std::vector< int > &)
void setGtBstLengthBytes(const unsigned int &)
std::vector< int > m_daqNrBxBoard
number of Bx per board in the DAQ record
unsigned int m_bstLengthBytes
length of BST message (in bytes)
void print(std::ostream &) const
print all the L1 GT parameters
std::ostream & operator<<(std::ostream &out, const ALILine &li)
Definition: ALILine.cc:167
uint16_t m_evmActiveBoards
active boards in the L1 EVM record
tuple result
Definition: mps_fire.py:311
void setGtTotalBxInEvent(const int &)
uint16_t m_daqActiveBoards
active boards in the L1 DAQ record
void setGtEvmActiveBoards(const uint16_t &)
void setGtEvmNrBxBoard(const std::vector< int > &)
void setGtDaqActiveBoards(const uint16_t &)
std::vector< int > m_evmNrBxBoard
number of Bx per board in the EVM record
int m_totalBxInEvent
total Bx&#39;s in the event