ATLAS Offline Software
Loading...
Searching...
No Matches
ITrigT1MuonRecRoiTool.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3*/
4
7
8namespace LVL1{
9
10 unsigned int ITrigT1MuonRecRoiTool::getBitMaskValue( const unsigned int * uintValue,
11 const unsigned int mask ) const {
12 unsigned int maskcopy = mask;
13 unsigned int result = *uintValue & mask;
14 if ( mask != 0 ) {
15 while ( ( maskcopy & 0x00000001 ) == 0 ) {
16 maskcopy = maskcopy >> 1;
17 result = result >> 1;
18 }
19 }
20 return result;
21 }
22
24 {
25 unsigned int result = getBitMaskValue(&roiWord,SysIDMask());
26 if( result == 0x0 ) return Barrel;
27 else if( result == 0x1 ) return Forward;
28 else if( result>>1 ) return Endcap;
29 else return Undef;
30 }
31
37 if( format == Run2 ){
38 m_IsRun3Mask = 0x80000000;
39 m_IsVetoedMask = 0x10000000;
40 m_ChargeMask = 0x08000000;
41 m_IsFirstCandMask = 0x00400000;
42 m_SectorAddressMask = 0x003fc000;
43 m_BarrelSectorIDMask = 0x000f8000;
44 m_EndcapSectorIDMask = 0x001f8000;
45 m_ForwardSectorIDMask = 0x000f8000;
46 m_SysIDMask = 0x00300000;
47 m_SubSysIDMask = 0x00004000;
48 m_ThresholdMask = 0x00003800;
49 m_BarrelRoIMask = 0x0000007c;
50 m_EndcapRoIMask = 0x000003fc;
51 m_ForwardRoIMask = 0x000000fc;
52 m_EndcapRMask = 0x000003f0;
53 m_EndcapPhiMask = 0x0000000c;
54 m_ForwardRMask = 0x000000f0;
55 m_ForwardPhiMask = 0x0000000c;
56 m_OverflowPerRoIMask = 0x00000002;
57 m_OverflowPerSectorMask = 0x00000001;
58 m_BW2Or3Mask = 0x00000000; // undef
59 m_InnerCoinMask = 0x00000000; // undef
60 m_GoodMFMask = 0x00000000; // undef
61 }else if( format == Run3 ){
62 m_IsRun3Mask = 0x80000000;
65 m_IsFirstCandMask = 0x00000000; // undef
85 }else{
86 // no update
87 }
88 }
89
90}
unsigned int getBitMaskValue(const unsigned int *uintValue, const unsigned int mask) const
void updateBitMask(const RoiWordFormat)
MuonTriggerSystem getSystem(const unsigned int &roiWord) const
static constexpr uint32_t RUN3_CAND_WORD_CANDFLAGS_ECFW_PHI_MASK
static constexpr uint32_t FORWARD_SECTORID_MASK
Mask for extracting the sector ID for forward candidates from the data word.
static constexpr uint32_t RUN3_ROI_SHIFT
Position of the RoI bits in the data word.
Definition MuCTPI_Bits.h:45
static constexpr uint32_t RUN3_SUBSYS_ADDRESS_SHIFT
Position in the data word of the subsystem bits.
Definition MuCTPI_Bits.h:93
static constexpr uint32_t RUN3_SUBSYS_HEMISPHERE_MASK
static constexpr uint32_t RUN3_CAND_WORD_CANDFLAGS_EC_R_MASK
static constexpr uint32_t RUN3_CAND_WORD_VETO_MASK
static constexpr uint32_t RUN3_CAND_PT_MASK
Mask for extracting the pT threshold passed by the candidate from the data word.
Definition MuCTPI_Bits.h:62
static constexpr uint32_t RUN3_CAND_WORD_CANDFLAGS_ECFW_GOODMF_MASK
static constexpr uint32_t BARREL_SECTORID_MASK
Mask for extracting the sector ID for barrel candidates from the data word.
static constexpr uint32_t RUN3_CAND_WORD_CANDFLAGS_ECFW_GOODMF_SHIFT
static constexpr uint32_t ENDCAP_ROI_MASK
Mask for extracting the RoI for endcap candidates from the data words.
Definition MuCTPI_Bits.h:41
static constexpr uint32_t RUN3_CAND_WORD_CANDFLAGS_FW_R_MASK
static constexpr uint32_t BARREL_ROI_MASK
new in v2
Definition MuCTPI_Bits.h:39
static constexpr uint32_t RUN3_SUBSYS_ADDRESS_BAFW_MASK
Definition MuCTPI_Bits.h:97
static constexpr uint32_t RUN3_CAND_WORD_CANDFLAGS_ECFW_BW23_MASK
static constexpr uint32_t RUN3_CAND_WORD_CANDFLAGS_ECFW_INNERCOIN_MASK
static constexpr uint32_t RUN3_CAND_WORD_CANDFLAGS_ECFW_CHARGE_MASK
static constexpr uint32_t RUN3_CAND_SECTOR_ADDRESS_SHIFT
Position of the muon candidate's address in the data word.
Definition MuCTPI_Bits.h:82
static constexpr uint32_t ROI_OVERFLOW_MASK
Mask for the bit showing if more than one muon candidates were in the sector RoI.
Definition MuCTPI_Bits.h:31
static constexpr uint32_t RUN3_CAND_PT_SHIFT
Position of the pT threshold bits in the data words.
Definition MuCTPI_Bits.h:65
static constexpr uint32_t RUN3_CAND_WORD_CANDFLAGS_ECFW_CHARGE_SHIFT
static constexpr uint32_t RUN3_CAND_WORD_VETO_SHIFT
static constexpr uint32_t RUN3_CAND_WORD_CANDFLAGS_ECFW_BW23_SHIFT
static constexpr uint32_t ENDCAP_SECTORID_MASK
Mask for extracting the sector ID for endcap candidates from the data word.
static constexpr uint32_t RUN3_CAND_WORD_CANDFLAGS_ECFW_INNERCOIN_SHIFT
static constexpr uint32_t RUN3_CAND_SECTORID_SHIFT
static constexpr uint32_t RUN3_ROI_OVERFLOW_SHIFT
Position of the RoI overflow mask.
Definition MuCTPI_Bits.h:33
static constexpr uint32_t RUN3_CAND_WORD_CANDFLAGS_ECFW_PHI_SHIFT
static constexpr uint32_t RUN3_SUBSYS_HEMISPHERE_SHIFT
static constexpr uint32_t RUN3_CAND_OVERFLOW_SHIFT
Position of the candidate overflow mask.
Definition MuCTPI_Bits.h:27
static constexpr uint32_t FORWARD_ROI_MASK
Mask for extracting the RoI for forward candidates from the data words.
Definition MuCTPI_Bits.h:43
static constexpr uint32_t RUN3_CAND_WORD_CANDFLAGS_ECFW_R_SHIFT
static constexpr uint32_t CAND_OVERFLOW_MASK
Mask for the bit showing if more than two muon candidates were in the trigger sector.
Definition MuCTPI_Bits.h:25
static constexpr uint32_t RUN3_CAND_SECTOR_ADDRESS_MASK
Mask for extracting the address of the muon candidate from the data word This is the mask and shift f...
Definition MuCTPI_Bits.h:77
eFexTowerBuilder creates xAOD::eFexTowerContainer from supercells (LATOME) and triggerTowers (TREX) i...