ATLAS Offline Software
Loading...
Searching...
No Matches
L0Muon::TgcL0SectorLogicWordEncoder Class Referencefinal

Encode the TGC-owned fields of the Run-4 Sector Logic format. More...

#include <TgcL0SectorLogicWordEncoder.h>

Collaboration diagram for L0Muon::TgcL0SectorLogicWordEncoder:

Static Public Member Functions

static TgcL0SectorLogicWords encode (const xAOD::TGCCandData &candidate)
 Encode one TGC candidate without MDT or overlap information.

Detailed Description

Encode the TGC-owned fields of the Run-4 Sector Logic format.

Definition at line 21 of file TgcL0SectorLogicWordEncoder.h.

Member Function Documentation

◆ encode()

TgcL0SectorLogicWords L0Muon::TgcL0SectorLogicWordEncoder::encode ( const xAOD::TGCCandData & candidate)
static

Encode one TGC candidate without MDT or overlap information.

Definition at line 23 of file TgcL0SectorLogicWordEncoder.cxx.

24 {
25 TgcL0SectorLogicWords words;
26 words.candWord =
27 encodeField(candidate.pt(), bits::RUN4_SL2MUCTPI_PT_VAL_SHIFT,
28 bits::RUN4_SL2MUCTPI_PT_VAL_MASK) |
29 encodeField(candidate.candCharge(), bits::RUN4_SL2MUCTPI_CHARGE_SHIFT,
30 bits::RUN4_SL2MUCTPI_CHARGE_MASK) |
31 encodeField(candidate.phi(), bits::RUN4_SL2MUCTPI_PHI_SHIFT,
32 bits::RUN4_SL2MUCTPI_PHI_MASK) |
33 encodeField(candidate.eta(), bits::RUN4_SL2MUCTPI_ETA_SHIFT,
34 bits::RUN4_SL2MUCTPI_ETA_MASK);
35
36 words.candExtraWord =
37 encodeField(candidate.threshold(),
38 bits::RUN4_SL2MUCTPI_PTTHRESHOLD_SHIFT,
39 bits::RUN4_SL2MUCTPI_PTTHRESHOLD_MASK) |
40 encodeField(candidate.tcId(), bits::RUN4_SL2MUCTPI_TCID_SHIFT,
41 bits::RUN4_SL2MUCTPI_TCID_MASK) |
42 encodeField(candidate.coinType(), bits::RUN4_SL2MUCTPI_COINTYPE_SHIFT,
43 bits::RUN4_SL2MUCTPI_COINTYPE_MASK);
44 return words;
45}
uint16_t eta() const
Retrieve the eta.
uint8_t coinType() const
Retrieve the coincidence type.
uint8_t candCharge() const
Retrieve the candidate charge.
uint8_t threshold() const
Retrieve the threshold.
uint8_t pt() const
Retrieve the encoded candidate pT.
uint16_t phi() const
Retrieve the phi.
uint8_t tcId() const
Retrieve the trigger-candidate identifier.

The documentation for this class was generated from the following files: