ATLAS Offline Software
Loading...
Searching...
No Matches
EfexHardwareInfo.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4#include <iostream>
6
7
8
9EfexHardwareInfo::EfexHardwareInfo(const std::string & efexlabel,
10 int fibre,
11 int inputconnector,
12 const std::string & mpod)
13:m_valid(true), m_efexlabel(efexlabel) , m_fibre(fibre), m_inputconnector(inputconnector),
14m_mpodlabel(mpod),m_overlap(-99)
15{
16}
18{
19 return m_efexlabel;
20}
22{
23 return m_fibre;
24}
26{
27 return 11-(m_fibre)%12; // Ribbon fibre # flip (hopefully right!)
28}
34{
35 int mpodnum = int(m_mpodlabel.at(1)) -48;
36 if (m_mpodlabel.at(0) == 'H') mpodnum += 10;
37 return mpodnum;
38}
40{
41 return m_mpodlabel;
42}
44{
45 return m_valid;
46}
48{
49 m_overlap = overlap;
50}
52{
53 return m_overlap;
54}
56{
57 std::cout << "EfexHardwareInfo Object:" << std::endl;
58 if(m_valid){
59 std::cout << "EFEX: " << this->getEFEXLabel() << std::endl;
60 std::cout << "Fibre: " << std::to_string(this->getFibreNumber()) << std::endl;
61 std::cout << "Input Connector: " << std::to_string(this->getInputConnector()) << std::endl;
62 std::cout << "MpodLabel: " << this->getMpodLabel() << std::endl;
63 }
64 else{
65 std::cout << "Invalid/Unused Connection" << std::endl;
66 }
67 std::cout << std::endl;
68}
EfexHardwareInfo()=default
std::string getEFEXLabel() const
bool getValidity() const
std::string m_mpodlabel
int getMpodNumber() const
int getFibreNumber() const
void setOverlap(int overlap)
std::string m_efexlabel
int getRibbonFibreNumber() const
std::string getMpodLabel() const
int getInputConnector() const