ATLAS Offline Software
TGCPatchPanel.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef TGCPatchPanel_hh
6 #define TGCPatchPanel_hh
7 
10 #include "TrigT1TGC/TGCNumbering.h"
11 #include <fstream>
12 #include <string>
13 
14 namespace LVL1TGCTrigger {
15 
16 class TGCPatchPanelOut;
17 class TGCASDOut;
18 class TGCBIDOut;
19 class TGCConnectionInPP;
20 class TGCDatabaseManager;
21 
22 typedef class TGCPatchPanel TGCWireTripletPP;
23 typedef class TGCPatchPanel TGCWireDoubletPP;
24 typedef class TGCPatchPanel TGCStripTripletPP;
25 typedef class TGCPatchPanel TGCStripDoubletPP;
26 typedef class TGCPatchPanel TGCWireInnerPP;
27 typedef class TGCPatchPanel TGCStripInnerPP;
28 
29 
30 const int NumberOfPatchPanelOut = 2;
31 const int NumberOfASDOut = 4;
33 const int NumberOfASDChannel = 16;
35 const int MaxNumberOfConnector = 10;
36 const int NumberOfBunchKeptInPP = 1;
37 
39 public:
40  void clockIn(int bunch, TGCDatabaseManager* db=0);
41 
42  TGCPatchPanelOut* getOutput(int SBId);
43  void eraseOutput(int SBId);
44 
45  int getIdSlaveBoard(int port) const;
46  void setIdSlaveBoard(int port,int id);
47 
48  // pointer to adjacent Patch Panel board.
50  const TGCPatchPanel* getAdjacentPP(int side) const { return m_PPAdj[side]; };
51  void setAdjacentPP(int side, TGCPatchPanel* PP);
52 
53  void setASDOut(int ch, int connector, const TGCASDOut* asdOut);
54 
55  TGCBIDOut* getBIDOut(int ch, int connector, int bunch);
56 
57  void dumpPPOut(); // print output of Patch Panel
58  void dumpPPOut(int i); // bit pattern is separated by underscore
59 
60  void showProperty();
61 
62  int getId() const;
63  void setId(int idIn);
64  int getType() const { return m_type; };
65  void setType(int typeIn) { m_type=typeIn; };
66  TGCRegionType getRegion() const { return m_region; };
67  void setRegion(TGCRegionType regionIn) { m_region=regionIn; };
68 
69  void connect();
70  std::string getTypeName(int typeIn) const;
71 
74  TGCPatchPanel(const TGCPatchPanel& right) = delete;
76 
77  const TGCArguments* tgcArgs() const { return m_tgcArgs; }
78 
79 private:
80  void showResult() const;
81  void doBID();
82  int doOrLogic();
83  int createOutput();
84  int getInputConnectorIndex(const int connectorId) const;
85  void clearASDOut();
86  void deleteBIDOut();
87 
88  int m_id;
90  int m_type;
95  int m_nHit; // 18-Jan-01 Added by KH
96 
100  TGCPatchPanel* m_PPAdj[2]; // pointer to adjacent board.
102 
104 
105 };
106 
107 } //end of namespace bracket
108 
109 #endif // TGCPatchPanel_hh
LVL1TGCTrigger::TGCPatchPanel::showResult
void showResult() const
Definition: TGCPatchPanel.cxx:20
LVL1TGCTrigger::TGCPatchPanel::m_id
int m_id
Definition: TGCPatchPanel.h:88
LVL1TGCTrigger::TGCPatchPanel::setId
void setId(int idIn)
Definition: TGCPatchPanel.cxx:404
sendEI_SPB.ch
ch
Definition: sendEI_SPB.py:35
LVL1TGCTrigger::TGCPatchPanel::getId
int getId() const
Definition: TGCPatchPanel.cxx:399
LVL1TGCTrigger::TGCPatchPanel::clearASDOut
void clearASDOut()
Definition: TGCPatchPanel.cxx:239
LVL1TGCTrigger::TGCPatchPanel::m_type
int m_type
Definition: TGCPatchPanel.h:90
LVL1TGCTrigger::NumberOfASDChannel
const int NumberOfASDChannel
Definition: TGCPatchPanel.h:33
LVL1TGCTrigger::TGCPatchPanel::doBID
void doBID()
Definition: TGCPatchPanel.cxx:372
LVL1TGCTrigger::TGCPatchPanel::setRegion
void setRegion(TGCRegionType regionIn)
Definition: TGCPatchPanel.h:67
LVL1TGCTrigger::TGCPatchPanel::m_region
TGCRegionType m_region
Definition: TGCPatchPanel.h:91
LVL1TGCTrigger::TGCWireTripletPP
class TGCPatchPanel TGCWireTripletPP
Definition: TGCPatchPanel.h:22
LVL1TGCTrigger::TGCPatchPanel::m_connectionInPP
TGCConnectionInPP * m_connectionInPP
Definition: TGCPatchPanel.h:101
TGCConnectionPPToSB.h
CaloCondBlobAlgs_fillNoiseFromASCII.db
db
Definition: CaloCondBlobAlgs_fillNoiseFromASCII.py:43
LVL1TGCTrigger::TGCPatchPanel::getAdjacentPP
TGCPatchPanel * getAdjacentPP(int side)
Definition: TGCPatchPanel.h:49
LVL1TGCTrigger::TGCPatchPanel::dumpPPOut
void dumpPPOut()
Definition: TGCPatchPanel.cxx:249
LVL1TGCTrigger::TGCPatchPanel::getIdSlaveBoard
int getIdSlaveBoard(int port) const
Definition: TGCPatchPanel.cxx:389
LVL1TGCTrigger::TGCPatchPanel::m_ASDOut
const TGCASDOut * m_ASDOut[NChOfPPOutputConnector][MaxNumberOfConnector]
Definition: TGCPatchPanel.h:98
LVL1TGCTrigger::TGCStripTripletPP
class TGCPatchPanel TGCStripTripletPP
Definition: TGCPatchPanel.h:24
LVL1TGCTrigger::TGCConnectionInPP
Definition: TGCConnectionInPP.h:15
LVL1TGCTrigger::TGCPatchPanel::TGCPatchPanel
TGCPatchPanel(TGCArguments *)
Definition: TGCPatchPanel.cxx:94
LVL1TGCTrigger::NChOfPPOutputConnector
const int NChOfPPOutputConnector
Definition: TGCPatchPanel.h:34
LVL1TGCTrigger::TGCPatchPanel::m_PPAdj
TGCPatchPanel * m_PPAdj[2]
Definition: TGCPatchPanel.h:100
LVL1TGCTrigger::TGCWireDoubletPP
class TGCPatchPanel TGCWireDoubletPP
Definition: TGCPatchPanel.h:23
LVL1TGCTrigger::NumberOfASDOut
const int NumberOfASDOut
Definition: TGCPatchPanel.h:31
LVL1TGCTrigger::TGCPatchPanel::eraseOutput
void eraseOutput(int SBId)
Definition: TGCPatchPanel.cxx:420
TRT::Hit::side
@ side
Definition: HitInfo.h:83
LVL1TGCTrigger::TGCPatchPanel::getAdjacentPP
const TGCPatchPanel * getAdjacentPP(int side) const
Definition: TGCPatchPanel.h:50
LVL1TGCTrigger::TGCPatchPanel::TGCPatchPanel
TGCPatchPanel(const TGCPatchPanel &right)=delete
LVL1TGCTrigger::TGCPatchPanel::setASDOut
void setASDOut(int ch, int connector, const TGCASDOut *asdOut)
Definition: TGCPatchPanel.cxx:428
LVL1TGCTrigger::TGCPatchPanel::m_BIDOut
TGCBIDOut * m_BIDOut[NChOfPPOutputConnector][MaxNumberOfConnector][NumberOfBunchKeptInPP]
Definition: TGCPatchPanel.h:99
lumiFormat.i
int i
Definition: lumiFormat.py:85
LVL1TGCTrigger::TGCPatchPanel::createOutput
int createOutput()
Definition: TGCPatchPanel.cxx:270
LVL1TGCTrigger::TGCPatchPanel::m_PPOut
TGCPatchPanelOut * m_PPOut[NumberOfPatchPanelOut]
Definition: TGCPatchPanel.h:97
LVL1TGCTrigger::TGCPatchPanel::m_hasBIDOut
bool m_hasBIDOut
Definition: TGCPatchPanel.h:94
LVL1TGCTrigger::TGCPatchPanel::setType
void setType(int typeIn)
Definition: TGCPatchPanel.h:65
LVL1TGCTrigger::TGCASDOut
Definition: TGCASDOut.h:12
LVL1TGCTrigger::TGCPatchPanel::setAdjacentPP
void setAdjacentPP(int side, TGCPatchPanel *PP)
Definition: TGCPatchPanel.cxx:462
LVL1TGCTrigger::NumberOfBunchKeptInPP
const int NumberOfBunchKeptInPP
Definition: TGCPatchPanel.h:36
LVL1TGCTrigger::TGCPatchPanel::setIdSlaveBoard
void setIdSlaveBoard(int port, int id)
Definition: TGCPatchPanel.cxx:394
LVL1TGCTrigger::TGCStripDoubletPP
class TGCPatchPanel TGCStripDoubletPP
Definition: TGCPatchPanel.h:25
LVL1TGCTrigger::TGCPatchPanel::getBIDOut
TGCBIDOut * getBIDOut(int ch, int connector, int bunch)
Definition: TGCPatchPanel.cxx:360
LVL1TGCTrigger::TGCPatchPanel::getOutput
TGCPatchPanelOut * getOutput(int SBId)
Definition: TGCPatchPanel.cxx:409
LVL1TGCTrigger::TGCBIDOut
Definition: TGCBIDOut.h:12
LVL1TGCTrigger::TGCPatchPanel::deleteBIDOut
void deleteBIDOut()
Definition: TGCPatchPanel.cxx:222
LVL1TGCTrigger::TGCPatchPanel::m_nHit
int m_nHit
Definition: TGCPatchPanel.h:95
LVL1TGCTrigger
Definition: LVL1TGCTrigger.cxx:47
LVL1TGCTrigger::TGCPatchPanel::m_idSlaveBoard
int m_idSlaveBoard[NumberOfPatchPanelOut]
Definition: TGCPatchPanel.h:89
LVL1TGCTrigger::TGCPatchPanel::connect
void connect()
Definition: TGCPatchPanel.cxx:114
LVL1TGCTrigger::TGCDatabaseManager
Definition: TGCDatabaseManager.h:39
LVL1TGCTrigger::TGCPatchPanel::operator=
TGCPatchPanel & operator=(const TGCPatchPanel &right)
Definition: TGCPatchPanel.cxx:119
TGCNumbering.h
LVL1TGCTrigger::TGCPatchPanel::clockIn
void clockIn(int bunch, TGCDatabaseManager *db=0)
Definition: TGCPatchPanel.cxx:179
LVL1TGCTrigger::TGCPatchPanel::getType
int getType() const
Definition: TGCPatchPanel.h:64
LVL1TGCTrigger::TGCPatchPanel::getTypeName
std::string getTypeName(int typeIn) const
Definition: TGCPatchPanel.cxx:83
LVL1TGCTrigger::TGCPatchPanel
Definition: TGCPatchPanel.h:38
LVL1TGCTrigger::TGCArguments
Definition: TGCArguments.h:12
LVL1TGCTrigger::TGCPatchPanel::m_tgcArgs
TGCArguments * m_tgcArgs
Definition: TGCPatchPanel.h:103
LVL1TGCTrigger::TGCStripInnerPP
class TGCPatchPanel TGCStripInnerPP
Definition: TGCPatchPanel.h:27
LVL1TGCTrigger::TGCRegionType
TGCRegionType
Definition: TGCNumbering.h:49
LVL1TGCTrigger::TGCPatchPanel::getInputConnectorIndex
int getInputConnectorIndex(const int connectorId) const
Definition: TGCPatchPanel.cxx:457
LVL1TGCTrigger::TGCWireInnerPP
class TGCPatchPanel TGCWireInnerPP
Definition: TGCPatchPanel.h:26
LVL1TGCTrigger::TGCPatchPanel::tgcArgs
const TGCArguments * tgcArgs() const
Definition: TGCPatchPanel.h:77
LVL1TGCTrigger::NumberOfPPOutputConnector
const int NumberOfPPOutputConnector
Definition: TGCPatchPanel.h:32
LVL1TGCTrigger::TGCPatchPanel::~TGCPatchPanel
~TGCPatchPanel()
Definition: TGCPatchPanel.cxx:156
TGCArguments.h
LVL1TGCTrigger::TGCPatchPanel::getRegion
TGCRegionType getRegion() const
Definition: TGCPatchPanel.h:66
LVL1TGCTrigger::TGCPatchPanel::m_bunchCounter
int m_bunchCounter
Definition: TGCPatchPanel.h:92
LVL1TGCTrigger::NumberOfPatchPanelOut
const int NumberOfPatchPanelOut
Definition: TGCPatchPanel.h:30
LVL1TGCTrigger::TGCPatchPanel::m_hasASDOut
bool m_hasASDOut
Definition: TGCPatchPanel.h:93
LVL1TGCTrigger::MaxNumberOfConnector
const int MaxNumberOfConnector
Definition: TGCPatchPanel.h:35
LVL1TGCTrigger::TGCPatchPanel::showProperty
void showProperty()
Definition: TGCPatchPanel.cxx:261
LVL1TGCTrigger::TGCPatchPanel::doOrLogic
int doOrLogic()
Definition: TGCPatchPanel.cxx:320
LVL1TGCTrigger::TGCPatchPanelOut
Definition: TGCPatchPanelOut.h:17