#include <CSCCFEBData.h>
Public Member Functions | |
unsigned | adcCounts (unsigned layer, unsigned channel, unsigned timeBin) const |
unsigned | adcOverflow (unsigned layer, unsigned channel, unsigned timeBin) const |
void | add (const CSCStripDigi &, int layer) |
unsigned | boardNumber () const |
bool | check () const |
makes sure each time slice has a trailer More... | |
unsigned | controllerData (unsigned uglay, unsigned ugchan, unsigned timeBin) const |
CSCCFEBData (unsigned boardNumber, bool sixteenSamples, uint16_t theFormatVersion=2005, bool fDCFEB=false) | |
create, More... | |
CSCCFEBData (unsigned boardNumber, const uint16_t *buf, uint16_t theFormatVersion=2005, bool fDCFEB=false) | |
read from an existing data stream. More... | |
uint16_t * | data () |
void | digis (uint32_t idlayer, std::vector< CSCStripDigi > &result) const |
faster way to get to digis More... | |
std::vector< CSCStripDigi > | digis (unsigned idlayer) const |
unsigned | errorstat (unsigned layer, unsigned channel, unsigned timeBin) const |
bool | isDCFEB () const |
unsigned | nTimeSamples () const |
unsigned | overlappedSampleFlag (unsigned layer, unsigned channel, unsigned timeBin) const |
void | setBoardNumber (int cfeb) |
void | setL1A (unsigned l1a) |
void | setL1A (unsigned sample, unsigned l1a) |
unsigned | sizeInWords () const |
CSCCFEBStatusDigi | statusDigi () const |
returns one status digi per cfeb More... | |
std::vector< std::vector< CSCStripDigi > > | stripDigis () |
deprecated. Use the above method. More... | |
const CSCCFEBTimeSlice * | timeSlice (unsigned i) const |
count from 0. User should check if it's a bad slice More... | |
Static Public Member Functions | |
static void | selfTest () |
Private Member Functions | |
CSCCFEBTimeSlice * | timeSlice (unsigned i) |
Private Attributes | |
unsigned | boardNumber_ |
std::vector< uint16_t > | bWords |
bool | fDCFEB |
uint16_t | theData [1600] |
uint16_t | theFormatVersion |
unsigned | theNumberOfSamples |
int | theSize |
in words More... | |
std::vector< std::pair< int, bool > > | theSliceStarts |
Friends | |
std::ostream & | operator<< (std::ostream &os, const CSCCFEBData &) |
Definition at line 13 of file CSCCFEBData.h.
CSCCFEBData::CSCCFEBData | ( | unsigned | boardNumber, |
const uint16_t * | buf, | ||
uint16_t | theFormatVersion = 2005 , |
||
bool | fDCFEB = false |
||
) |
read from an existing data stream.
Definition at line 11 of file CSCCFEBData.cc.
References visDQMUpload::buf, bWords, CSCBadCFEBTimeSlice::check(), CSCCFEBTimeSlice::check(), CSCBadCFEBWord::data(), LogTrace, hcal::constants::maxSamples, CSCCFEBTimeSlice::sixteenSamples(), CSCBadCFEBTimeSlice::sizeInWords(), CSCCFEBTimeSlice::sizeInWords(), theData, theNumberOfSamples, theSize, theSliceStarts, and CSCBadCFEBTimeSlice::word().
CSCCFEBData::CSCCFEBData | ( | unsigned | boardNumber, |
bool | sixteenSamples, | ||
uint16_t | theFormatVersion = 2005 , |
||
bool | fDCFEB = false |
||
) |
create,
Definition at line 59 of file CSCCFEBData.cc.
References mps_fire::i, mergeAndRegister::slice, theData, theNumberOfSamples, theSize, theSliceStarts, and CSCCFEBSCAControllerWord::ts_flag.
unsigned CSCCFEBData::adcCounts | ( | unsigned | layer, |
unsigned | channel, | ||
unsigned | timeBin | ||
) | const |
Definition at line 110 of file CSCCFEBData.cc.
References fDCFEB, phase1PixelTopology::layer, mps_fire::result, mergeAndRegister::slice, and timeSlice().
unsigned CSCCFEBData::adcOverflow | ( | unsigned | layer, |
unsigned | channel, | ||
unsigned | timeBin | ||
) | const |
Definition at line 118 of file CSCCFEBData.cc.
References fDCFEB, phase1PixelTopology::layer, mps_fire::result, mergeAndRegister::slice, and timeSlice().
void CSCCFEBData::add | ( | const CSCStripDigi & | digi, |
int | layer | ||
) |
=VB= Set CRC value for simulated data
Definition at line 82 of file CSCCFEBData.cc.
References cms::cuda::assert(), fDCFEB, CSCStripDigi::getADCCounts(), CSCStripDigi::getStrip(), phase1PixelTopology::layer, mergeAndRegister::slice, theNumberOfSamples, timeSlice(), and relativeConstraints::value.
Referenced by CSCEventData::add(), counter.Counter::register(), SequenceTypes.Task::remove(), and SequenceTypes.Task::replace().
|
inline |
bool CSCCFEBData::check | ( | ) | const |
makes sure each time slice has a trailer
Definition at line 301 of file CSCCFEBData.cc.
References mps_fire::i, mps_fire::result, mergeAndRegister::slice, theNumberOfSamples, and timeSlice().
unsigned CSCCFEBData::controllerData | ( | unsigned | uglay, |
unsigned | ugchan, | ||
unsigned | timeBin | ||
) | const |
Definition at line 127 of file CSCCFEBData.cc.
References mps_fire::result, mergeAndRegister::slice, and timeSlice().
Referenced by digis().
|
inline |
void CSCCFEBData::digis | ( | uint32_t | idlayer, |
std::vector< CSCStripDigi > & | result | ||
) | const |
faster way to get to digis
Fill strip digis for layer with raw detid = idlayer WARNING: these digis have no comparator information.
for bad or missing data word will be zero
Handle 2013 Format
Definition at line 202 of file CSCCFEBData.cc.
References boardNumber_, controllerData(), CSCDetId::endcap(), fDCFEB, CSCDetId::layer(), phase1PixelTopology::layer, LogTrace, nTimeSamples(), muon::overlap(), mps_fire::result, CSCDetId::ring(), mergeAndRegister::slice, CSCDetId::station(), digitizers_cfi::strip, theFormatVersion, timeSlice(), and SurfaceOrientation::zplus.
Referenced by digis(), stripDigis(), and CSCEventData::stripDigis().
std::vector< CSCStripDigi > CSCCFEBData::digis | ( | unsigned | idlayer | ) | const |
Definition at line 293 of file CSCCFEBData.cc.
References digis(), phase1PixelTopology::layer, and mps_fire::result.
unsigned CSCCFEBData::errorstat | ( | unsigned | layer, |
unsigned | channel, | ||
unsigned | timeBin | ||
) | const |
Definition at line 150 of file CSCCFEBData.cc.
References fDCFEB, phase1PixelTopology::layer, mps_fire::result, mergeAndRegister::slice, and timeSlice().
|
inline |
|
inline |
Definition at line 20 of file CSCCFEBData.h.
References theNumberOfSamples.
Referenced by digis(), and statusDigi().
unsigned CSCCFEBData::overlappedSampleFlag | ( | unsigned | layer, |
unsigned | channel, | ||
unsigned | timeBin | ||
) | const |
Definition at line 142 of file CSCCFEBData.cc.
References fDCFEB, phase1PixelTopology::layer, mps_fire::result, mergeAndRegister::slice, and timeSlice().
|
static |
|
inline |
void CSCCFEBData::setL1A | ( | unsigned | l1a | ) |
Definition at line 159 of file CSCCFEBData.cc.
References mps_fire::i, and theNumberOfSamples.
Referenced by CSCEventData::setEventInformation().
void CSCCFEBData::setL1A | ( | unsigned | sample, |
unsigned | l1a | ||
) |
Definition at line 164 of file CSCCFEBData.cc.
References cms::cuda::assert(), mps_fire::i, theData, theNumberOfSamples, and theSliceStarts.
|
inline |
Definition at line 46 of file CSCCFEBData.h.
References theSize.
Referenced by CSCEventData::unpack_data().
CSCCFEBStatusDigi CSCCFEBData::statusDigi | ( | ) | const |
returns one status digi per cfeb
returns one status digi per cfeb contains bWord if slice is bad also contains crc word and controller word
here layer=1 bec this word repeats 6 times for each layer
Definition at line 173 of file CSCCFEBData.cc.
References boardNumber_, bWords, mps_fire::i, phase1PixelTopology::layer, LogTrace, nTimeSamples(), mps_fire::result, mergeAndRegister::slice, and timeSlice().
std::vector< std::vector< CSCStripDigi > > CSCCFEBData::stripDigis | ( | ) |
deprecated. Use the above method.
Definition at line 326 of file CSCCFEBData.cc.
References digis(), phase1PixelTopology::layer, and mps_fire::result.
|
private |
Definition at line 103 of file CSCCFEBData.cc.
References cms::cuda::assert(), mps_fire::i, theData, theNumberOfSamples, and theSliceStarts.
const CSCCFEBTimeSlice * CSCCFEBData::timeSlice | ( | unsigned | i | ) | const |
count from 0. User should check if it's a bad slice
Definition at line 96 of file CSCCFEBData.cc.
References cms::cuda::assert(), mps_fire::i, theData, theNumberOfSamples, and theSliceStarts.
Referenced by adcCounts(), adcOverflow(), add(), check(), controllerData(), digis(), errorstat(), overlappedSampleFlag(), and statusDigi().
|
friend |
Definition at line 311 of file CSCCFEBData.cc.
|
private |
Definition at line 69 of file CSCCFEBData.h.
Referenced by boardNumber(), digis(), setBoardNumber(), and statusDigi().
|
private |
Definition at line 71 of file CSCCFEBData.h.
Referenced by CSCCFEBData(), and statusDigi().
|
private |
Definition at line 73 of file CSCCFEBData.h.
Referenced by adcCounts(), adcOverflow(), add(), digis(), errorstat(), isDCFEB(), and overlappedSampleFlag().
|
private |
Definition at line 63 of file CSCCFEBData.h.
Referenced by CSCCFEBData(), data(), setL1A(), and timeSlice().
|
private |
Definition at line 72 of file CSCCFEBData.h.
Referenced by digis().
|
private |
Definition at line 70 of file CSCCFEBData.h.
Referenced by add(), check(), CSCCFEBData(), nTimeSamples(), setL1A(), and timeSlice().
|
private |
in words
Definition at line 68 of file CSCCFEBData.h.
Referenced by CSCCFEBData(), and sizeInWords().
|
private |
Shows where in theData the words start. A bad slice will be tagged with a false
Definition at line 66 of file CSCCFEBData.h.
Referenced by CSCCFEBData(), setL1A(), and timeSlice().