CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
RegionalMuonRawDigiTranslator.h
Go to the documentation of this file.
1 #ifndef RegionalMuonRawDigiTranslator_h
2 #define RegionalMuonRawDigiTranslator_h
3 
5 
6 namespace l1t {
8  public:
10  uint32_t raw_data_00_31,
11  uint32_t raw_data_32_63,
12  int proc,
13  tftype tf,
14  bool isKbmtf,
15  bool useEmtfDisplacementInfo);
16  static void fillRegionalMuonCand(
17  RegionalMuonCand& mu, uint64_t dataword, int proc, tftype tf, bool isKbmtf, bool useEmtfDisplacementInfo);
18  static void generatePackedDataWords(const RegionalMuonCand& mu,
19  uint32_t& raw_data_00_31,
20  uint32_t& raw_data_32_63,
21  bool isKbmtf,
22  bool useEmtfDisplacementInfo);
23  static uint64_t generate64bitDataWord(const RegionalMuonCand& mu, bool isKbmtf, bool useEmtfDisplacementInfo);
24  static int generateRawTrkAddress(const RegionalMuonCand&, bool isKalman);
25 
26  static constexpr unsigned ptMask_ = 0x1FF;
27  static constexpr unsigned ptShift_ = 0;
28  static constexpr unsigned qualMask_ = 0xF;
29  static constexpr unsigned qualShift_ = 9;
30  static constexpr unsigned absEtaMask_ = 0xFF;
31  static constexpr unsigned absEtaShift_ = 13;
32  static constexpr unsigned etaSignShift_ = 21;
33  static constexpr unsigned hfMask_ = 0x1;
34  static constexpr unsigned hfShift_ = 22;
35  static constexpr unsigned absPhiMask_ = 0x7F;
36  static constexpr unsigned absPhiShift_ = 23;
37  static constexpr unsigned phiSignShift_ = 30;
38  static constexpr unsigned signShift_ = 0;
39  static constexpr unsigned signValidShift_ = 1;
40  static constexpr unsigned dxyMask_ = 0x3;
41  static constexpr unsigned bmtfDxyShift_ = 2;
42  static constexpr unsigned emtfDxyShift_ = 29;
43  static constexpr unsigned ptUnconstrainedMask_ = 0xFF;
44  static constexpr unsigned bmtfPtUnconstrainedShift_ = 23;
45  static constexpr unsigned emtfPtUnconstrainedShift_ = 20;
46  static constexpr unsigned trackAddressMask_ = 0x1FFFFFFF;
47  static constexpr unsigned trackAddressShift_ = 2;
48  // relative shifts within track address
49  static constexpr unsigned bmtfTrAddrSegSelMask_ = 0xF;
50  static constexpr unsigned bmtfTrAddrSegSelShift_ = 21;
51  static constexpr unsigned bmtfTrAddrDetSideShift_ = 20;
52  static constexpr unsigned bmtfTrAddrWheelMask_ = 0x3;
53  static constexpr unsigned bmtfTrAddrWheelShift_ = 18;
54  static constexpr unsigned bmtfTrAddrStat1Mask_ = 0x3;
55  static constexpr unsigned bmtfTrAddrStat1Shift_ = 14;
56  static constexpr unsigned bmtfTrAddrStat2Mask_ = 0xF;
57  static constexpr unsigned bmtfTrAddrStat2Shift_ = 10;
58  static constexpr unsigned bmtfTrAddrStat3Mask_ = 0xF;
59  static constexpr unsigned bmtfTrAddrStat3Shift_ = 6;
60  static constexpr unsigned bmtfTrAddrStat4Mask_ = 0xF;
61  static constexpr unsigned bmtfTrAddrStat4Shift_ = 2;
62 
63  static constexpr unsigned emtfTrAddrMe1SegShift_ = 0;
64  static constexpr unsigned emtfTrAddrMe1ChShift_ = 1;
65  static constexpr unsigned emtfTrAddrMe1ChMask_ = 0x7;
66  static constexpr unsigned emtfTrAddrMe2SegShift_ = 4;
67  static constexpr unsigned emtfTrAddrMe2ChShift_ = 5;
68  static constexpr unsigned emtfTrAddrMe2ChMask_ = 0x7;
69  static constexpr unsigned emtfTrAddrMe3SegShift_ = 8;
70  static constexpr unsigned emtfTrAddrMe3ChShift_ = 9;
71  static constexpr unsigned emtfTrAddrMe3ChMask_ = 0x7;
72  static constexpr unsigned emtfTrAddrMe4SegShift_ = 12;
73  static constexpr unsigned emtfTrAddrMe4ChShift_ = 13;
74  static constexpr unsigned emtfTrAddrMe4ChMask_ = 0x7;
75  static constexpr unsigned emtfTrAddrTrkNumShift_ = 16;
76  static constexpr unsigned emtfTrAddrTrkNumMask_ = 0x3;
77  static constexpr unsigned emtfTrAddrBxShift_ = 18;
78  static constexpr unsigned emtfTrAddrBxMask_ = 0x7FF;
79 
80  static constexpr unsigned omtfTrAddrLayersShift_ = 0;
81  static constexpr unsigned omtfTrAddrLayersMask_ = 0x3FFFF;
82  static constexpr unsigned omtfTrAddrWeightShift_ = 18;
83  static constexpr unsigned omtfTrAddrWeightMask_ = 0x1F;
84  };
85 } // namespace l1t
86 
87 #endif
static void generatePackedDataWords(const RegionalMuonCand &mu, uint32_t &raw_data_00_31, uint32_t &raw_data_32_63, bool isKbmtf, bool useEmtfDisplacementInfo)
const int mu
Definition: Constants.h:22
unsigned long long uint64_t
Definition: Time.h:13
static int generateRawTrkAddress(const RegionalMuonCand &, bool isKalman)
static uint64_t generate64bitDataWord(const RegionalMuonCand &mu, bool isKbmtf, bool useEmtfDisplacementInfo)
static void fillRegionalMuonCand(RegionalMuonCand &mu, uint32_t raw_data_00_31, uint32_t raw_data_32_63, int proc, tftype tf, bool isKbmtf, bool useEmtfDisplacementInfo)