CMS 3D CMS Logo

SiStripDigiToRaw.h
Go to the documentation of this file.
1 
2 #ifndef EventFilter_SiStripRawToDigi_SiStripDigiToRaw_H
3 #define EventFilter_SiStripRawToDigi_SiStripDigiToRaw_H
4 
9 #include <string>
10 
12 #include "WarningSummary.h"
13 #include <cstdint>
14 
15 class SiStripFedCabling;
17 class SiStripDigi;
18 class SiStripRawDigi;
19 
20 namespace sistrip {
21 
30  public: // ----- public interface -----
31  DigiToRaw(FEDReadoutMode mode, uint8_t packetCode, bool use_fed_key);
32  ~DigiToRaw();
33 
34  //digi to raw with default headers
35  void createFedBuffers(edm::Event&,
38  std::unique_ptr<FEDRawDataCollection>& buffers);
39  void createFedBuffers(edm::Event&,
42  std::unique_ptr<FEDRawDataCollection>& buffers);
43 
44  //with input raw data for copying header
45  void createFedBuffers(edm::Event&,
49  std::unique_ptr<FEDRawDataCollection>& buffers);
50  void createFedBuffers(edm::Event&,
54  std::unique_ptr<FEDRawDataCollection>& buffers);
55 
56  inline void fedReadoutMode(FEDReadoutMode mode) { mode_ = mode; }
57 
58  void printWarningSummary() const { warnings_.printSummary(); }
59 
60  private: // ----- private data members -----
61  template <class Digi_t>
62  void createFedBuffers_(edm::Event&,
65  std::unique_ptr<FEDRawDataCollection>& buffers,
66  bool zeroSuppressed);
67 
68  template <class Digi_t>
69  void createFedBuffers_(edm::Event&,
73  std::unique_ptr<FEDRawDataCollection>& buffers,
74  bool zeroSuppressed);
75 
76  uint16_t STRIP(const edm::DetSet<SiStripDigi>::const_iterator& it,
78  uint16_t STRIP(const edm::DetSet<SiStripRawDigi>::const_iterator& it,
80 
82  uint8_t packetCode_;
83  bool useFedKey_;
85 
87  };
88 
89 } // namespace sistrip
90 
91 #endif // EventFilter_SiStripRawToDigi_SiStripDigiToRaw_H
void fedReadoutMode(FEDReadoutMode mode)
Input: edm::DetSetVector<SiStripDigi>. Output: FEDRawDataCollection.
WarningSummary warnings_
void printWarningSummary() const
sistrip classes
A Digi for the silicon strip detector, containing both strip and adc information, and suitable for st...
Definition: SiStripDigi.h:12
#define dso_hidden
Definition: Visibility.h:12
FEDReadoutMode mode_
Contains cabling info at the device level, including DetId, APV pair numbers, hardware addresses...
#define begin
Definition: vmac.h:32
collection_type::const_iterator const_iterator
Definition: DetSet.h:32
A Digi for the silicon strip detector, containing only adc information, and suitable for storing raw ...
FEDBufferGenerator bufferGenerator_