File indexing completed on 2024-04-06 12:02:22
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018 #include "CondFormats/L1TObjects/interface/L1GtParameters.h"
0019
0020
0021 #include <iomanip>
0022
0023
0024
0025
0026
0027
0028
0029 L1GtParameters::L1GtParameters() {
0030
0031 }
0032
0033
0034 L1GtParameters::~L1GtParameters() {
0035
0036 }
0037
0038
0039 void L1GtParameters::setGtTotalBxInEvent(const int& totalBxInEventValue) { m_totalBxInEvent = totalBxInEventValue; }
0040
0041
0042 void L1GtParameters::setGtDaqActiveBoards(const uint16_t& activeBoardsValue) { m_daqActiveBoards = activeBoardsValue; }
0043
0044
0045 void L1GtParameters::setGtEvmActiveBoards(const uint16_t& activeBoardsValue) { m_evmActiveBoards = activeBoardsValue; }
0046
0047
0048 void L1GtParameters::setGtDaqNrBxBoard(const std::vector<int>& nrBxBoardValue) { m_daqNrBxBoard = nrBxBoardValue; }
0049
0050
0051 void L1GtParameters::setGtEvmNrBxBoard(const std::vector<int>& nrBxBoardValue) { m_evmNrBxBoard = nrBxBoardValue; }
0052
0053 void L1GtParameters::setGtBstLengthBytes(const unsigned int& bstLengthBytesValue) {
0054 m_bstLengthBytes = bstLengthBytesValue;
0055 }
0056
0057
0058 void L1GtParameters::print(std::ostream& myCout) const {
0059 myCout << "\nL1 GT Parameters" << std::endl;
0060
0061 myCout << "\n Total Bx's in the event = " << m_totalBxInEvent << std::endl;
0062
0063 myCout << "\n Active boards in L1 GT DAQ record (hex format) = " << std::hex
0064 << std::setw(sizeof(m_daqActiveBoards) * 2) << std::setfill('0') << m_daqActiveBoards << std::dec
0065 << std::setfill(' ') << std::endl;
0066
0067 myCout << "\n Active boards in L1 GT EVM record (hex format) = " << std::hex
0068 << std::setw(sizeof(m_evmActiveBoards) * 2) << std::setfill('0') << m_evmActiveBoards << std::dec
0069 << std::setfill(' ') << std::endl;
0070
0071 myCout << "\n"
0072 << " Number of bunch crosses per board in L1 GT DAQ record\n"
0073 << " Board bit gives the position of the board in the \"active boards\" word.\n"
0074 << std::endl;
0075
0076 int iBit = 0;
0077 for (std::vector<int>::const_iterator cIt = m_daqNrBxBoard.begin(); cIt != m_daqNrBxBoard.end(); ++cIt) {
0078 myCout << " Board active bit " << iBit << ": " << (*cIt) << " BXs" << std::endl;
0079 iBit++;
0080 }
0081
0082 myCout << "\n"
0083 << " Number of bunch crosses per board in L1 GT EVM record\n"
0084 << " Board bit gives the position of the board in the \"active boards\" word.\n"
0085 << std::endl;
0086
0087 iBit = 0;
0088 for (std::vector<int>::const_iterator cIt = m_evmNrBxBoard.begin(); cIt != m_evmNrBxBoard.end(); ++cIt) {
0089 myCout << " Board active bit " << iBit << ": " << (*cIt) << " BXs" << std::endl;
0090 iBit++;
0091 }
0092
0093 myCout << "\n Length of the BST message = " << m_bstLengthBytes << std::endl;
0094
0095 myCout << "\n" << std::endl;
0096 }
0097
0098
0099 std::ostream& operator<<(std::ostream& os, const L1GtParameters& result) {
0100 result.print(os);
0101 return os;
0102 }