src
CondFormats
HcalObjects
interface
HcalMCParam.h
Go to the documentation of this file.
1
#ifndef HcalMCParam_h
2
#define HcalMCParam_h
3
10
#include "
CondFormats/Serialization/interface/Serializable.h
"
11
#include <cstdint>
12
13
// definition 8.Feb.2011
14
// MC signal shape integer variable assigned to each readout this way:
15
// 0 - regular HPD HB/HE/HO shape
16
// 1 - "special" HB shape
17
// 2 - SiPMs shape (HO, possibly also in HB/HE)
18
// 3 - HF Shape
19
// 4 - ZDC shape
20
//
21
// change in definition 28.Oct.2011 sk
22
// mParam1 is now packed word.
23
// pulseShapeID [0,500] 9 bits (use this as phot0 detetor ID as well)
24
// syncPhase = cms.bool(True), bool 1 bit (use this for QPLL unlocked channel)
25
// binOfMaximum = cms.int32(5) [1-10] 4 bits
26
// timePhase = cms.double(5.0), [-30.0,30.0] 8 bits (0.25ns step)
27
// timeSmearing = cms.bool(False) bool 1 bit
28
// packingScheme 4 bits
29
class
HcalMCParam
{
30
public
:
31
HcalMCParam
() :
mId
(0),
mParam1
(0) {}
32
33
HcalMCParam
(
unsigned
long
fId,
unsigned
int
fParam1) :
mId
(fId),
mParam1
(fParam1) {}
34
35
uint32_t
rawId
()
const
{
return
mId
; }
36
37
unsigned
int
param1
()
const
{
return
mParam1
; }
38
unsigned
int
signalShape
()
const
{
return
mParam1
& 0x1FF; }
39
bool
syncPhase
()
const
{
return
(
mParam1
>> 9) & 0x1; }
40
unsigned
int
binOfMaximum
()
const
{
return
(
mParam1
>> 10) & 0xF; }
41
float
timePhase
()
const
{
return
((
mParam1
>> 14) & 0xFF) / 4.0 - 32.0; }
42
bool
timeSmearing
()
const
{
return
(
mParam1
>> 22) & 0x1; }
43
unsigned
int
packingScheme
()
const
{
return
(
mParam1
>> 27) & 0xF; }
44
45
private
:
46
uint32_t
mId
;
47
uint32_t
mParam1
;
48
49
COND_SERIALIZABLE
;
50
};
51
52
#endif
HcalMCParam
Definition:
HcalMCParam.h:29
HcalMCParam::mParam1
uint32_t mParam1
Definition:
HcalMCParam.h:47
HcalMCParam::timeSmearing
bool timeSmearing() const
Definition:
HcalMCParam.h:42
HcalMCParam::timePhase
float timePhase() const
Definition:
HcalMCParam.h:41
HcalMCParam::param1
unsigned int param1() const
Definition:
HcalMCParam.h:37
HcalMCParam::rawId
uint32_t rawId() const
Definition:
HcalMCParam.h:35
HcalMCParam::signalShape
unsigned int signalShape() const
Definition:
HcalMCParam.h:38
HcalMCParam::HcalMCParam
HcalMCParam(unsigned long fId, unsigned int fParam1)
Definition:
HcalMCParam.h:33
COND_SERIALIZABLE
#define COND_SERIALIZABLE
Definition:
Serializable.h:39
HcalMCParam::mId
uint32_t mId
Definition:
HcalMCParam.h:46
HcalMCParam::packingScheme
unsigned int packingScheme() const
Definition:
HcalMCParam.h:43
HcalMCParam::HcalMCParam
HcalMCParam()
Definition:
HcalMCParam.h:31
HcalMCParam::binOfMaximum
unsigned int binOfMaximum() const
Definition:
HcalMCParam.h:40
HcalMCParam::syncPhase
bool syncPhase() const
Definition:
HcalMCParam.h:39
Serializable.h
Generated for CMSSW Reference Manual by
1.8.14