CMS 3D CMS Logo

HcalElectronicsSim.h
Go to the documentation of this file.
1 #ifndef HcalSimAlgos_HcalElectronicsSim_h
2 #define HcalSimAlgos_HcalElectronicsSim_h
3 
13 
14 class HBHEDataFrame;
15 class HODataFrame;
16 class HFDataFrame;
17 class ZDCDataFrame;
18 class QIE10DataFrame;
19 class QIE11DataFrame;
20 
21 namespace CLHEP {
22  class HepRandomEngine;
23 }
24 
26 public:
27  HcalElectronicsSim(const HcalSimParameterMap* parameterMap,
28  HcalAmplifier* amplifier,
29  const HcalCoderFactory* coderFactory,
30  bool PreMix);
32 
33  void setDbService(const HcalDbService* service);
34 
35  //these need to be overloads instead of templates to avoid linking issues when calling private member function templates
36  void analogToDigital(CLHEP::HepRandomEngine*,
37  CaloSamples& linearFrame,
39  double preMixFactor = 10.0,
40  unsigned preMixBits = 126);
41  void analogToDigital(CLHEP::HepRandomEngine*,
42  CaloSamples& linearFrame,
44  double preMixFactor = 10.0,
45  unsigned preMixBits = 126);
46  void analogToDigital(CLHEP::HepRandomEngine*,
47  CaloSamples& linearFrame,
49  double preMixFactor = 10.0,
50  unsigned preMixBits = 126);
51  void analogToDigital(CLHEP::HepRandomEngine*,
52  CaloSamples& linearFrame,
54  double preMixFactor = 10.0,
55  unsigned preMixBits = 126);
56  void analogToDigital(CLHEP::HepRandomEngine*,
57  CaloSamples& linearFrame,
59  double preMixFactor = 10.0,
60  unsigned preMixBits = 126);
61  void analogToDigital(CLHEP::HepRandomEngine*,
62  CaloSamples& linearFrame,
64  double preMixFactor = 10.0,
65  unsigned preMixBits = 126);
68  void newEvent(CLHEP::HepRandomEngine*);
69  void setStartingCapId(int startingCapId);
70 
71 private:
72  template <class Digi>
74  CLHEP::HepRandomEngine*, CaloSamples& linearFrame, Digi& result, double preMixFactor, unsigned preMixBits);
75  template <class Digi>
76  void convert(CaloSamples& frame, Digi& result, CLHEP::HepRandomEngine*);
77  template <class Digi>
78  void premix(CaloSamples& frame, Digi& result, double preMixFactor, unsigned preMixBits);
79 
84 
88 };
89 
90 #endif
HcalElectronicsSim::analogToDigital
void analogToDigital(CLHEP::HepRandomEngine *, CaloSamples &linearFrame, HBHEDataFrame &result, double preMixFactor=10.0, unsigned preMixBits=126)
Definition: HcalElectronicsSim.cc:118
service
Definition: service.py:1
CaloSamples.h
TrendClient_cfi.Digi
Digi
Definition: TrendClient_cfi.py:7
HcalElectronicsSim::setDbService
void setDbService(const HcalDbService *service)
Definition: HcalElectronicsSim.cc:26
HcalElectronicsSim::newEvent
void newEvent(CLHEP::HepRandomEngine *)
Definition: HcalElectronicsSim.cc:155
HcalElectronicsSim::setStartingCapId
void setStartingCapId(int startingCapId)
Definition: HcalElectronicsSim.cc:163
HcalCoderFactory
Definition: HcalCoderFactory.h:8
HcalSimParameterMap.h
HcalElectronicsSim::theCoderFactory
const HcalCoderFactory * theCoderFactory
Definition: HcalElectronicsSim.h:82
HcalElectronicsSim::theStartingCapId
int theStartingCapId
Definition: HcalElectronicsSim.h:85
HcalSimParameterMap
Definition: HcalSimParameterMap.h:10
ZDCDataFrame
Definition: ZDCDataFrame.h:15
CLHEP
Definition: CocoaGlobals.h:27
HcalElectronicsSim::analogToDigitalImpl
void analogToDigitalImpl(CLHEP::HepRandomEngine *, CaloSamples &linearFrame, Digi &result, double preMixFactor, unsigned preMixBits)
Definition: HcalElectronicsSim.cc:108
HcalCoderFactory.h
HBHEDataFrame
Definition: HBHEDataFrame.h:14
HcalTDC
Definition: HcalTDC.h:17
HFDataFrame
Definition: HFDataFrame.h:14
CaloSamples
Definition: CaloSamples.h:14
HcalElectronicsSim::convert
void convert(CaloSamples &frame, Digi &result, CLHEP::HepRandomEngine *)
Definition: HcalElectronicsSim.cc:32
HcalElectronicsSim::theParameterMap
const HcalSimParameterMap * theParameterMap
Definition: HcalElectronicsSim.h:80
HcalElectronicsSim::theStartingCapIdIsRandom
bool theStartingCapIdIsRandom
Definition: HcalElectronicsSim.h:86
HcalTDC.h
HcalDbService
Definition: HcalDbService.h:23
HcalElectronicsSim::premix
void premix(CaloSamples &frame, Digi &result, double preMixFactor, unsigned preMixBits)
Definition: HcalElectronicsSim.cc:55
QIE10DataFrame
Definition: QIE10DataFrame.h:11
HcalElectronicsSim::~HcalElectronicsSim
~HcalElectronicsSim()
Definition: HcalElectronicsSim.cc:24
HODataFrame
Definition: HODataFrame.h:14
amptDefault_cfi.frame
frame
Definition: amptDefault_cfi.py:12
HcalAmplifier
Definition: HcalAmplifier.h:20
QIE11DataFrame
Definition: QIE11DataFrame.h:11
HcalElectronicsSim::PreMixDigis
bool PreMixDigis
Definition: HcalElectronicsSim.h:87
HcalElectronicsSim
Definition: HcalElectronicsSim.h:25
mps_fire.result
result
Definition: mps_fire.py:311
HcalAmplifier.h
HcalElectronicsSim::theAmplifier
HcalAmplifier * theAmplifier
Definition: HcalElectronicsSim.h:81
HcalElectronicsSim::theTDC
HcalTDC theTDC
Definition: HcalElectronicsSim.h:83
HcalElectronicsSim::HcalElectronicsSim
HcalElectronicsSim(const HcalSimParameterMap *parameterMap, HcalAmplifier *amplifier, const HcalCoderFactory *coderFactory, bool PreMix)
Definition: HcalElectronicsSim.cc:13