CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Attributes | Private Member Functions | Private Attributes
DTConfigTSPhi Class Reference

#include <DTConfigTSPhi.h>

Inheritance diagram for DTConfigTSPhi:
DTConfig

Public Member Functions

bool debug () const
 Return the debug flag. More...
 
 DTConfigTSPhi (const edm::ParameterSet &ps)
 Constructor. More...
 
 DTConfigTSPhi ()
 Constructor. More...
 
 DTConfigTSPhi (bool debug, unsigned short int tss_buffer[7][31], int ntss, unsigned short int tsm_buffer[9])
 Constructor. More...
 
int nValidTSM () const
 Number of correctly configured TSS. More...
 
int nValidTSS () const
 Number of correctly configured TSS. More...
 
void print () const
 Print the setup. More...
 
void setDebug (bool debug)
 Set debug flag. More...
 
void setTsmCarryFlag (unsigned short tsmhsp)
 Handling of second track (carry) in case of pile-up, in TSM. More...
 
void setTsmCorrEna (bool tsmcce, int i)
 Enable Correlation checking in TSM for sort1/2. More...
 
void setTsmCorrEnaCarry (bool tsmcce)
 Enable Correlation checking in TSM for carry. More...
 
void setTsmGhost1Corr (bool tsmcgs1)
 Correlated ghost 1 suppression option in TSM. More...
 
void setTsmGhost1Flag (unsigned short tsmgs1)
 Ghost 1 suppression option in TSM. More...
 
void setTsmGhost2Corr (bool tsmcgs2)
 Correlated ghost 2 suppression option in TSM. More...
 
void setTsmGhost2Flag (unsigned short tsmgs2)
 Ghost 2 suppression option in TSM. More...
 
void setTsmHtrigEna (bool tsmhte, int i)
 Enable Htrig checking in TSM for sort1/2. More...
 
void setTsmHtrigEnaCarry (bool tsmhte)
 Enable Htrig checking in TSM for carry. More...
 
void setTsmInOutEna (bool tsmnoe, int i)
 Enable Inner SL checking in TSM for sort1/2. More...
 
void setTsmInOutEnaCarry (bool tsmnoe)
 Enable Inner SL checking in TSM for carry. More...
 
void setTsmMasking (unsigned short int tsmmsk, int i)
 Order of quality bits in TSM for sort1/2. More...
 
void setTsmStatus (int i, int val)
 TSM status. More...
 
void setTssCorrEna (bool tsscce, int i)
 Enable Correlation checking in TSS for sort1/2. More...
 
void setTssCorrEnaCarry (bool tsscce)
 Enable Correlation checking in TSS for. More...
 
void setTssGhost1Corr (bool tsscgs1)
 Correlated ghost 1 suppression option in TSS. More...
 
void setTssGhost1Flag (unsigned short tssgs1)
 Ghost 1 suppression option in TSS. More...
 
void setTssGhost2Corr (bool tsscgs2)
 Correlated ghost 2 suppression option in TSS. More...
 
void setTssGhost2Flag (unsigned short tssgs2)
 Ghost 2 suppression option in TSS. More...
 
void setTssHtrigEna (bool tsshte, int i)
 Enable Htrig checking in TSS for sort1/2. More...
 
void setTssHtrigEnaCarry (bool tsshte)
 Enable Htrig checking in TSS for carry. More...
 
void setTssInOutEna (bool tssnoe, int i)
 Enable Inner SL checking in TSS for sort1/2. More...
 
void setTssInOutEnaCarry (bool tssnoe)
 Enable Inner SL checking in TSS for carry. More...
 
void setTssMasking (unsigned short int tssmsk, int i)
 Order of quality bits in TSS for sort1/2. More...
 
void setUsedTraco (int i, int val)
 Enabled TRACOs in TS. More...
 
bool TsmCorrEna (int i) const
 Enable Correlation checking in TSM for sort1/2. More...
 
bool TsmCorrEnaCarry () const
 Enable Correlation checking in TSM for carry. More...
 
int TsmGetCarryFlag () const
 Handling of second track (carry) in case of pile-up, in TSM. More...
 
bool TsmGhost1Corr () const
 Correlated ghost 1 suppression option in TSM. More...
 
int TsmGhost1Flag () const
 Ghost 1 suppression option in TSM. More...
 
bool TsmGhost2Corr () const
 Correlated ghost 2 suppression option in TSM. More...
 
int TsmGhost2Flag () const
 Ghost 2 suppression option in TSM. More...
 
bool TsmHtrigEna (int i) const
 Enable Htrig checking in TSM for sort1/2. More...
 
bool TsmHtrigEnaCarry () const
 Enable Htrig checking in TSM for carry. More...
 
bool TsmInOutEna (int i) const
 Enable Inner SL checking in TSM for sort1/2. More...
 
bool TsmInOutEnaCarry () const
 Enable Inner SL checking in TSM for carry. More...
 
int TsmMasking (int i) const
 Order of quality bits in TSM for sort1/2. More...
 
BitArray< 8 > TsmStatus () const
 TSM status. More...
 
bool TssCorrEna (int i) const
 Enable Correlation checking in TSS for sort1/2. More...
 
bool TssCorrEnaCarry () const
 Enable Correlation checking in TSS for carry. More...
 
bool TssGhost1Corr () const
 Correlated ghost 1 suppression option in TSS. More...
 
int TssGhost1Flag () const
 Ghost 1 suppression option in TSS. More...
 
bool TssGhost2Corr () const
 Correlated ghost 2 suppression option in TSS. More...
 
int TssGhost2Flag () const
 Ghost 2 suppression option in TSS. More...
 
bool TssHtrigEna (int i) const
 Enable Htrig checking in TSS for sort1/2. More...
 
bool TssHtrigEnaCarry () const
 Enable Htrig checking in TSS for carry. More...
 
bool TssInOutEna (int i) const
 Enable Inner SL checking in TSS for sort1/2. More...
 
bool TssInOutEnaCarry () const
 Enable Inner SL checking in TSS for carry. More...
 
int TSSinTSMD (int stat, int sect) const
 Return the max nb. of TSSs in input to a single TSMD (called ONLY in back-up mode) More...
 
int TssMasking (int i) const
 Order of quality bits in TSS for sort1/2. More...
 
bool usedTraco (int i) const
 Enabled TRACOs in TS. More...
 
 ~DTConfigTSPhi () override
 Destructor. More...
 
- Public Member Functions inherited from DTConfig
 DTConfig ()
 Constructor. More...
 
virtual ~DTConfig ()
 Destructor. More...
 

Static Public Attributes

static const int NTSMD = 2
 Constant: number of TSMD. More...
 
static const int NTSSTSM = 7
 Constant: maximum number of TSS in input to the TSM. More...
 
static const int NTSSTSMD = 3
 Constant: maximum number of TSS in input to a single TSMD. More...
 
- Static Public Attributes inherited from DTConfig
static const int NBTITC = 4
 
static const int NSTEPF = 9
 
static const int NSTEPL = 24
 Constants: first and last step to start trigger finding. More...
 
static const int NTCTSS = 4
 Constant: number of TRACOs in input to a TSS. More...
 

Private Member Functions

bool checkMask (unsigned short) const
 Check mask correctness. More...
 
void setDefaults (const edm::ParameterSet &ps)
 Load pset values into class variables. More...
 

Private Attributes

bool m_debug
 
short int m_ntsm
 
short int m_ntss
 
bool m_tsmcce [3]
 
bool m_tsmcgs1
 
bool m_tsmcgs2
 
unsigned short int m_tsmgs1
 
unsigned short int m_tsmgs2
 
unsigned short int m_tsmhsp
 
bool m_tsmhte [3]
 
unsigned short int m_tsmmsk [2]
 
bool m_tsmnoe [3]
 
BitArray< 8 > m_tsmword
 
bool m_tsscce [3]
 
bool m_tsscgs1
 
bool m_tsscgs2
 
unsigned short int m_tssgs1
 
unsigned short int m_tssgs2
 
bool m_tsshte [3]
 
unsigned short int m_tssmsk [2]
 
bool m_tssnoe [3]
 
BitArray< 24 > m_tstren
 

Detailed Description

Configurable parameters and constants for Level-1 Muon DT Trigger - TS Phi

Author
C. Battilana

Definition at line 36 of file DTConfigTSPhi.h.

Constructor & Destructor Documentation

◆ DTConfigTSPhi() [1/3]

DTConfigTSPhi::DTConfigTSPhi ( const edm::ParameterSet ps)

Constructor.

Definition at line 34 of file DTConfigTSPhi.cc.

References debug(), print(), and setDefaults().

34  {
35  setDefaults(ps);
36  if (debug())
37  print();
38 }
void print() const
Print the setup.
void setDefaults(const edm::ParameterSet &ps)
Load pset values into class variables.
bool debug() const
Return the debug flag.
Definition: DTConfigTSPhi.h:60

◆ DTConfigTSPhi() [2/3]

DTConfigTSPhi::DTConfigTSPhi ( )
inline

Constructor.

Definition at line 51 of file DTConfigTSPhi.h.

51 {};

◆ DTConfigTSPhi() [3/3]

DTConfigTSPhi::DTConfigTSPhi ( bool  debug,
unsigned short int  tss_buffer[7][31],
int  ntss,
unsigned short int  tsm_buffer[9] 
)

Constructor.

Definition at line 40 of file DTConfigTSPhi.cc.

References gather_cfg::cout, debug(), TauDecayModes::dec, mps_fire::i, m_debug, m_ntsm, m_ntss, setTsmCarryFlag(), setTsmCorrEna(), setTsmCorrEnaCarry(), setTsmGhost1Corr(), setTsmGhost1Flag(), setTsmGhost2Corr(), setTsmGhost2Flag(), setTsmHtrigEna(), setTsmHtrigEnaCarry(), setTsmInOutEna(), setTsmInOutEnaCarry(), setTsmMasking(), setTsmStatus(), setTssCorrEna(), setTssCorrEnaCarry(), setTssGhost1Corr(), setTssGhost1Flag(), setTssGhost2Corr(), setTssGhost2Flag(), setTssHtrigEna(), setTssHtrigEnaCarry(), setTssInOutEna(), setTssInOutEnaCarry(), setTssMasking(), and setUsedTraco().

43  {
44  m_ntss = 0;
45  m_ntsm = 0;
46 
47  if (ntss == 0)
48  return;
49 
50  m_debug = debugTS;
51 
52  bool tstren[24];
53  bool tsscgs2, tsscgs1, tsscce1, tsshte1, tssnoe1, carrytss;
54  bool tsscce2, tsshte2, tssnoe2, tssccec, tsshtec, tssnoec;
55  unsigned short tssgs1, tssgs2, tssmsk1, tssmsk2;
56 
57  tsscgs2 = tsscgs1 = tsscce1 = tsshte1 = tssnoe1 = carrytss = false;
58  tsscce2 = tsshte2 = tssnoe2 = tssccec = tsshtec = tssnoec = false;
59  tssgs1 = tssgs2 = tssmsk1 = tssmsk2 = 0;
60 
61  memset(tstren, true, 24 * sizeof(bool));
62 
63  // TSS unpacking
64  for (int itss = 0; itss < ntss; itss++) {
65  unsigned short int memory_tss[27];
66 
67  for (int ts = 0; ts < 27; ts++) {
68  memory_tss[ts] = tss_buffer[itss][ts + 4];
69  //std::cout << std::hex << memory_tss[ts] << " ";
70  }
71 
72  tstren[itss * 4] = !(memory_tss[1] & 0x08);
73  tstren[itss * 4 + 1] = !(memory_tss[1] & 0x80);
74  tstren[itss * 4 + 2] = !(memory_tss[2] & 0x08);
75  tstren[itss * 4 + 3] = !(memory_tss[2] & 0x80);
76 
77  if (!itss) {
78  tsscgs2 = !(memory_tss[0] & 0x08);
79  tssgs2 = memory_tss[0] & 0x04 ? 0 : 1;
80  tsscgs1 = !(memory_tss[0] & 0x02);
81  tssgs1 = memory_tss[0] & 0x01 ? 0 : 1;
82  tsscce1 = !(memory_tss[4] & 0x04);
83  tsshte1 = !(memory_tss[4] & 0x02);
84  tssnoe1 = !(memory_tss[4] & 0x01);
85  tsscce2 = !(memory_tss[3] & 0x40);
86  tsshte2 = !(memory_tss[3] & 0x20);
87  tssnoe2 = !(memory_tss[3] & 0x10);
88  tssccec = !(memory_tss[3] & 0x04);
89  tsshtec = !(memory_tss[3] & 0x02);
90  tssnoec = !(memory_tss[3] & 0x01);
91  carrytss = !(memory_tss[4] & 0x40);
92  tssmsk1 = memory_tss[4] & 0x10 ? 132 : 312;
93  tssmsk2 = memory_tss[4] & 0x20 ? 132 : 312;
94  }
95 
96  m_ntss++;
97  }
98 
99  // TSM unpacking
100  unsigned short int memory_tsms[2], memory_tsmdu[2], memory_tsmdd[2];
101 
102  for (int ts = 0; ts < 2; ts++) {
103  memory_tsms[ts] = tsm_buffer[ts + 3];
104  memory_tsmdu[ts] = tsm_buffer[ts + 5];
105  memory_tsmdd[ts] = tsm_buffer[ts + 7];
106  //std::cout << std::hex << memory_tsms[ts] << " "
107  //<< memory_tsmdu[ts] << " " << memory_tsmdd[ts] << " " << std::endl;
108  }
109 
110  bool tsmcgs1 = true;
111  unsigned short tsmgs1 = memory_tsms[1] & 0x02 ? 0 : 1;
112  bool tsmcgs2 = true;
113  unsigned short tsmgs2 = 1;
114  bool tsmcce1 = true;
115  bool tsmhte1 = true;
116  bool tsmnoe1 = true;
117  bool tsmcce2 = true;
118  bool tsmhte2 = true;
119  bool tsmnoe2 = true;
120  bool tsmccec = true;
121  bool tsmhtec = true;
122  bool tsmnoec = true;
123  bool carrytsms = !(memory_tsms[1] & 0x01);
124  unsigned short tsmmsk1 = memory_tsms[1] & 0x08 ? 321 : 312;
125  unsigned short tsmmsk2 = tsmmsk1;
126  bool tsmword[8];
127  tsmword[0] = !((memory_tsmdu[0] & 0x80) && (memory_tsmdd[0] & 0x80));
128  tsmword[1] = !(memory_tsms[0] & 0x01);
129  tsmword[2] = !(memory_tsms[0] & 0x02);
130  tsmword[3] = !(memory_tsms[0] & 0x04);
131  tsmword[4] = !(memory_tsms[0] & 0x08);
132  tsmword[5] = !(memory_tsms[0] & 0x10);
133  tsmword[6] = !(memory_tsms[0] & 0x20);
134  tsmword[7] = !(memory_tsms[0] & 0x40);
135  bool carrytsmd = !((memory_tsmdu[0] & 0x10) && (memory_tsmdd[0] & 0x10));
136 
137  unsigned short tsmhsp = carrytss && carrytsms && carrytsmd;
138 
139  m_ntsm++;
140 
141  if (debug()) {
142  std::cout << "TSS :" << std::dec << std::endl << "tstren= ";
143  for (int i = 0; i < 24; i++)
144  std::cout << tstren[i] << " ";
145  std::cout << " tsscgs1=" << tsscgs1 << " tssgs1=" << tssgs1 << " tsscgs2=" << tsscgs2 << " tssgs2=" << tssgs2
146  << " tsscce1=" << tsscce1 << " tsshte1=" << tsshte1 << " tssnoe1=" << tssnoe1 << " tsscce2=" << tsscce2
147  << " tsshte2=" << tsshte2 << " tssnoe2=" << tssnoe2 << " tssccec=" << tssccec << " tsshtec=" << tsshtec
148  << " tssnoec=" << tssnoec << " carrytss=" << carrytss << " tssmsk1=" << tssmsk1 << " tssmsk2=" << tssmsk2
149  << std::endl;
150 
151  std::cout << "TSM : " << std::endl
152  << "tsmcgs1=" << tsmcgs1 << " tsmgs1=" << tsmgs1 << " tsmcgs2=" << tsmcgs2 << " tsmgs2=" << tsmgs2
153  << " tsmcce1=" << tsmcce1 << " tsmhte1=" << tsmhte1 << " tsmnoe1=" << tsmnoe1 << " tsmcce2=" << tsmcce2
154  << " tsmhte2=" << tsmhte2 << " tsmnoe2=" << tsmnoe2 << " tsmccec=" << tsmccec << " tsmhtec=" << tsmhtec
155  << " tsmnoec=" << tsmnoec << " tsmhsp=" << tsmhsp << " carrytsms=" << carrytsms
156  << " carrytsmd=" << carrytsmd << " tsmword=";
157  for (int i = 0; i < 8; i++)
158  std::cout << tsmword[i] << " ";
159  std::cout << " tsmmsk1=" << tsmmsk1 << " tsmmsk2=" << tsmmsk2 << std::endl;
160  }
161 
162  setTssMasking(tssmsk1, 1);
163  setTssMasking(tssmsk2, 2);
164  setTssHtrigEna(tsshte1, 1);
165  setTssHtrigEna(tsshte2, 2);
166  setTssHtrigEnaCarry(tsshtec);
167  setTssInOutEna(tssnoe1, 1);
168  setTssInOutEna(tssnoe2, 2);
169  setTssInOutEnaCarry(tssnoec);
170  setTssCorrEna(tsscce1, 1);
171  setTssCorrEna(tsscce2, 2);
172  setTssCorrEnaCarry(tssccec);
173  setTssGhost1Flag(tssgs1);
174  setTssGhost2Flag(tssgs2);
175  setTssGhost1Corr(tsscgs1);
176  setTssGhost2Corr(tsscgs2);
177 
178  setTsmMasking(tsmmsk1, 1);
179  setTsmMasking(tsmmsk2, 2);
180  setTsmHtrigEna(tsmhte1, 1);
181  setTsmHtrigEna(tsmhte2, 2);
182  setTsmHtrigEnaCarry(tsmhtec);
183  setTsmInOutEna(tsmnoe1, 1);
184  setTsmInOutEna(tsmnoe2, 2);
185  setTsmInOutEnaCarry(tsmnoec);
186  setTsmCorrEna(tsmcce1, 1);
187  setTsmCorrEna(tsmcce2, 2);
188  setTsmCorrEnaCarry(tsmccec);
189  setTsmGhost1Flag(tsmgs1);
190  setTsmGhost2Flag(tsmgs2);
191  setTsmGhost1Corr(tsmcgs1);
192  setTsmGhost2Corr(tsmcgs2);
193  setTsmCarryFlag(tsmhsp);
194 
195  for (int i = 0; i < 24; i++)
196  setUsedTraco(i, tstren[i]);
197  for (int i = 0; i < 8; i++)
198  setTsmStatus(i, tsmword[i]);
199 }
void setTssGhost2Corr(bool tsscgs2)
Correlated ghost 2 suppression option in TSS.
void setTsmCorrEna(bool tsmcce, int i)
Enable Correlation checking in TSM for sort1/2.
void setTsmInOutEnaCarry(bool tsmnoe)
Enable Inner SL checking in TSM for carry.
void setTssHtrigEna(bool tsshte, int i)
Enable Htrig checking in TSS for sort1/2.
void setTssGhost1Corr(bool tsscgs1)
Correlated ghost 1 suppression option in TSS.
void setTssMasking(unsigned short int tssmsk, int i)
Order of quality bits in TSS for sort1/2.
void setTssGhost1Flag(unsigned short tssgs1)
Ghost 1 suppression option in TSS.
void setTsmCorrEnaCarry(bool tsmcce)
Enable Correlation checking in TSM for carry.
void setUsedTraco(int i, int val)
Enabled TRACOs in TS.
void setTsmInOutEna(bool tsmnoe, int i)
Enable Inner SL checking in TSM for sort1/2.
void setTssGhost2Flag(unsigned short tssgs2)
Ghost 2 suppression option in TSS.
void setTsmGhost1Corr(bool tsmcgs1)
Correlated ghost 1 suppression option in TSM.
void setTsmCarryFlag(unsigned short tsmhsp)
Handling of second track (carry) in case of pile-up, in TSM.
void setTssHtrigEnaCarry(bool tsshte)
Enable Htrig checking in TSS for carry.
void setTsmGhost2Corr(bool tsmcgs2)
Correlated ghost 2 suppression option in TSM.
short int m_ntss
void setTssCorrEna(bool tsscce, int i)
Enable Correlation checking in TSS for sort1/2.
void setTsmGhost2Flag(unsigned short tsmgs2)
Ghost 2 suppression option in TSM.
void setTsmGhost1Flag(unsigned short tsmgs1)
Ghost 1 suppression option in TSM.
void setTsmHtrigEna(bool tsmhte, int i)
Enable Htrig checking in TSM for sort1/2.
void setTsmStatus(int i, int val)
TSM status.
short int m_ntsm
void setTssCorrEnaCarry(bool tsscce)
Enable Correlation checking in TSS for.
void setTsmMasking(unsigned short int tsmmsk, int i)
Order of quality bits in TSM for sort1/2.
void setTsmHtrigEnaCarry(bool tsmhte)
Enable Htrig checking in TSM for carry.
void setTssInOutEnaCarry(bool tssnoe)
Enable Inner SL checking in TSS for carry.
void setTssInOutEna(bool tssnoe, int i)
Enable Inner SL checking in TSS for sort1/2.
bool debug() const
Return the debug flag.
Definition: DTConfigTSPhi.h:60

◆ ~DTConfigTSPhi()

DTConfigTSPhi::~DTConfigTSPhi ( )
override

Destructor.

Definition at line 204 of file DTConfigTSPhi.cc.

204 {}

Member Function Documentation

◆ checkMask()

bool DTConfigTSPhi::checkMask ( unsigned short  msk) const
private

Check mask correctness.

Definition at line 456 of file DTConfigTSPhi.cc.

References mps_fire::i.

Referenced by nValidTSM(), nValidTSS(), and setDefaults().

456  {
457  bool hasone = false;
458  bool hastwo = false;
459  bool hasthree = false;
460  for (int i = 0; i < 3; i++) {
461  int mynum = msk % 10;
462  switch (mynum) {
463  case 1:
464  hasone = true;
465  break;
466  case 2:
467  hastwo = true;
468  break;
469  case 3:
470  hasthree = true;
471  break;
472  }
473  msk /= 10;
474  }
475  if (hasone == true && hastwo == true && hasthree == true)
476  return true;
477  return false;
478 }

◆ debug()

bool DTConfigTSPhi::debug ( ) const
inline

Return the debug flag.

Definition at line 60 of file DTConfigTSPhi.h.

References m_debug.

Referenced by DTConfigTSPhi(), print(), DTTSPhi::runTSPhi(), and setDebug().

60 { return m_debug; }

◆ nValidTSM()

int DTConfigTSPhi::nValidTSM ( ) const

Number of correctly configured TSS.

Definition at line 447 of file DTConfigTSPhi.cc.

References checkMask(), m_ntsm, TsmGetCarryFlag(), TsmGhost1Flag(), TsmGhost2Flag(), and TsmMasking().

Referenced by DTConfigDBProducer::checkDTCCBConfig().

447  {
448  bool isMaskValid = checkMask(TsmMasking(0)) && checkMask(TsmMasking(1));
449  bool isGsValid = (TsmGhost1Flag() >= 0 && TsmGhost1Flag() < 3) && (TsmGhost2Flag() >= 0 && TsmGhost2Flag() < 5);
450  bool isCarryValid = TsmGetCarryFlag() >= 0 && TsmGetCarryFlag() < 3;
451  int nValidTSM = static_cast<int>(isMaskValid && isGsValid && isCarryValid ? m_ntsm : 0);
452 
453  return nValidTSM;
454 }
int nValidTSM() const
Number of correctly configured TSS.
int TsmMasking(int i) const
Order of quality bits in TSM for sort1/2.
Definition: DTConfigTSPhi.h:84
int TsmGhost1Flag() const
Ghost 1 suppression option in TSM.
int TsmGetCarryFlag() const
Handling of second track (carry) in case of pile-up, in TSM.
bool checkMask(unsigned short) const
Check mask correctness.
int TsmGhost2Flag() const
Ghost 2 suppression option in TSM.
short int m_ntsm

◆ nValidTSS()

int DTConfigTSPhi::nValidTSS ( ) const

Number of correctly configured TSS.

Definition at line 439 of file DTConfigTSPhi.cc.

References checkMask(), m_ntss, TssGhost1Flag(), TssGhost2Flag(), and TssMasking().

Referenced by DTConfigDBProducer::checkDTCCBConfig().

439  {
440  bool isMaskValid = checkMask(TssMasking(0)) && checkMask(TssMasking(1));
441  bool isGsValid = (TssGhost1Flag() >= 0 && TssGhost1Flag() < 3) && (TssGhost2Flag() >= 0 && TssGhost2Flag() < 5);
442  int nValidTSS = static_cast<int>(isMaskValid && isGsValid ? m_ntss : 0);
443 
444  return nValidTSS;
445 }
int TssGhost1Flag() const
Ghost 1 suppression option in TSS.
int nValidTSS() const
Number of correctly configured TSS.
bool checkMask(unsigned short) const
Check mask correctness.
short int m_ntss
int TssGhost2Flag() const
Ghost 2 suppression option in TSS.
int TssMasking(int i) const
Order of quality bits in TSS for sort1/2.
Definition: DTConfigTSPhi.h:63

◆ print()

void DTConfigTSPhi::print ( void  ) const

Print the setup.

Definition at line 402 of file DTConfigTSPhi.cc.

References gather_cfg::cout, debug(), mps_fire::i, BitArray< N >::print(), TsmCorrEna(), TsmCorrEnaCarry(), TsmGetCarryFlag(), TsmGhost1Corr(), TsmGhost1Flag(), TsmGhost2Corr(), TsmGhost2Flag(), TsmHtrigEna(), TsmHtrigEnaCarry(), TsmInOutEna(), TsmInOutEnaCarry(), TsmMasking(), TsmStatus(), TssCorrEna(), TssCorrEnaCarry(), TssGhost1Corr(), TssGhost1Flag(), TssGhost2Corr(), TssGhost2Flag(), TssHtrigEna(), TssHtrigEnaCarry(), TssInOutEna(), TssInOutEnaCarry(), TssMasking(), and usedTraco().

Referenced by DTConfigTester::analyze(), and DTConfigTSPhi().

402  {
403  std::cout << "******************************************************************************" << std::endl;
404  std::cout << "* DTTrigger configuration : TSPhi chips *" << std::endl;
405  std::cout << "******************************************************************************" << std::endl
406  << std::endl;
407  std::cout << "Debug flag : " << debug() << std::endl;
408  std::cout << " TSS Parameters:" << std::endl;
409  std::cout << "TSSMSK 1/2:" << TssMasking(0) << " " << TssMasking(1) << std::endl;
410  std::cout << "TSSHTE 1/2/carry :" << TssHtrigEna(0) << " " << TssHtrigEna(1) << " " << TssHtrigEnaCarry()
411  << std::endl;
412  std::cout << "TSSNOE 1/2/carry :" << TssInOutEna(0) << " " << TssInOutEna(1) << " " << TssInOutEnaCarry()
413  << std::endl;
414  std::cout << "TSSCCE 1/2/carry :" << TssCorrEna(0) << " " << TssCorrEna(1) << " " << TssCorrEnaCarry() << std::endl;
415  std::cout << "TSSGS 1/2:" << TssGhost1Flag() << " " << TssGhost2Flag() << std::endl;
416  std::cout << "TSSCGS 1/2:" << TssGhost1Corr() << " " << TssGhost2Corr() << std::endl;
417  std::cout << " TSM Parameters:" << std::endl;
418  std::cout << "TSMMSK 1/2:" << TsmMasking(0) << " " << TsmMasking(1) << std::endl;
419  std::cout << "TSMHTE 1/2/carry :" << TsmHtrigEna(0) << " " << TsmHtrigEna(1) << " " << TsmHtrigEnaCarry()
420  << std::endl;
421  std::cout << "TSMNOE 1/2/carry :" << TsmInOutEna(0) << " " << TsmInOutEna(1) << " " << TsmInOutEnaCarry()
422  << std::endl;
423  std::cout << "TSMCCE 1/2/carry :" << TsmCorrEna(0) << " " << TsmCorrEna(1) << " " << TsmCorrEnaCarry() << std::endl;
424  std::cout << "TSMGS 1/2:" << TsmGhost1Flag() << " " << TsmGhost2Flag() << std::endl;
425  std::cout << "TSMCGS 1/2:" << TsmGhost1Corr() << " " << TsmGhost2Corr() << std::endl;
426  std::cout << "TSMHSP :" << TsmGetCarryFlag() << std::endl;
427  std::cout << "TSTREN[i] :";
428  for (int i = 1; i < 25; i++)
429  std::cout << usedTraco(i) << " ";
430  std::cout << std::endl;
431  std::cout << "TSMWORD :";
432  TsmStatus().print();
433  std::cout << std::endl;
434  // int stat=4, sect=5;
435  // std::cout << "TSSTSMD(4,14 :" << TSSinTSMD(stat,sect) << std::endl;
436  std::cout << "******************************************************************************" << std::endl;
437 }
bool TssHtrigEna(int i) const
Enable Htrig checking in TSS for sort1/2.
Definition: DTConfigTSPhi.h:66
int TssGhost1Flag() const
Ghost 1 suppression option in TSS.
int TsmMasking(int i) const
Order of quality bits in TSM for sort1/2.
Definition: DTConfigTSPhi.h:84
bool TsmHtrigEna(int i) const
Enable Htrig checking in TSM for sort1/2.
Definition: DTConfigTSPhi.h:87
BitArray< 8 > TsmStatus() const
TSM status.
int TsmGhost1Flag() const
Ghost 1 suppression option in TSM.
bool TsmInOutEnaCarry() const
Enable Inner SL checking in TSM for carry.
Definition: DTConfigTSPhi.h:96
int TsmGetCarryFlag() const
Handling of second track (carry) in case of pile-up, in TSM.
bool TssGhost2Corr() const
Correlated ghost 2 suppression option in TSS.
std::ostream & print(std::ostream &o=std::cout) const
Definition: BitArray.h:340
bool TssCorrEnaCarry() const
Enable Correlation checking in TSS for carry.
Definition: DTConfigTSPhi.h:81
bool usedTraco(int i) const
Enabled TRACOs in TS.
bool TsmCorrEna(int i) const
Enable Correlation checking in TSM for sort1/2.
Definition: DTConfigTSPhi.h:99
bool TssHtrigEnaCarry() const
Enable Htrig checking in TSS for carry.
Definition: DTConfigTSPhi.h:69
bool TssCorrEna(int i) const
Enable Correlation checking in TSS for sort1/2.
Definition: DTConfigTSPhi.h:78
bool TsmGhost2Corr() const
Correlated ghost 2 suppression option in TSM.
int TsmGhost2Flag() const
Ghost 2 suppression option in TSM.
bool TssInOutEnaCarry() const
Enable Inner SL checking in TSS for carry.
Definition: DTConfigTSPhi.h:75
bool TssInOutEna(int i) const
Enable Inner SL checking in TSS for sort1/2.
Definition: DTConfigTSPhi.h:72
int TssGhost2Flag() const
Ghost 2 suppression option in TSS.
bool TssGhost1Corr() const
Correlated ghost 1 suppression option in TSS.
int TssMasking(int i) const
Order of quality bits in TSS for sort1/2.
Definition: DTConfigTSPhi.h:63
bool TsmHtrigEnaCarry() const
Enable Htrig checking in TSM for carry.
Definition: DTConfigTSPhi.h:90
bool TsmInOutEna(int i) const
Enable Inner SL checking in TSM for sort1/2.
Definition: DTConfigTSPhi.h:93
bool TsmCorrEnaCarry() const
Enable Correlation checking in TSM for carry.
bool debug() const
Return the debug flag.
Definition: DTConfigTSPhi.h:60
bool TsmGhost1Corr() const
Correlated ghost 1 suppression option in TSM.

◆ setDebug()

void DTConfigTSPhi::setDebug ( bool  debug)
inline

Set debug flag.

Definition at line 143 of file DTConfigTSPhi.h.

References debug(), and m_debug.

143 { m_debug = debug; }
bool debug() const
Return the debug flag.
Definition: DTConfigTSPhi.h:60

◆ setDefaults()

void DTConfigTSPhi::setDefaults ( const edm::ParameterSet ps)
private

Load pset values into class variables.

Enabled TRACOs in TS

Definition at line 210 of file DTConfigTSPhi.cc.

References checkMask(), edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), mps_fire::i, m_debug, m_ntsm, m_ntss, m_tsmcce, m_tsmcgs1, m_tsmcgs2, m_tsmgs1, m_tsmgs2, m_tsmhsp, m_tsmhte, m_tsmmsk, m_tsmnoe, m_tsmword, m_tsscce, m_tsscgs1, m_tsscgs2, m_tssgs1, m_tssgs2, m_tsshte, m_tssmsk, m_tssnoe, m_tstren, BitArray< N >::one(), and BitArray< N >::unset().

Referenced by DTConfigTSPhi().

210  {
211  m_ntss = 1; //dummy param used only in DB config
212  m_ntsm = 1; //dummy param used only in DB config
213 
214  // Debug flag
215  m_debug = ps.getUntrackedParameter<bool>("Debug");
216 
217  // Order of quaity bits in TSS for sort1
218  int mymsk = ps.getParameter<int>("TSSMSK1");
219  if (checkMask(mymsk))
220  m_tssmsk[0] = mymsk;
221  else {
222  edm::LogVerbatim("DTTPG") << "DTConfigTSPhi::setDefaults : TSSMSK1 not in correct form: " << mymsk << std::endl;
223  }
224 
225  // Order of quaity bits in TSS for sort2
226  mymsk = ps.getParameter<int>("TSSMSK2");
227  if (checkMask(mymsk))
228  m_tssmsk[1] = mymsk;
229  else {
230  edm::LogVerbatim("DTTPG") << "DTConfigTSPhi::setDefaults : TSSMSK2 not in correct form: " << mymsk << std::endl;
231  }
232 
233  // Htrig checking in TSS for sort1
234  m_tsshte[0] = ps.getParameter<bool>("TSSHTE1");
235 
236  // Htrig checking in TSS for sort2
237  m_tsshte[1] = ps.getParameter<bool>("TSSHTE2");
238 
239  // Htrig checking in TSS for carry
240  m_tsshte[2] = ps.getParameter<bool>("TSSHTEC");
241 
242  // Inner SL checking in TSS for sort1
243  m_tssnoe[0] = ps.getParameter<bool>("TSSNOE1");
244 
245  // Inner SL checking in TSS for sort2
246  m_tssnoe[1] = ps.getParameter<bool>("TSSNOE2");
247 
248  // Inner SL checking in TSS for carry
249  m_tssnoe[2] = ps.getParameter<bool>("TSSNOEC");
250 
251  // Correlation checking in TSS for sort1
252  m_tsscce[0] = ps.getParameter<bool>("TSSCCE1");
253 
254  // Correlation checking in TSS for sort2
255  m_tsscce[1] = ps.getParameter<bool>("TSSCCE2");
256 
257  // Correlation checking in TSS for carry
258  m_tsscce[2] = ps.getParameter<bool>("TSSCCEC");
259 
260  // Ghost 1 supperssion option in TSS
261  int mygs = ps.getParameter<int>("TSSGS1");
262  if (mygs >= 0 && mygs < 3)
263  m_tssgs1 = mygs;
264  else {
265  edm::LogVerbatim("DTTPG") << "DTConfigTSPhi::setDefaults : TSSGS1 value is not correct: " << mygs << std::endl;
266  }
267 
268  // Ghost 2 supperssion option in TSS
269  mygs = ps.getParameter<int>("TSSGS2");
270  if (mygs >= 0 && mygs < 5)
271  m_tssgs2 = mygs;
272  else {
273  edm::LogVerbatim("DTTPG") << "DTConfigTSPhi::setDefaults : TSSGS2 value is not correct: " << mygs << std::endl;
274  }
275 
276  // Correlated ghost 1 supperssion option in TSS
277  m_tsscgs1 = ps.getParameter<bool>("TSSCGS1");
278 
279  // Correlated ghost 2 supperssion option in TSS
280  m_tsscgs2 = ps.getParameter<bool>("TSSCGS2");
281 
282  // Order of quaity bits in TSM for sort1
283  mymsk = ps.getParameter<int>("TSMMSK1");
284  if (checkMask(mymsk))
285  m_tsmmsk[0] = mymsk;
286  else {
287  edm::LogVerbatim("DTTPG") << "DTConfigTSPhi::setDefaults : TSMMSK1 not in correct form: " << mymsk << std::endl;
288  }
289 
290  // Order of quaity bits in TSM for sort2
291  mymsk = ps.getParameter<int>("TSMMSK2");
292  if (checkMask(mymsk))
293  m_tsmmsk[1] = mymsk;
294  else {
295  edm::LogVerbatim("DTTPG") << "DTConfigTSPhi::setDefaults : TSMMSK2 not in correct form: " << mymsk << std::endl;
296  }
297 
298  // Htrig checking in TSM for sort1
299  m_tsmhte[0] = ps.getParameter<bool>("TSMHTE1");
300 
301  // Htrig checking in TSM for sort2
302  m_tsmhte[1] = ps.getParameter<bool>("TSMHTE2");
303 
304  // Htrig checking in TSM for carry
305  m_tsmhte[2] = ps.getParameter<bool>("TSMHTEC");
306 
307  // Inner SL checking in TSM for sort1
308  m_tsmnoe[0] = ps.getParameter<bool>("TSMNOE1");
309 
310  // Inner SL checking in TSM for sort2
311  m_tsmnoe[1] = ps.getParameter<bool>("TSMNOE2");
312 
313  // Inner SL checking in TSM for carry
314  m_tsmnoe[2] = ps.getParameter<bool>("TSMNOEC");
315 
316  // Correlation checking in TSM for sort1
317  m_tsmcce[0] = ps.getParameter<bool>("TSMCCE1");
318 
319  // Correlation checking in TSM for sort2
320  m_tsmcce[1] = ps.getParameter<bool>("TSMCCE2");
321 
322  // Correlation checking in TSM for carry
323  m_tsmcce[2] = ps.getParameter<bool>("TSMCCEC");
324 
325  // Ghost 1 supperssion option in TSM
326  mygs = ps.getParameter<int>("TSMGS1");
327  if (mygs >= 0 && mygs < 3)
328  m_tsmgs1 = mygs;
329  else {
330  edm::LogVerbatim("DTTPG") << "DTConfigTSPhi::setDefaults : TSMGS1 value is not correct: " << mygs << std::endl;
331  }
332 
333  // Ghost 2 supperssion option in TSM
334  mygs = ps.getParameter<int>("TSMGS2");
335  if (mygs >= 0 && mygs < 5)
336  m_tsmgs2 = mygs;
337  else {
338  edm::LogVerbatim("DTTPG") << "DTConfigTSPhi::setDefaults : TSMGS2 value is not correct: " << mygs << std::endl;
339  }
340 
341  // Correlated ghost 1 supperssion option in TSM
342  m_tsmcgs1 = ps.getParameter<bool>("TSMCGS1");
343 
344  // Correlated ghost 2 supperssion option in TSM
345  m_tsmcgs2 = ps.getParameter<bool>("TSMCGS2");
346 
347  // Handling carry in case of pile-up
348  int myhsp = ps.getParameter<int>("TSMHSP");
349  if (myhsp >= 0 && myhsp < 3)
350  m_tsmhsp = myhsp;
351  else {
352  edm::LogVerbatim("DTTPG") << "DTConfigTSPhi::setDefaults : TSMHSP value is not correct: " << myhsp << std::endl;
353  }
354 
355  // Handling TSMS masking parameters
356  m_tsmword.one();
357  int word = ps.getParameter<int>("TSMWORD");
358  if (word < 0 || word > 255) {
359  edm::LogVerbatim("DTTPG") << "DTConfigTSPhi::setDefaults : TSMWORD value is not correct: " << word << std::endl;
360  }
361  for (int i = 0; i < 7; i++) {
362  short int bit = word % 2;
363  word /= 2;
364  if (bit == 0)
365  m_tsmword.unset(i);
366  }
367 
369  m_tstren.one();
370  for (int i = 0; i < 24; i++) {
371  std::stringstream os;
372  os << "TSTREN" << i;
373  if (ps.getParameter<bool>(os.str()) == 0)
374  m_tstren.unset(i);
375  }
376 }
Log< level::Info, true > LogVerbatim
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
bool m_tssnoe[3]
unsigned short int m_tssgs1
unsigned short int m_tsmgs2
unsigned short int m_tsmhsp
unsigned short int m_tsmmsk[2]
T getUntrackedParameter(std::string const &, T const &) const
bool m_tsmcce[3]
uint64_t word
bool m_tsmhte[3]
void one()
Definition: BitArray.h:217
bool m_tsshte[3]
bool checkMask(unsigned short) const
Check mask correctness.
BitArray< 8 > m_tsmword
unsigned short int m_tsmgs1
BitArray< 24 > m_tstren
void unset(const int i)
Definition: BitArray.h:225
short int m_ntss
bool m_tsmnoe[3]
bool m_tsscce[3]
short int m_ntsm
unsigned short int m_tssmsk[2]
unsigned short int m_tssgs2

◆ setTsmCarryFlag()

void DTConfigTSPhi::setTsmCarryFlag ( unsigned short  tsmhsp)
inline

Handling of second track (carry) in case of pile-up, in TSM.

Definition at line 212 of file DTConfigTSPhi.h.

References m_tsmhsp.

Referenced by DTConfigTSPhi().

212 { m_tsmhsp = tsmhsp; }
unsigned short int m_tsmhsp

◆ setTsmCorrEna()

void DTConfigTSPhi::setTsmCorrEna ( bool  tsmcce,
int  i 
)
inline

Enable Correlation checking in TSM for sort1/2.

Definition at line 182 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tsmcce.

Referenced by DTConfigTSPhi().

182 { m_tsmcce[i - 1] = tsmcce; }
bool m_tsmcce[3]

◆ setTsmCorrEnaCarry()

void DTConfigTSPhi::setTsmCorrEnaCarry ( bool  tsmcce)
inline

Enable Correlation checking in TSM for carry.

Definition at line 185 of file DTConfigTSPhi.h.

References m_tsmcce.

Referenced by DTConfigTSPhi().

185 { m_tsmcce[2] = tsmcce; }
bool m_tsmcce[3]

◆ setTsmGhost1Corr()

void DTConfigTSPhi::setTsmGhost1Corr ( bool  tsmcgs1)
inline

Correlated ghost 1 suppression option in TSM.

Definition at line 206 of file DTConfigTSPhi.h.

References m_tsmcgs1.

Referenced by DTConfigTSPhi().

206 { m_tsmcgs1 = tsmcgs1; }

◆ setTsmGhost1Flag()

void DTConfigTSPhi::setTsmGhost1Flag ( unsigned short  tsmgs1)
inline

Ghost 1 suppression option in TSM.

Definition at line 194 of file DTConfigTSPhi.h.

References m_tsmgs1.

Referenced by DTConfigTSPhi().

194 { m_tsmgs1 = tsmgs1; }
unsigned short int m_tsmgs1

◆ setTsmGhost2Corr()

void DTConfigTSPhi::setTsmGhost2Corr ( bool  tsmcgs2)
inline

Correlated ghost 2 suppression option in TSM.

Definition at line 209 of file DTConfigTSPhi.h.

References m_tsmcgs2.

Referenced by DTConfigTSPhi().

209 { m_tsmcgs2 = tsmcgs2; }

◆ setTsmGhost2Flag()

void DTConfigTSPhi::setTsmGhost2Flag ( unsigned short  tsmgs2)
inline

Ghost 2 suppression option in TSM.

Definition at line 197 of file DTConfigTSPhi.h.

References m_tsmgs2.

Referenced by DTConfigTSPhi().

197 { m_tsmgs2 = tsmgs2; }
unsigned short int m_tsmgs2

◆ setTsmHtrigEna()

void DTConfigTSPhi::setTsmHtrigEna ( bool  tsmhte,
int  i 
)
inline

Enable Htrig checking in TSM for sort1/2.

Definition at line 170 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tsmhte.

Referenced by DTConfigTSPhi().

170 { m_tsmhte[i - 1] = tsmhte; }
bool m_tsmhte[3]

◆ setTsmHtrigEnaCarry()

void DTConfigTSPhi::setTsmHtrigEnaCarry ( bool  tsmhte)
inline

Enable Htrig checking in TSM for carry.

Definition at line 173 of file DTConfigTSPhi.h.

References m_tsmhte.

Referenced by DTConfigTSPhi().

173 { m_tsmhte[2] = tsmhte; }
bool m_tsmhte[3]

◆ setTsmInOutEna()

void DTConfigTSPhi::setTsmInOutEna ( bool  tsmnoe,
int  i 
)
inline

Enable Inner SL checking in TSM for sort1/2.

Definition at line 176 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tsmnoe.

Referenced by DTConfigTSPhi().

176 { m_tsmnoe[i - 1] = tsmnoe; }
bool m_tsmnoe[3]

◆ setTsmInOutEnaCarry()

void DTConfigTSPhi::setTsmInOutEnaCarry ( bool  tsmnoe)
inline

Enable Inner SL checking in TSM for carry.

Definition at line 179 of file DTConfigTSPhi.h.

References m_tsmnoe.

Referenced by DTConfigTSPhi().

179 { m_tsmnoe[2] = tsmnoe; }
bool m_tsmnoe[3]

◆ setTsmMasking()

void DTConfigTSPhi::setTsmMasking ( unsigned short int  tsmmsk,
int  i 
)
inline

Order of quality bits in TSM for sort1/2.

Definition at line 167 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tsmmsk.

Referenced by DTConfigTSPhi().

167 { m_tsmmsk[i - 1] = tsmmsk; }
unsigned short int m_tsmmsk[2]

◆ setTsmStatus()

void DTConfigTSPhi::setTsmStatus ( int  i,
int  val 
)
inline

TSM status.

Definition at line 218 of file DTConfigTSPhi.h.

References mps_fire::i, m_tsmword, BitArray< N >::set(), and heppy_batch::val.

Referenced by DTConfigTSPhi().

218 { m_tsmword.set(i, val); };
BitArray< 8 > m_tsmword
void set(const int i)
Definition: BitArray.h:224

◆ setTssCorrEna()

void DTConfigTSPhi::setTssCorrEna ( bool  tsscce,
int  i 
)
inline

Enable Correlation checking in TSS for sort1/2.

Definition at line 161 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tsscce.

Referenced by DTConfigTSPhi().

161 { m_tsscce[i - 1] = tsscce; }
bool m_tsscce[3]

◆ setTssCorrEnaCarry()

void DTConfigTSPhi::setTssCorrEnaCarry ( bool  tsscce)
inline

Enable Correlation checking in TSS for.

Definition at line 164 of file DTConfigTSPhi.h.

References m_tsscce.

Referenced by DTConfigTSPhi().

164 { m_tsscce[2] = tsscce; }
bool m_tsscce[3]

◆ setTssGhost1Corr()

void DTConfigTSPhi::setTssGhost1Corr ( bool  tsscgs1)
inline

Correlated ghost 1 suppression option in TSS.

Definition at line 200 of file DTConfigTSPhi.h.

References m_tsscgs1.

Referenced by DTConfigTSPhi().

200 { m_tsscgs1 = tsscgs1; }

◆ setTssGhost1Flag()

void DTConfigTSPhi::setTssGhost1Flag ( unsigned short  tssgs1)
inline

Ghost 1 suppression option in TSS.

Definition at line 188 of file DTConfigTSPhi.h.

References m_tssgs1.

Referenced by DTConfigTSPhi().

188 { m_tssgs1 = tssgs1; }
unsigned short int m_tssgs1

◆ setTssGhost2Corr()

void DTConfigTSPhi::setTssGhost2Corr ( bool  tsscgs2)
inline

Correlated ghost 2 suppression option in TSS.

Definition at line 203 of file DTConfigTSPhi.h.

References m_tsscgs2.

Referenced by DTConfigTSPhi().

203 { m_tsscgs2 = tsscgs2; }

◆ setTssGhost2Flag()

void DTConfigTSPhi::setTssGhost2Flag ( unsigned short  tssgs2)
inline

Ghost 2 suppression option in TSS.

Definition at line 191 of file DTConfigTSPhi.h.

References m_tssgs2.

Referenced by DTConfigTSPhi().

191 { m_tssgs2 = tssgs2; }
unsigned short int m_tssgs2

◆ setTssHtrigEna()

void DTConfigTSPhi::setTssHtrigEna ( bool  tsshte,
int  i 
)
inline

Enable Htrig checking in TSS for sort1/2.

Definition at line 149 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tsshte.

Referenced by DTConfigTSPhi().

149 { m_tsshte[i - 1] = tsshte; }
bool m_tsshte[3]

◆ setTssHtrigEnaCarry()

void DTConfigTSPhi::setTssHtrigEnaCarry ( bool  tsshte)
inline

Enable Htrig checking in TSS for carry.

Definition at line 152 of file DTConfigTSPhi.h.

References m_tsshte.

Referenced by DTConfigTSPhi().

152 { m_tsshte[2] = tsshte; }
bool m_tsshte[3]

◆ setTssInOutEna()

void DTConfigTSPhi::setTssInOutEna ( bool  tssnoe,
int  i 
)
inline

Enable Inner SL checking in TSS for sort1/2.

Definition at line 155 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tssnoe.

Referenced by DTConfigTSPhi().

155 { m_tssnoe[i - 1] = tssnoe; }
bool m_tssnoe[3]

◆ setTssInOutEnaCarry()

void DTConfigTSPhi::setTssInOutEnaCarry ( bool  tssnoe)
inline

Enable Inner SL checking in TSS for carry.

Definition at line 158 of file DTConfigTSPhi.h.

References m_tssnoe.

Referenced by DTConfigTSPhi().

158 { m_tssnoe[2] = tssnoe; }
bool m_tssnoe[3]

◆ setTssMasking()

void DTConfigTSPhi::setTssMasking ( unsigned short int  tssmsk,
int  i 
)
inline

Order of quality bits in TSS for sort1/2.

Definition at line 146 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tssmsk.

Referenced by DTConfigTSPhi().

146 { m_tssmsk[i - 1] = tssmsk; }
unsigned short int m_tssmsk[2]

◆ setUsedTraco()

void DTConfigTSPhi::setUsedTraco ( int  i,
int  val 
)
inline

Enabled TRACOs in TS.

Definition at line 215 of file DTConfigTSPhi.h.

References mps_fire::i, m_tstren, BitArray< N >::set(), and heppy_batch::val.

Referenced by DTConfigTSPhi().

215 { m_tstren.set(i, val); }
BitArray< 24 > m_tstren
void set(const int i)
Definition: BitArray.h:224

◆ TsmCorrEna()

bool DTConfigTSPhi::TsmCorrEna ( int  i) const
inline

Enable Correlation checking in TSM for sort1/2.

Definition at line 99 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tsmcce.

Referenced by print(), and DTTSCand::setBitsTsm().

99 { return m_tsmcce[i]; }
bool m_tsmcce[3]

◆ TsmCorrEnaCarry()

bool DTConfigTSPhi::TsmCorrEnaCarry ( ) const
inline

Enable Correlation checking in TSM for carry.

Definition at line 102 of file DTConfigTSPhi.h.

References m_tsmcce.

Referenced by print(), and DTTSCand::setBitsTsm().

102 { return m_tsmcce[2]; }
bool m_tsmcce[3]

◆ TsmGetCarryFlag()

int DTConfigTSPhi::TsmGetCarryFlag ( ) const
inline

Handling of second track (carry) in case of pile-up, in TSM.

Definition at line 129 of file DTConfigTSPhi.h.

References m_tsmhsp.

Referenced by nValidTSM(), print(), and DTTSPhi::runTSPhi().

129 { return (int)m_tsmhsp; }
unsigned short int m_tsmhsp

◆ TsmGhost1Corr()

bool DTConfigTSPhi::TsmGhost1Corr ( ) const
inline

Correlated ghost 1 suppression option in TSM.

Definition at line 123 of file DTConfigTSPhi.h.

References m_tsmcgs1.

Referenced by print().

123 { return m_tsmcgs1; }

◆ TsmGhost1Flag()

int DTConfigTSPhi::TsmGhost1Flag ( ) const
inline

Ghost 1 suppression option in TSM.

Definition at line 111 of file DTConfigTSPhi.h.

References m_tsmgs1.

Referenced by nValidTSM(), print(), and DTTSM::sortTSM1().

111 { return (int)m_tsmgs1; }
unsigned short int m_tsmgs1

◆ TsmGhost2Corr()

bool DTConfigTSPhi::TsmGhost2Corr ( ) const
inline

Correlated ghost 2 suppression option in TSM.

Definition at line 126 of file DTConfigTSPhi.h.

References m_tsmcgs2.

Referenced by print(), and DTTSM::sortTSM2().

126 { return m_tsmcgs2; }

◆ TsmGhost2Flag()

int DTConfigTSPhi::TsmGhost2Flag ( ) const
inline

Ghost 2 suppression option in TSM.

Definition at line 114 of file DTConfigTSPhi.h.

References m_tsmgs2.

Referenced by nValidTSM(), print(), and DTTSM::sortTSM2().

114 { return (int)m_tsmgs2; }
unsigned short int m_tsmgs2

◆ TsmHtrigEna()

bool DTConfigTSPhi::TsmHtrigEna ( int  i) const
inline

Enable Htrig checking in TSM for sort1/2.

Definition at line 87 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tsmhte.

Referenced by print(), and DTTSCand::setBitsTsm().

87 { return m_tsmhte[i]; }
bool m_tsmhte[3]

◆ TsmHtrigEnaCarry()

bool DTConfigTSPhi::TsmHtrigEnaCarry ( ) const
inline

Enable Htrig checking in TSM for carry.

Definition at line 90 of file DTConfigTSPhi.h.

References m_tsmhte.

Referenced by print(), and DTTSCand::setBitsTsm().

90 { return m_tsmhte[2]; }
bool m_tsmhte[3]

◆ TsmInOutEna()

bool DTConfigTSPhi::TsmInOutEna ( int  i) const
inline

Enable Inner SL checking in TSM for sort1/2.

Definition at line 93 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tsmnoe.

Referenced by print(), and DTTSCand::setBitsTsm().

93 { return m_tsmnoe[i]; }
bool m_tsmnoe[3]

◆ TsmInOutEnaCarry()

bool DTConfigTSPhi::TsmInOutEnaCarry ( ) const
inline

Enable Inner SL checking in TSM for carry.

Definition at line 96 of file DTConfigTSPhi.h.

References m_tsmnoe.

Referenced by print(), and DTTSCand::setBitsTsm().

96 { return m_tsmnoe[2]; }
bool m_tsmnoe[3]

◆ TsmMasking()

int DTConfigTSPhi::TsmMasking ( int  i) const
inline

Order of quality bits in TSM for sort1/2.

Definition at line 84 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tsmmsk.

Referenced by nValidTSM(), print(), and DTTSCand::setBitsTsm().

84 { return (int)m_tsmmsk[i]; }
unsigned short int m_tsmmsk[2]

◆ TsmStatus()

BitArray<8> DTConfigTSPhi::TsmStatus ( ) const
inline

TSM status.

Definition at line 135 of file DTConfigTSPhi.h.

References m_tsmword.

Referenced by DTTSPhi::ignoreSecondTrack(), print(), and DTTSPhi::runTSPhi().

135 { return m_tsmword; };
BitArray< 8 > m_tsmword

◆ TssCorrEna()

bool DTConfigTSPhi::TssCorrEna ( int  i) const
inline

Enable Correlation checking in TSS for sort1/2.

Definition at line 78 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tsscce.

Referenced by print(), and DTTSCand::setBitsTss().

78 { return m_tsscce[i]; }
bool m_tsscce[3]

◆ TssCorrEnaCarry()

bool DTConfigTSPhi::TssCorrEnaCarry ( ) const
inline

Enable Correlation checking in TSS for carry.

Definition at line 81 of file DTConfigTSPhi.h.

References m_tsscce.

Referenced by print(), and DTTSCand::setBitsTss().

81 { return m_tsscce[2]; }
bool m_tsscce[3]

◆ TssGhost1Corr()

bool DTConfigTSPhi::TssGhost1Corr ( ) const
inline

Correlated ghost 1 suppression option in TSS.

Definition at line 117 of file DTConfigTSPhi.h.

References m_tsscgs1.

Referenced by print(), and DTTSS::sortTSS1().

117 { return m_tsscgs1; }

◆ TssGhost1Flag()

int DTConfigTSPhi::TssGhost1Flag ( ) const
inline

Ghost 1 suppression option in TSS.

Definition at line 105 of file DTConfigTSPhi.h.

References m_tssgs1.

Referenced by nValidTSS(), and print().

105 { return (int)m_tssgs1; }
unsigned short int m_tssgs1

◆ TssGhost2Corr()

bool DTConfigTSPhi::TssGhost2Corr ( ) const
inline

Correlated ghost 2 suppression option in TSS.

Definition at line 120 of file DTConfigTSPhi.h.

References m_tsscgs2.

Referenced by print(), and DTTSS::sortTSS2().

120 { return m_tsscgs2; }

◆ TssGhost2Flag()

int DTConfigTSPhi::TssGhost2Flag ( ) const
inline

Ghost 2 suppression option in TSS.

Definition at line 108 of file DTConfigTSPhi.h.

References m_tssgs2.

Referenced by nValidTSS(), print(), and DTTSS::sortTSS2().

108 { return (int)m_tssgs2; }
unsigned short int m_tssgs2

◆ TssHtrigEna()

bool DTConfigTSPhi::TssHtrigEna ( int  i) const
inline

Enable Htrig checking in TSS for sort1/2.

Definition at line 66 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tsshte.

Referenced by print(), and DTTSCand::setBitsTss().

66 { return m_tsshte[i]; }
bool m_tsshte[3]

◆ TssHtrigEnaCarry()

bool DTConfigTSPhi::TssHtrigEnaCarry ( ) const
inline

Enable Htrig checking in TSS for carry.

Definition at line 69 of file DTConfigTSPhi.h.

References m_tsshte.

Referenced by print(), and DTTSCand::setBitsTss().

69 { return m_tsshte[2]; }
bool m_tsshte[3]

◆ TssInOutEna()

bool DTConfigTSPhi::TssInOutEna ( int  i) const
inline

Enable Inner SL checking in TSS for sort1/2.

Definition at line 72 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tssnoe.

Referenced by print(), and DTTSCand::setBitsTss().

72 { return m_tssnoe[i]; }
bool m_tssnoe[3]

◆ TssInOutEnaCarry()

bool DTConfigTSPhi::TssInOutEnaCarry ( ) const
inline

Enable Inner SL checking in TSS for carry.

Definition at line 75 of file DTConfigTSPhi.h.

References m_tssnoe.

Referenced by print(), and DTTSCand::setBitsTss().

75 { return m_tssnoe[2]; }
bool m_tssnoe[3]

◆ TSSinTSMD()

int DTConfigTSPhi::TSSinTSMD ( int  stat,
int  sect 
) const

Return the max nb. of TSSs in input to a single TSMD (called ONLY in back-up mode)

Definition at line 378 of file DTConfigTSPhi.cc.

Referenced by DTTSPhi::ignoreSecondTrack(), and DTTSPhi::runTSPhi().

379  { //CB it should set value when constructor is called (it should be done when we have station by station config)
380 
381  // Number of TSS for each TSMD (it changes from station to station) The DT stations are indicated in parenthesis
382  // in the DT column.
383  //
384  // MB nb.TSS nb.TTS per TSMD
385  // 1 3 2
386  // 2 4 2
387  // 3 5 3
388  // 4(1,2,3,5,6,7) 6 3
389  // 4(8,12) 6 3
390  // 4(9,11) 3 2
391  // 4(4L) 5 3
392  // 4(4R) 5 3
393  // 4(10L) 4 2
394  // 4(10R) 4 2
395 
396  if (stat == 1 || stat == 2 || (stat == 4 && (sect == 9 || sect == 11 || sect == 10))) {
397  return 2;
398  }
399  return 3;
400 }

◆ TssMasking()

int DTConfigTSPhi::TssMasking ( int  i) const
inline

Order of quality bits in TSS for sort1/2.

Definition at line 63 of file DTConfigTSPhi.h.

References mps_fire::i, and m_tssmsk.

Referenced by nValidTSS(), print(), DTTSCand::setBitsTsm(), and DTTSCand::setBitsTss().

63 { return (int)m_tssmsk[i]; }
unsigned short int m_tssmsk[2]

◆ usedTraco()

bool DTConfigTSPhi::usedTraco ( int  i) const
inline

Enabled TRACOs in TS.

Definition at line 132 of file DTConfigTSPhi.h.

References BitArray< N >::element(), mps_fire::i, and m_tstren.

Referenced by DTTSPhi::loadTSPhi(), and print().

132 { return (bool)m_tstren.element(i - 1); }
BitArray< 24 > m_tstren
int element(const int pos) const
Definition: BitArray.h:206

Member Data Documentation

◆ m_debug

bool DTConfigTSPhi::m_debug
private

Definition at line 236 of file DTConfigTSPhi.h.

Referenced by debug(), DTConfigTSPhi(), setDebug(), and setDefaults().

◆ m_ntsm

short int DTConfigTSPhi::m_ntsm
private

Definition at line 264 of file DTConfigTSPhi.h.

Referenced by DTConfigTSPhi(), nValidTSM(), and setDefaults().

◆ m_ntss

short int DTConfigTSPhi::m_ntss
private

Definition at line 263 of file DTConfigTSPhi.h.

Referenced by DTConfigTSPhi(), nValidTSS(), and setDefaults().

◆ m_tsmcce

bool DTConfigTSPhi::m_tsmcce[3]
private

◆ m_tsmcgs1

bool DTConfigTSPhi::m_tsmcgs1
private

Definition at line 255 of file DTConfigTSPhi.h.

Referenced by setDefaults(), setTsmGhost1Corr(), and TsmGhost1Corr().

◆ m_tsmcgs2

bool DTConfigTSPhi::m_tsmcgs2
private

Definition at line 256 of file DTConfigTSPhi.h.

Referenced by setDefaults(), setTsmGhost2Corr(), and TsmGhost2Corr().

◆ m_tsmgs1

unsigned short int DTConfigTSPhi::m_tsmgs1
private

Definition at line 253 of file DTConfigTSPhi.h.

Referenced by setDefaults(), setTsmGhost1Flag(), and TsmGhost1Flag().

◆ m_tsmgs2

unsigned short int DTConfigTSPhi::m_tsmgs2
private

Definition at line 254 of file DTConfigTSPhi.h.

Referenced by setDefaults(), setTsmGhost2Flag(), and TsmGhost2Flag().

◆ m_tsmhsp

unsigned short int DTConfigTSPhi::m_tsmhsp
private

Definition at line 257 of file DTConfigTSPhi.h.

Referenced by setDefaults(), setTsmCarryFlag(), and TsmGetCarryFlag().

◆ m_tsmhte

bool DTConfigTSPhi::m_tsmhte[3]
private

◆ m_tsmmsk

unsigned short int DTConfigTSPhi::m_tsmmsk[2]
private

Definition at line 249 of file DTConfigTSPhi.h.

Referenced by setDefaults(), setTsmMasking(), and TsmMasking().

◆ m_tsmnoe

bool DTConfigTSPhi::m_tsmnoe[3]
private

◆ m_tsmword

BitArray<8> DTConfigTSPhi::m_tsmword
private

Definition at line 260 of file DTConfigTSPhi.h.

Referenced by setDefaults(), setTsmStatus(), and TsmStatus().

◆ m_tsscce

bool DTConfigTSPhi::m_tsscce[3]
private

◆ m_tsscgs1

bool DTConfigTSPhi::m_tsscgs1
private

Definition at line 245 of file DTConfigTSPhi.h.

Referenced by setDefaults(), setTssGhost1Corr(), and TssGhost1Corr().

◆ m_tsscgs2

bool DTConfigTSPhi::m_tsscgs2
private

Definition at line 246 of file DTConfigTSPhi.h.

Referenced by setDefaults(), setTssGhost2Corr(), and TssGhost2Corr().

◆ m_tssgs1

unsigned short int DTConfigTSPhi::m_tssgs1
private

Definition at line 243 of file DTConfigTSPhi.h.

Referenced by setDefaults(), setTssGhost1Flag(), and TssGhost1Flag().

◆ m_tssgs2

unsigned short int DTConfigTSPhi::m_tssgs2
private

Definition at line 244 of file DTConfigTSPhi.h.

Referenced by setDefaults(), setTssGhost2Flag(), and TssGhost2Flag().

◆ m_tsshte

bool DTConfigTSPhi::m_tsshte[3]
private

◆ m_tssmsk

unsigned short int DTConfigTSPhi::m_tssmsk[2]
private

Definition at line 239 of file DTConfigTSPhi.h.

Referenced by setDefaults(), setTssMasking(), and TssMasking().

◆ m_tssnoe

bool DTConfigTSPhi::m_tssnoe[3]
private

◆ m_tstren

BitArray<24> DTConfigTSPhi::m_tstren
private

Definition at line 259 of file DTConfigTSPhi.h.

Referenced by setDefaults(), setUsedTraco(), and usedTraco().

◆ NTSMD

const int DTConfigTSPhi::NTSMD = 2
static

Constant: number of TSMD.

Definition at line 42 of file DTConfigTSPhi.h.

Referenced by DTTSPhi::DTTSPhi(), and DTTSPhi::runTSPhi().

◆ NTSSTSM

const int DTConfigTSPhi::NTSSTSM = 7
static

Constant: maximum number of TSS in input to the TSM.

Definition at line 39 of file DTConfigTSPhi.h.

Referenced by DTTSPhi::addTracoT(), DTTSM::DTTSM(), DTTSPhi::DTTSPhi(), and DTTSPhi::ignoreSecondTrack().

◆ NTSSTSMD

const int DTConfigTSPhi::NTSSTSMD = 3
static

Constant: maximum number of TSS in input to a single TSMD.

Definition at line 45 of file DTConfigTSPhi.h.

Referenced by DTTSPhi::runTSPhi().