Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-09-16 03:23:58

0001 //-------------------------------------------------
0002 //
0003 /**  \class L1MuBMSectorReceiver
0004  *
0005  *   Sector Receiver:
0006  *
0007  *   The Sector Receiver receives track segment
0008  *   data from the BBMX and CSC chamber triggers
0009  *   and stores it into the Data Buffer
0010  *
0011  *
0012  *
0013  *   N. Neumeister            CERN EP
0014  *   J. Troconiz              UAM Madrid
0015  */
0016 //
0017 //--------------------------------------------------
0018 #ifndef L1MUBM_SECTOR_RECEIVER_H
0019 #define L1MUBM_SECTOR_RECEIVER_H
0020 
0021 //---------------
0022 // C++ Headers --
0023 //---------------
0024 
0025 #include <vector>
0026 
0027 //----------------------
0028 // Base Class Headers --
0029 //----------------------
0030 
0031 //------------------------------------
0032 // Collaborating Class Declarations --
0033 //------------------------------------
0034 
0035 #include <DataFormats/Common/interface/Handle.h>
0036 #include <FWCore/Framework/interface/ESHandle.h>
0037 #include <FWCore/Framework/interface/Event.h>
0038 #include "FWCore/Utilities/interface/EDGetToken.h"
0039 #include "DataFormats/L1DTTrackFinder/interface/L1MuDTChambPhDigi.h"
0040 #include "DataFormats/L1DTTrackFinder/interface/L1MuDTChambPhContainer.h"
0041 #include "FWCore/Framework/interface/ConsumesCollector.h"
0042 #include "CondFormats/L1TObjects/interface/L1TMuonBarrelParams.h"
0043 #include "CondFormats/DataRecord/interface/L1TMuonBarrelParamsRcd.h"
0044 
0045 class L1MuBMSectorProcessor;
0046 class L1MuDTTFParameters;
0047 class L1MuDTTFMasks;
0048 
0049 //              ---------------------
0050 //              -- Class Interface --
0051 //              ---------------------
0052 
0053 class L1MuBMSectorReceiver {
0054 public:
0055   /// constructor
0056   L1MuBMSectorReceiver(L1MuBMSectorProcessor&, edm::ConsumesCollector&& iC);
0057 
0058   /// destructor
0059   virtual ~L1MuBMSectorReceiver();
0060 
0061   /// receive track segment data from the BBMX and CSC chamber triggers
0062   void run(int bx, const edm::Event& e, const edm::EventSetup& c);
0063 
0064   /// clear Sector Receiver
0065   void reset();
0066 
0067 private:
0068   /// receive track segment data from BBMX chamber trigger
0069   void receiveBBMXData(int bx, const edm::Event& e);
0070 
0071   /// find the right sector for a given address
0072   int address2sector(int adr) const;
0073 
0074   /// find the right wheel for a given address
0075   int address2wheel(int adr) const;
0076 
0077 private:
0078   L1MuBMSectorProcessor& m_sp;
0079 
0080   edm::ESGetToken<L1TMuonBarrelParams, L1TMuonBarrelParamsRcd> m_bmtfParamsToken;
0081   L1MuDTTFMasks msks;
0082   L1MuDTTFParameters pars;
0083 
0084   //edm::ESHandle< L1MuDTTFParameters > pars;
0085   //edm::ESHandle< L1MuDTTFMasks >      msks;
0086   edm::EDGetTokenT<L1MuDTChambPhContainer> m_DTDigiToken;
0087 };
0088 
0089 #endif