ATLAS Offline Software
Loading...
Searching...
No Matches
LVL1BS::PpmSubBlockV1 Class Reference

Sub-Block class for PPM data. More...

#include <PpmSubBlockV1.h>

Inheritance diagram for LVL1BS::PpmSubBlockV1:
Collaboration diagram for LVL1BS::PpmSubBlockV1:

Public Types

enum  SubBlockWordType { HEADER , DATA , STATUS }
enum  DataFormats { NEUTRAL = 0 , UNCOMPRESSED = 1 , COMPRESSED = 2 , SUPERCOMPRESSED = 3 }
enum  DataErrorType {
  ERROR_NONE , ERROR_DUPLICATE_ROB , ERROR_ROD_ID , ERROR_ROD_NSTATUS ,
  ERROR_USER_HEADER , ERROR_MISSING_HEADER , ERROR_MISSING_SUBBLOCK , ERROR_CRATE_NUMBER ,
  ERROR_MODULE_NUMBER , ERROR_SLICES , ERROR_DUPLICATE_DATA , ERROR_ROI_TYPE ,
  ERROR_MAX
}
enum  UnpackErrorType {
  UNPACK_NONE = ERROR_NONE , UNPACK_VERSION = ERROR_MAX , UNPACK_FORMAT , UNPACK_COMPRESSION_VERSION ,
  UNPACK_COMPRESSION_SLICES , UNPACK_DATA_TRUNCATED , UNPACK_EXCESS_DATA , UNPACK_SOURCE_ID ,
  UNPACK_EXCESS_TOBS , UNPACK_DATA_ID
}

Public Member Functions

 PpmSubBlockV1 ()
 ~PpmSubBlockV1 ()
void clear ()
 Clear all data.
void setPpmHeader (int version, int format, int seqno, int crate, int module, int slicesFadc, int slicesLut)
 Store PPM header.
void setPpmErrorHeader (int version, int format, int crate, int module, int slicesFadc, int slicesLut)
 Store PPM error block header.
int slicesFadc () const
int slicesLut () const
void fillPpmData (int chan, const std::vector< int > &lut, const std::vector< int > &fadc, const std::vector< int > &bcidLut, const std::vector< int > &bcidFadc)
 Store PPM data for later packing.
void ppmData (int chan, std::vector< int > &lut, std::vector< int > &fadc, std::vector< int > &bcidLut, std::vector< int > &bcidFadc)
 Return unpacked data for given channel.
void fillPpmError (int chan, int errorWord)
 Store an error word corresponding to a data channel.
void fillPpmPinError (int pin, int errorWord)
 Store an error word corresponding to a G-Link pin.
int ppmError (int chan) const
 Return the error word for a data channel.
int ppmPinError (int pin) const
 Return the error word for a G-Link pin.
bool glinkPinParity (int chan) const
bool fpgaCorrupt (int chan) const
bool bunchMismatch (int chan) const
bool eventMismatch (int chan) const
bool asicFull (int chan) const
bool timeout (int chan) const
bool mcmAbsent (int chan) const
bool channelDisabled (int chan) const
bool channelDisabledA (int pin) const
bool channelDisabledB (int pin) const
bool channelDisabledC (int pin) const
bool channelDisabledD (int pin) const
bool glinkPinParity () const
bool fpgaCorrupt () const
bool bunchMismatch () const
bool eventMismatch () const
bool asicFull () const
bool timeout () const
bool mcmAbsent () const
bool channelDisabledA () const
bool channelDisabledB () const
bool channelDisabledC () const
bool channelDisabledD () const
void setLutOffset (int offset)
void setFadcOffset (int offset)
void setPedestal (int pedval)
void setFadcBaseline (int baseline)
void setFadcThreshold (int threshold)
void setRunNumber (int run)
int lutOffset () const
int fadcOffset () const
int pedestal () const
int fadcBaseline () const
int fadcThreshold () const
int runNumber () const
bool pack ()
 Pack data.
bool unpack ()
 Unpack data.
int channelsPerSubBlock (int version, int format)
 Return the number of channels per sub-block.
int channelsPerSubBlock ()
void setCompStats (const std::vector< uint32_t > &stats)
 Set compression stats.
const std::vector< uint32_t > & compStats () const
 Return reference to compression stats.
int dataWords () const
 Return number of data words.
void setHeader (int wordId, int version, int format, int seqno, int crate, int module, int slices2, int slices1)
 Store header data.
int wordId () const
int version () const
int format () const
int seqno () const
int slice () const
int crate () const
int module () const
int slices2 () const
int slices1 () const
uint32_t failingBCN () const
bool glinkTimeout () const
bool glinkDown () const
bool upstreamError () const
bool daqOverflow () const
bool bcnMismatch () const
bool glinkProtocol () const
bool glinkParity () const
uint32_t subStatus () const
 Return Sub-status word.
void setBunchCrossing (int bc)
 Set the Bunch Crossing number (neutral format only)
int bunchCrossing () const
 Return the Bunch Crossing number (neutral format only)
OFFLINE_FRAGMENTS_NAMESPACE::PointerType read (const OFFLINE_FRAGMENTS_NAMESPACE::PointerType beg, const OFFLINE_FRAGMENTS_NAMESPACE::PointerType end)
 Input complete packed sub-block from ROD array.
void write (FullEventAssembler< L1CaloSrcIdMap >::RODDATA *theROD) const
 Output complete packed sub-block to ROD vector.
void setStatus (uint32_t failingBCN, bool glinkTimeout, bool glinkDown, bool upstreamError, bool daqOverflow, bool bcnMismatch, bool glinkProtocol, bool glinkParity)
 Store error status trailer.
void setDaqOverflow (int bit=1)
 Set DAQ FIFO Overflow bit in Sub-status word.
void setGlinkParity (int bit=1)
 Set G-Link Parity bit in Sub-status word.
void setUnpackErrorCode (int code)
 Set the unpacking error code.
int unpackErrorCode () const
 Return the unpacking error code.
std::string unpackErrorMsg () const
 Return the unpacking error message for printing.
int minBits (uint32_t datum) const
 Return the minimum number of bits needed for given data.
int parityBit (int init, uint32_t datum, int nbits) const
 Return the parity bit for given data.
void packer (uint32_t datum, int nbits)
 Pack given data into given number of bits.
void packerFlush ()
 Flush the current data word padded with zeros.
void setStreamed ()
 Set continuous bit streaming for compressed formats.
uint32_t unpacker (int nbits)
 Unpack given number of bits of data.
uint32_t unpacker (int nbits, int align)
void unpackerInit ()
 Initialise unpacker.
bool unpackerSuccess () const
 Return unpacker success flag.
void packerNeutral (int pin, uint32_t datum, int nbits)
 Pack given neutral data from given pin.
void packerNeutralParity (int pin)
 Pack current G-Link parity bit for given pin.
uint32_t unpackerNeutral (int pin, int nbits)
 Unpack given number of bits of neutral data for given pin.
bool unpackerNeutralParityError (int pin)
 Unpack and test G-Link parity bit for given pin.
int currentPinBit (int pin) const
 Return current pin bit for given pin.

Static Public Member Functions

static bool errorBlock (uint32_t word)
 Check if a header word is for an error block.
static int wordId (uint32_t word)
 Return wordID field from given header word.
static int version (uint32_t word)
 Return version number from given header word.
static int format (uint32_t word)
 Return data format from given header word.
static int seqno (uint32_t word)
 Return seqno field from given header word.
static int module (uint32_t word)
 Return module field from given header word.
static SubBlockWordType wordType (uint32_t word)
 Word identification.

Private Member Functions

int asic (int chan) const
 Return the ASIC channel corresponding to a data channel.
int pin (int chan) const
 Return the G-Link pin corresponding to a data channel.
bool errorBit (int pin, int bit) const
 Error bit extraction.
bool errorBit (int bit) const
 Global error bit extraction.
bool packNeutral ()
 Pack neutral data.
bool packUncompressedData ()
 Pack uncompressed data.
bool packUncompressedErrors ()
 Pack uncompressed error data.
bool unpackNeutral ()
 Unpack neutral data.
bool unpackUncompressedData ()
 Unpack uncompressed data.
bool unpackUncompressedErrors ()
 Unpack uncompressed error data.

Private Attributes

uint32_t m_globalError
int m_lutOffset
int m_fadcOffset
int m_pedestal
int m_fadcBaseline
int m_fadcThreshold
int m_runNumber
std::vector< uint32_t > m_compStats
 Vector for compression statistics.
std::vector< uint32_t > m_datamap
 Vector for intermediate data.
std::vector< uint32_t > m_errormap
 Vector for intermediate error data.
uint32_t m_header
 Sub-Block Header.
uint32_t m_trailer
 Sub-Block Status Trailer.
int m_bunchCrossing
 Bunch Crossing number (neutral format only)
int m_unpackError
 Unpacking error code.
uint32_t m_bitword
int m_currentBit
int m_maxBits
uint32_t m_maxMask
bool m_unpackerFlag
std::vector< uint32_t >::const_iterator m_dataPos {}
std::vector< uint32_t >::const_iterator m_dataPosEnd {}
std::vector< int > m_currentPinBit
std::vector< int > m_oddParity
int m_dataWords
 Current number of data words.
std::vector< uint32_t > m_data
 Sub-Block data.
std::vector< uint32_t > m_unpackingMasks
 Unpacking masks.

Static Private Attributes

static const uint32_t s_wordIdVal = 0xc
static const int s_errorMarker = 63
static const int s_wordLen = 16
static const int s_lutBit = 0
static const int s_bcidLutBit = 8
static const int s_fadcBit = 1
static const int s_bcidFadcBit = 0
static const uint32_t s_lutMask = 0xff
static const uint32_t s_bcidLutMask = 0x7
static const uint32_t s_fadcMask = 0x3ff
static const uint32_t s_bcidFadcMask = 0x1
static const int s_channels = 64
static const int s_glinkPins = 16
static const int s_asicChannels = 4
static const int s_dataBits = 11
static const int s_errorBits = 10
static const int s_bunchCrossingBits = 12
static const uint32_t s_errorMask = 0x7ff
static const int s_glinkPinParityBit = 10
static const int s_fpgaCorruptBit = 9
static const int s_bunchMismatchBit = 8
static const int s_eventMismatchBit = 7
static const int s_asicFullBit = 6
static const int s_timeoutBit = 5
static const int s_mcmAbsentBit = 4
static const int s_channelDisabledBit = 0
static const int s_headerBit = 30
static const int s_statusBit = 28
static const uint32_t s_headerMask = 0x3
static const uint32_t s_statusMask = 0x1
static const uint32_t s_headerVal = 0x3
static const uint32_t s_statusVal = 0x1
static const int s_ppmCrates = 8
static const int s_wordIdBit = 28
static const int s_versionBit = 25
static const int s_formatBit = 22
static const int s_seqnoBit = 16
static const int s_crateBit = 12
static const int s_moduleBit = 8
static const int s_slices2Bit = 3
static const int s_slices1Bit = 0
static const uint32_t s_wordIdMask = 0xf
static const uint32_t s_versionMask = 0x7
static const uint32_t s_formatMask = 0x7
static const uint32_t s_seqnoMask = 0x3f
static const uint32_t s_crateMask = 0xf
static const uint32_t s_moduleMask = 0xf
static const uint32_t s_slices2Mask = 0x1f
static const uint32_t s_slices1Mask = 0x7
static const int s_failingBcnBit = 22
static const int s_glinkTimeoutBit = 7
static const int s_glinkDownBit = 6
static const int s_upstreamErrorBit = 4
static const int s_daqOverflowBit = 3
static const int s_bcnMismatchBit = 2
static const int s_glinkProtocolBit = 1
static const int s_glinkParityBit = 0
static const uint32_t s_failingBcnMask = 0x3f
static const int s_maxWordBits = 32
static const int s_maxStreamedBits = 31
static const uint32_t s_maxWordMask = 0xffffffff
static const uint32_t s_maxStreamedMask = 0x7fffffff
static const int s_maxPins = 20
static const uint32_t s_glinkDavSet = 0x400000

Detailed Description

Sub-Block class for PPM data.

Author
Peter Faulkner

Definition at line 20 of file PpmSubBlockV1.h.

Member Enumeration Documentation

◆ DataErrorType

Enumerator
ERROR_NONE 
ERROR_DUPLICATE_ROB 
ERROR_ROD_ID 
ERROR_ROD_NSTATUS 
ERROR_USER_HEADER 
ERROR_MISSING_HEADER 
ERROR_MISSING_SUBBLOCK 
ERROR_CRATE_NUMBER 
ERROR_MODULE_NUMBER 
ERROR_SLICES 
ERROR_DUPLICATE_DATA 
ERROR_ROI_TYPE 
ERROR_MAX 

Definition at line 31 of file L1CaloSubBlock.h.

◆ DataFormats

Enumerator
NEUTRAL 
UNCOMPRESSED 
COMPRESSED 
SUPERCOMPRESSED 

Definition at line 28 of file L1CaloSubBlock.h.

◆ SubBlockWordType

Enumerator
HEADER 
DATA 
STATUS 

Definition at line 27 of file L1CaloSubBlock.h.

◆ UnpackErrorType

Enumerator
UNPACK_NONE 
UNPACK_VERSION 
UNPACK_FORMAT 
UNPACK_COMPRESSION_VERSION 
UNPACK_COMPRESSION_SLICES 
UNPACK_DATA_TRUNCATED 
UNPACK_EXCESS_DATA 
UNPACK_SOURCE_ID 
UNPACK_EXCESS_TOBS 
UNPACK_DATA_ID 

Definition at line 38 of file L1CaloSubBlock.h.

Constructor & Destructor Documentation

◆ PpmSubBlockV1()

LVL1BS::PpmSubBlockV1::PpmSubBlockV1 ( )

◆ ~PpmSubBlockV1()

LVL1BS::PpmSubBlockV1::~PpmSubBlockV1 ( )

Definition at line 50 of file PpmSubBlockV1.cxx.

51{
52}

Member Function Documentation

◆ asic()

int LVL1BS::PpmSubBlockV1::asic ( int chan) const
inlineprivate

Return the ASIC channel corresponding to a data channel.

Definition at line 383 of file PpmSubBlockV1.h.

384{
385 return chan / s_glinkPins;
386}
static const int s_glinkPins

◆ asicFull() [1/2]

bool LVL1BS::PpmSubBlockV1::asicFull ( ) const
inline

Definition at line 278 of file PpmSubBlockV1.h.

279{
280 return errorBit(s_asicFullBit);
281}
bool errorBit(int pin, int bit) const
Error bit extraction.
static const int s_asicFullBit

◆ asicFull() [2/2]

bool LVL1BS::PpmSubBlockV1::asicFull ( int chan) const
inline

Definition at line 218 of file PpmSubBlockV1.h.

219{
220 return errorBit(pin(chan), s_asicFullBit);
221}
int pin(int chan) const
Return the G-Link pin corresponding to a data channel.

◆ bcnMismatch()

bool LVL1BS::L1CaloSubBlock::bcnMismatch ( ) const
inlineinherited

Definition at line 308 of file L1CaloSubBlock.h.

309{
310 return m_trailer & (0x1 << s_bcnMismatchBit);
311}
uint32_t m_trailer
Sub-Block Status Trailer.
static const int s_bcnMismatchBit

◆ bunchCrossing()

int LVL1BS::L1CaloSubBlock::bunchCrossing ( ) const
inlineinherited

Return the Bunch Crossing number (neutral format only)

Definition at line 333 of file L1CaloSubBlock.h.

334{
335 return m_bunchCrossing;
336}
int m_bunchCrossing
Bunch Crossing number (neutral format only)

◆ bunchMismatch() [1/2]

bool LVL1BS::PpmSubBlockV1::bunchMismatch ( ) const
inline

Definition at line 268 of file PpmSubBlockV1.h.

269{
271}
static const int s_bunchMismatchBit

◆ bunchMismatch() [2/2]

bool LVL1BS::PpmSubBlockV1::bunchMismatch ( int chan) const
inline

Definition at line 208 of file PpmSubBlockV1.h.

209{
210 return errorBit(pin(chan), s_bunchMismatchBit);
211}

◆ channelDisabled()

bool LVL1BS::PpmSubBlockV1::channelDisabled ( int chan) const
inline

Definition at line 233 of file PpmSubBlockV1.h.

234{
235 return errorBit(pin(chan), s_channelDisabledBit + asic(chan));
236}
int asic(int chan) const
Return the ASIC channel corresponding to a data channel.
static const int s_channelDisabledBit

◆ channelDisabledA() [1/2]

bool LVL1BS::PpmSubBlockV1::channelDisabledA ( ) const
inline

Definition at line 293 of file PpmSubBlockV1.h.

294{
296}

◆ channelDisabledA() [2/2]

bool LVL1BS::PpmSubBlockV1::channelDisabledA ( int pin) const
inline

Definition at line 238 of file PpmSubBlockV1.h.

239{
241}

◆ channelDisabledB() [1/2]

bool LVL1BS::PpmSubBlockV1::channelDisabledB ( ) const
inline

Definition at line 298 of file PpmSubBlockV1.h.

299{
300 return errorBit(s_channelDisabledBit + 1);
301}

◆ channelDisabledB() [2/2]

bool LVL1BS::PpmSubBlockV1::channelDisabledB ( int pin) const
inline

Definition at line 243 of file PpmSubBlockV1.h.

244{
245 return errorBit(pin, s_channelDisabledBit + 1);
246}

◆ channelDisabledC() [1/2]

bool LVL1BS::PpmSubBlockV1::channelDisabledC ( ) const
inline

Definition at line 303 of file PpmSubBlockV1.h.

304{
305 return errorBit(s_channelDisabledBit + 2);
306}

◆ channelDisabledC() [2/2]

bool LVL1BS::PpmSubBlockV1::channelDisabledC ( int pin) const
inline

Definition at line 248 of file PpmSubBlockV1.h.

249{
250 return errorBit(pin, s_channelDisabledBit + 2);
251}

◆ channelDisabledD() [1/2]

bool LVL1BS::PpmSubBlockV1::channelDisabledD ( ) const
inline

Definition at line 308 of file PpmSubBlockV1.h.

309{
310 return errorBit(s_channelDisabledBit + 3);
311}

◆ channelDisabledD() [2/2]

bool LVL1BS::PpmSubBlockV1::channelDisabledD ( int pin) const
inline

Definition at line 253 of file PpmSubBlockV1.h.

254{
255 return errorBit(pin, s_channelDisabledBit + 3);
256}

◆ channelsPerSubBlock() [1/2]

int LVL1BS::PpmSubBlockV1::channelsPerSubBlock ( )

Definition at line 483 of file PpmSubBlockV1.cxx.

◆ channelsPerSubBlock() [2/2]

int LVL1BS::PpmSubBlockV1::channelsPerSubBlock ( int version,
int format )

Return the number of channels per sub-block.

Definition at line 457 of file PpmSubBlockV1.cxx.

458{
459 int chan = 0;
460 switch (version) {
461 case 1:
462 switch (format) {
463 case UNCOMPRESSED:
465 break;
466 case NEUTRAL:
467 case COMPRESSED:
468 case SUPERCOMPRESSED:
470 break;
471 default:
473 break;
474 }
475 break;
476 default:
478 break;
479 }
480 return chan;
481}
void setUnpackErrorCode(int code)
Set the unpacking error code.
static const int s_channels
static const int s_asicChannels

◆ clear()

void LVL1BS::PpmSubBlockV1::clear ( )

Clear all data.

Definition at line 56 of file PpmSubBlockV1.cxx.

57{
59 m_globalError = 0;
60 m_lutOffset = -1;
61 m_fadcOffset = -1;
62 m_datamap.clear();
63 m_errormap.clear();
64}
void clear()
Clear all data.
std::vector< uint32_t > m_errormap
Vector for intermediate error data.
std::vector< uint32_t > m_datamap
Vector for intermediate data.

◆ compStats()

const std::vector< uint32_t > & LVL1BS::PpmSubBlockV1::compStats ( ) const
inline

Return reference to compression stats.

Definition at line 373 of file PpmSubBlockV1.h.

374{
375 return m_compStats;
376}
std::vector< uint32_t > m_compStats
Vector for compression statistics.

◆ crate()

int LVL1BS::L1CaloSubBlock::crate ( ) const
inlineinherited

Definition at line 263 of file L1CaloSubBlock.h.

264{
265 return (m_header >> s_crateBit) & s_crateMask;
266}
static const uint32_t s_crateMask
static const int s_crateBit
uint32_t m_header
Sub-Block Header.

◆ currentPinBit()

int LVL1BS::L1CaloSubBlock::currentPinBit ( int pin) const
inlineinherited

Return current pin bit for given pin.

Definition at line 359 of file L1CaloSubBlock.h.

360{
361 return m_currentPinBit[pin];
362}
std::vector< int > m_currentPinBit

◆ daqOverflow()

bool LVL1BS::L1CaloSubBlock::daqOverflow ( ) const
inlineinherited

Definition at line 303 of file L1CaloSubBlock.h.

304{
305 return m_trailer & (0x1 << s_daqOverflowBit);
306}
static const int s_daqOverflowBit

◆ dataWords()

int LVL1BS::L1CaloSubBlock::dataWords ( ) const
inlineinherited

Return number of data words.

Definition at line 233 of file L1CaloSubBlock.h.

234{
235 return m_dataWords;
236}
int m_dataWords
Current number of data words.

◆ errorBit() [1/2]

bool LVL1BS::PpmSubBlockV1::errorBit ( int bit) const
private

Global error bit extraction.

Definition at line 229 of file PpmSubBlockV1.cxx.

230{
231 return m_globalError & (0x1 << bit);
232}

◆ errorBit() [2/2]

bool LVL1BS::PpmSubBlockV1::errorBit ( int pin,
int bit ) const
inlineprivate

Error bit extraction.

Definition at line 393 of file PpmSubBlockV1.h.

394{
395 return m_errormap[pin] & (0x1 << bit);
396}

◆ errorBlock()

bool LVL1BS::PpmSubBlockV1::errorBlock ( uint32_t word)
static

Check if a header word is for an error block.

Definition at line 490 of file PpmSubBlockV1.cxx.

491{
492 bool rc = false;
493 if (format(word) == UNCOMPRESSED &&
494 seqno(word) == s_errorMarker) rc = true;
495 return rc;
496}
static Double_t rc
static const int s_errorMarker

◆ eventMismatch() [1/2]

bool LVL1BS::PpmSubBlockV1::eventMismatch ( ) const
inline

Definition at line 273 of file PpmSubBlockV1.h.

274{
276}
static const int s_eventMismatchBit

◆ eventMismatch() [2/2]

bool LVL1BS::PpmSubBlockV1::eventMismatch ( int chan) const
inline

Definition at line 213 of file PpmSubBlockV1.h.

214{
215 return errorBit(pin(chan), s_eventMismatchBit);
216}

◆ fadcBaseline()

int LVL1BS::PpmSubBlockV1::fadcBaseline ( ) const
inline

Definition at line 358 of file PpmSubBlockV1.h.

359{
360 return m_fadcBaseline;
361}

◆ fadcOffset()

int LVL1BS::PpmSubBlockV1::fadcOffset ( ) const
inline

Definition at line 348 of file PpmSubBlockV1.h.

349{
350 return (m_fadcOffset < 0) ? slicesFadc()/2 : m_fadcOffset;
351}

◆ fadcThreshold()

int LVL1BS::PpmSubBlockV1::fadcThreshold ( ) const
inline

Definition at line 363 of file PpmSubBlockV1.h.

364{
365 return m_fadcThreshold;
366}

◆ failingBCN()

uint32_t LVL1BS::L1CaloSubBlock::failingBCN ( ) const
inlineinherited

Definition at line 283 of file L1CaloSubBlock.h.

284{
286}
static const uint32_t s_failingBcnMask
static const int s_failingBcnBit

◆ fillPpmData()

void LVL1BS::PpmSubBlockV1::fillPpmData ( int chan,
const std::vector< int > & lut,
const std::vector< int > & fadc,
const std::vector< int > & bcidLut,
const std::vector< int > & bcidFadc )

Store PPM data for later packing.

Definition at line 110 of file PpmSubBlockV1.cxx.

114{
115 const int sliceL = slicesLut();
116 const int sliceF = slicesFadc();
117 const int slices = sliceL + sliceF;
118 const int chanPerSubBlock = channelsPerSubBlock();
119 int dataSize = m_datamap.size();
120 if (dataSize == 0) {
121 dataSize = slices * chanPerSubBlock;
122 m_datamap.resize(dataSize);
123 }
124 // coverity[divide_by_zero : FALSE]
125 int offset = (chan % chanPerSubBlock) * slices;
126 if (offset + slices <= dataSize) {
127 for (int pos = 0; pos < sliceL; ++pos) {
128 uint32_t datum = (lut[pos] & s_lutMask) << s_lutBit;
129 datum |= (bcidLut[pos] & s_bcidLutMask) << s_bcidLutBit;
130 m_datamap[offset + pos] = datum;
131 }
132 offset += sliceL;
133 for (int pos = 0; pos < sliceF; ++pos) {
134 const int adc = (fadc[pos] > 0) ? fadc[pos] : 0;
135 uint32_t datum = (adc & s_fadcMask) << s_fadcBit;
136 datum |= (bcidFadc[pos] & s_bcidFadcMask) << s_bcidFadcBit;
137 m_datamap[offset + pos] = datum;
138 }
139 }
140}
static const uint32_t s_bcidFadcMask
static const int s_bcidFadcBit
static const uint32_t s_fadcMask
static const int s_fadcBit
static const uint32_t s_lutMask
static const int s_lutBit
static const int s_bcidLutBit
static const uint32_t s_bcidLutMask
constexpr auto lut(Generator &&f)
size_t dataSize(TDA::PayloadIterator start)
Size in bytes of the buffer that is needed to decode next fragment data content.
setEventNumber uint32_t

◆ fillPpmError()

void LVL1BS::PpmSubBlockV1::fillPpmError ( int chan,
int errorWord )

Store an error word corresponding to a data channel.

Definition at line 181 of file PpmSubBlockV1.cxx.

182{
183 if (m_errormap.empty()) m_errormap.resize(s_glinkPins);
184 // Expand one ASIC channel disabled bit to four
185 const uint32_t chanDisabled = (errorWord & 0x1) << asic(chan);
186 uint32_t word = (((errorWord >> 1) << s_asicChannels)
187 | chanDisabled) & s_errorMask;
188 m_errormap[pin(chan)] |= word;
189 m_globalError |= word;
190}
static const uint32_t s_errorMask

◆ fillPpmPinError()

void LVL1BS::PpmSubBlockV1::fillPpmPinError ( int pin,
int errorWord )

Store an error word corresponding to a G-Link pin.

Definition at line 194 of file PpmSubBlockV1.cxx.

195{
196 if (m_errormap.empty()) m_errormap.resize(s_glinkPins);
197 m_errormap[pin] = errorWord & s_errorMask;
198 m_globalError = 0;
199 for (uint32_t word : m_errormap) {
200 m_globalError |= word;
201 }
202}

◆ format() [1/2]

int LVL1BS::L1CaloSubBlock::format ( ) const
inlineinherited

Definition at line 248 of file L1CaloSubBlock.h.

249{
250 return (m_header >> s_formatBit) & s_formatMask;
251}
static const int s_formatBit
static const uint32_t s_formatMask

◆ format() [2/2]

int LVL1BS::L1CaloSubBlock::format ( uint32_t word)
staticinherited

Return data format from given header word.

Definition at line 506 of file L1CaloSubBlock.cxx.

507{
508 return (word >> s_formatBit) & s_formatMask;
509}

◆ fpgaCorrupt() [1/2]

bool LVL1BS::PpmSubBlockV1::fpgaCorrupt ( ) const
inline

Definition at line 263 of file PpmSubBlockV1.h.

264{
266}
static const int s_fpgaCorruptBit

◆ fpgaCorrupt() [2/2]

bool LVL1BS::PpmSubBlockV1::fpgaCorrupt ( int chan) const
inline

Definition at line 203 of file PpmSubBlockV1.h.

204{
205 return errorBit(pin(chan), s_fpgaCorruptBit);
206}

◆ glinkDown()

bool LVL1BS::L1CaloSubBlock::glinkDown ( ) const
inlineinherited

Definition at line 293 of file L1CaloSubBlock.h.

294{
295 return m_trailer & (0x1 << s_glinkDownBit);
296}
static const int s_glinkDownBit

◆ glinkParity()

bool LVL1BS::L1CaloSubBlock::glinkParity ( ) const
inlineinherited

Definition at line 318 of file L1CaloSubBlock.h.

319{
320 return m_trailer & (0x1 << s_glinkParityBit);
321}
static const int s_glinkParityBit

◆ glinkPinParity() [1/2]

bool LVL1BS::PpmSubBlockV1::glinkPinParity ( ) const
inline

Definition at line 258 of file PpmSubBlockV1.h.

259{
261}
static const int s_glinkPinParityBit

◆ glinkPinParity() [2/2]

bool LVL1BS::PpmSubBlockV1::glinkPinParity ( int chan) const
inline

Definition at line 198 of file PpmSubBlockV1.h.

199{
200 return errorBit(pin(chan), s_glinkPinParityBit);
201}

◆ glinkProtocol()

bool LVL1BS::L1CaloSubBlock::glinkProtocol ( ) const
inlineinherited

Definition at line 313 of file L1CaloSubBlock.h.

314{
315 return m_trailer & (0x1 << s_glinkProtocolBit);
316}
static const int s_glinkProtocolBit

◆ glinkTimeout()

bool LVL1BS::L1CaloSubBlock::glinkTimeout ( ) const
inlineinherited

Definition at line 288 of file L1CaloSubBlock.h.

289{
290 return m_trailer & (0x1 << s_glinkTimeoutBit);
291}
static const int s_glinkTimeoutBit

◆ lutOffset()

int LVL1BS::PpmSubBlockV1::lutOffset ( ) const
inline

Definition at line 343 of file PpmSubBlockV1.h.

344{
345 return (m_lutOffset < 0) ? slicesLut()/2 : m_lutOffset;
346}

◆ mcmAbsent() [1/2]

bool LVL1BS::PpmSubBlockV1::mcmAbsent ( ) const
inline

Definition at line 288 of file PpmSubBlockV1.h.

289{
290 return errorBit(s_mcmAbsentBit);
291}
static const int s_mcmAbsentBit

◆ mcmAbsent() [2/2]

bool LVL1BS::PpmSubBlockV1::mcmAbsent ( int chan) const
inline

Definition at line 228 of file PpmSubBlockV1.h.

229{
230 return errorBit(pin(chan), s_mcmAbsentBit);
231}

◆ minBits()

int LVL1BS::L1CaloSubBlock::minBits ( uint32_t datum) const
inherited

Return the minimum number of bits needed for given data.

Definition at line 274 of file L1CaloSubBlock.cxx.

275{
276 const int maxBits = 32;
277 int nbits = maxBits;
278 for (int i = 0; i < maxBits; ++i)
279 {
280 if ( !(datum >> i))
281 {
282 nbits = i;
283 break;
284 }
285 }
286 return nbits;
287}

◆ module() [1/2]

int LVL1BS::L1CaloSubBlock::module ( ) const
inlineinherited

Definition at line 268 of file L1CaloSubBlock.h.

269{
270 return (m_header >> s_moduleBit) & s_moduleMask;
271}
static const int s_moduleBit
static const uint32_t s_moduleMask

◆ module() [2/2]

int LVL1BS::L1CaloSubBlock::module ( uint32_t word)
staticinherited

Return module field from given header word.

Definition at line 520 of file L1CaloSubBlock.cxx.

521{
522 return (word >> s_moduleBit) & s_moduleMask;
523}

◆ pack()

bool LVL1BS::PpmSubBlockV1::pack ( )

Pack data.

Definition at line 236 of file PpmSubBlockV1.cxx.

237{
238 bool rc = false;
239 switch (version()) {
240 case 1:
241 switch (format()) {
242 case NEUTRAL:
243 rc = packNeutral();
244 break;
245 case UNCOMPRESSED:
246 switch (seqno()) {
247 case s_errorMarker:
249 break;
250 default:
252 break;
253 }
254 break;
255 case COMPRESSED:
256 case SUPERCOMPRESSED:
257 rc = PpmCompressionV1::pack(*this);
258 break;
259 default:
260 break;
261 }
262 break;
263 default:
264 break;
265 }
266 return rc;
267}
static bool pack(PpmSubBlockV1 &subBlock)
Pack data.
bool packUncompressedData()
Pack uncompressed data.
bool packUncompressedErrors()
Pack uncompressed error data.
bool packNeutral()
Pack neutral data.

◆ packer()

void LVL1BS::L1CaloSubBlock::packer ( uint32_t datum,
int nbits )
inherited

Pack given data into given number of bits.

Definition at line 302 of file L1CaloSubBlock.cxx.

303{
304 if (nbits > 0)
305 {
307 m_bitword |= (datum & mask) << m_currentBit;
308 m_currentBit += nbits;
309 if (m_currentBit >= m_maxBits)
310 {
312 m_data.push_back(m_bitword);
313 ++m_dataWords;
314 const int bitsLeft = m_currentBit - m_maxBits;
315 if (bitsLeft > 0)
316 {
317 m_bitword = (datum & mask) >> (nbits - bitsLeft);
318 m_currentBit = bitsLeft;
319 }
320 else
321 {
322 m_bitword = 0;
323 m_currentBit = 0;
324 }
325 }
326 }
327}
std::vector< uint32_t > m_data
Sub-Block data.
std::vector< uint32_t > m_unpackingMasks
Unpacking masks.

◆ packerFlush()

void LVL1BS::L1CaloSubBlock::packerFlush ( )
inherited

Flush the current data word padded with zeros.

Definition at line 331 of file L1CaloSubBlock.cxx.

332{
333 if (m_currentBit > 0)
334 {
336 m_data.push_back(m_bitword);
337 ++m_dataWords;
338 m_bitword = 0;
339 m_currentBit = 0;
340 }
341}

◆ packerNeutral()

void LVL1BS::L1CaloSubBlock::packerNeutral ( int pin,
uint32_t datum,
int nbits )
inherited

Pack given neutral data from given pin.

Definition at line 413 of file L1CaloSubBlock.cxx.

415{
416 if (pin >= 0 && pin < s_maxPins && nbits > 0)
417 {
418 if (m_currentPinBit[pin] + nbits > m_dataWords)
419 {
420 m_dataWords = m_currentPinBit[pin] + nbits;
422 }
423 for (int bit = 0; bit < nbits; ++bit)
424 {
425 m_data[m_currentPinBit[pin] + bit] |= ((datum >> bit) & 0x1) << pin;
426 }
427 m_currentPinBit[pin] += nbits;
428 m_oddParity[pin] = parityBit(m_oddParity[pin], datum, nbits);
429 }
430}
std::vector< int > m_oddParity
int parityBit(int init, uint32_t datum, int nbits) const
Return the parity bit for given data.
static const uint32_t s_glinkDavSet

◆ packerNeutralParity()

void LVL1BS::L1CaloSubBlock::packerNeutralParity ( int pin)
inherited

Pack current G-Link parity bit for given pin.

Definition at line 434 of file L1CaloSubBlock.cxx.

435{
436 if (pin >= 0 && pin < s_maxPins)
437 {
438 packerNeutral(pin, m_oddParity[pin], 1);
439 m_oddParity[pin] = 1;
440 }
441}
static const int s_maxPins
void packerNeutral(int pin, uint32_t datum, int nbits)
Pack given neutral data from given pin.

◆ packNeutral()

bool LVL1BS::PpmSubBlockV1::packNeutral ( )
private

Pack neutral data.

Definition at line 306 of file PpmSubBlockV1.cxx.

307{
308 const int slices = slicesLut() + slicesFadc();
309 const int channels = channelsPerSubBlock();
310 if (m_datamap.empty()) m_datamap.resize(slices * channels);
311 // Bunch crossing number
312 for (int pin = 0; pin < s_glinkPins; ++pin) {
313 uint32_t bc = 0;
314 if (pin < s_bunchCrossingBits) bc = (bunchCrossing() >> pin) & 0x1;
315 packerNeutral(pin, bc, 1);
316 }
317 // Data
318 std::vector<uint32_t>::const_iterator pos = m_datamap.begin();
319 for (int asic = 0; asic < s_asicChannels; ++asic) {
320 for (int pin = 0; pin < s_glinkPins; ++pin) {
321 for (int sl = 0; sl < slices; ++sl) {
323 ++pos;
324 }
325 }
326 }
327 // Errors, including GP
328 if (m_errormap.empty()) m_errormap.resize(s_glinkPins);
329 pos = m_errormap.begin();
330 for (int pin = 0; pin < s_glinkPins; ++pin) {
333 ++pos;
334 }
335 return true;
336}
void packerNeutralParity(int pin)
Pack current G-Link parity bit for given pin.
int bunchCrossing() const
Return the Bunch Crossing number (neutral format only)
static const int s_dataBits
static const int s_bunchCrossingBits
static const int s_errorBits

◆ packUncompressedData()

bool LVL1BS::PpmSubBlockV1::packUncompressedData ( )
private

Pack uncompressed data.

Definition at line 340 of file PpmSubBlockV1.cxx.

341{
342 const int slices = slicesLut() + slicesFadc();
343 const int channels = channelsPerSubBlock();
344 if (m_datamap.empty()) m_datamap.resize(slices * channels);
345 for (int sl = 0; sl < slices; ++sl) {
346 for (int chan = 0; chan < channels; ++chan) {
347 packer(m_datamap[sl + chan * slices], s_wordLen);
348 }
349 }
350 packerFlush();
351 return true;
352}
void packer(uint32_t datum, int nbits)
Pack given data into given number of bits.
void packerFlush()
Flush the current data word padded with zeros.
static const int s_wordLen

◆ packUncompressedErrors()

bool LVL1BS::PpmSubBlockV1::packUncompressedErrors ( )
private

Pack uncompressed error data.

Definition at line 356 of file PpmSubBlockV1.cxx.

357{
358 if (m_errormap.empty()) m_errormap.resize(s_glinkPins);
359 for (int pin = 0; pin < s_glinkPins; ++pin) {
361 }
362 packerFlush();
363 return true;
364}

◆ parityBit()

int LVL1BS::L1CaloSubBlock::parityBit ( int init,
uint32_t datum,
int nbits ) const
inherited

Return the parity bit for given data.

Definition at line 291 of file L1CaloSubBlock.cxx.

293{
294 // set init to 0/1 for even/odd parity
295 int parity = init;
296 for (int bit = 0; bit < nbits; ++bit) parity ^= (datum >> bit) & 0x1;
297 return parity;
298}
init(v_theApp, v_rootStream=None)
Definition PyKernel.py:45

◆ pedestal()

int LVL1BS::PpmSubBlockV1::pedestal ( ) const
inline

Definition at line 353 of file PpmSubBlockV1.h.

354{
355 return m_pedestal;
356}

◆ pin()

int LVL1BS::PpmSubBlockV1::pin ( int chan) const
inlineprivate

Return the G-Link pin corresponding to a data channel.

Definition at line 388 of file PpmSubBlockV1.h.

389{
390 return chan % s_glinkPins;
391}

◆ ppmData()

void LVL1BS::PpmSubBlockV1::ppmData ( int chan,
std::vector< int > & lut,
std::vector< int > & fadc,
std::vector< int > & bcidLut,
std::vector< int > & bcidFadc )

Return unpacked data for given channel.

Definition at line 144 of file PpmSubBlockV1.cxx.

148{
149 lut.clear();
150 fadc.clear();
151 bcidLut.clear();
152 bcidFadc.clear();
153 const int sliceL = slicesLut();
154 const int sliceF = slicesFadc();
155 // coverity[divide_by_zero : FALSE]
156 int beg = (chan % channelsPerSubBlock()) * (sliceL + sliceF);
157 int end = beg + sliceL;
158 if (size_t(end + sliceF) <= m_datamap.size()) {
159 for (int pos = beg; pos < end; ++pos) {
160 const uint32_t word = m_datamap[pos];
161 lut.push_back((word >> s_lutBit) & s_lutMask);
162 bcidLut.push_back((word >> s_bcidLutBit) & s_bcidLutMask);
163 }
164 beg += sliceL;
165 end += sliceF;
166 for (int pos = beg; pos < end; ++pos) {
167 const uint32_t word = m_datamap[pos];
168 fadc.push_back((word >> s_fadcBit) & s_fadcMask);
169 bcidFadc.push_back((word >> s_bcidFadcBit) & s_bcidFadcMask);
170 }
171 } else {
172 lut.resize(sliceL);
173 fadc.resize(sliceF);
174 bcidLut.resize(sliceL);
175 bcidFadc.resize(sliceF);
176 }
177}

◆ ppmError()

int LVL1BS::PpmSubBlockV1::ppmError ( int chan) const

Return the error word for a data channel.

Definition at line 206 of file PpmSubBlockV1.cxx.

207{
208 int err = 0;
209 if ( !m_errormap.empty()) {
210 // Replace the four ASIC channel disabled bits with just the one
211 // corresponding to the data channel
212 err = (((m_errormap[pin(chan)] & s_errorMask) >> s_asicChannels) << 1)
213 | channelDisabled(chan);
214 }
215 return err;
216}
bool channelDisabled(int chan) const

◆ ppmPinError()

int LVL1BS::PpmSubBlockV1::ppmPinError ( int pin) const

Return the error word for a G-Link pin.

Definition at line 220 of file PpmSubBlockV1.cxx.

221{
222 int err = 0;
223 if ( !m_errormap.empty()) err = m_errormap[pin] & s_errorMask;
224 return err;
225}

◆ read()

Input complete packed sub-block from ROD array.

Definition at line 118 of file L1CaloSubBlock.cxx.

121{
122 m_dataWords = 0;
123 m_unpackerFlag = true;
126 for (; pos != pose; ++pos)
127 {
128 const uint32_t word = *pos;
129 const SubBlockWordType type = wordType(word);
130 if (type == HEADER)
131 {
132 if (m_header) return pos;
133 m_header = word;
134 }
135 else if (type == STATUS)
136 {
137 // Word ID should be consistent with header
138 if (m_trailer || (wordId(word) != wordId() + 1)) return pos;
139 m_trailer = word;
140 }
141 else
142 {
143 // Check data word IDs
144 const int id = wordId(word);
145 bool badId = false;
146 // All neutral format '0000'
147 if (format() == NEUTRAL) badId = (id != 0);
148 // Other PPM '0xxx'
149 else if (crate() < s_ppmCrates) badId = ((id & 0x8) != 0);
150 // Other CPM/JEM '01xx' or '10xx'
151 else if (wordId() == 0xc) badId = (((id & 0xc) != 0x4) &&
152 ((id & 0xc) != 0x8));
153 // Other CMM/CMX '00xx'
154 else badId = ((id & 0xc) != 0);
155 if (m_trailer || badId) return pos;
156 m_data.push_back(word);
157 ++m_dataWords;
158 }
159 }
160 return pose;
161}
static const int s_ppmCrates
static SubBlockWordType wordType(uint32_t word)
Word identification.
const DataType * PointerType
Definition RawEvent.h:25

◆ runNumber()

int LVL1BS::PpmSubBlockV1::runNumber ( ) const
inline

Definition at line 368 of file PpmSubBlockV1.h.

369{
370 return m_runNumber;
371}

◆ seqno() [1/2]

int LVL1BS::L1CaloSubBlock::seqno ( ) const
inlineinherited

Definition at line 253 of file L1CaloSubBlock.h.

254{
255 return (m_header >> s_seqnoBit) & s_seqnoMask;
256}
static const uint32_t s_seqnoMask
static const int s_seqnoBit

◆ seqno() [2/2]

int LVL1BS::L1CaloSubBlock::seqno ( uint32_t word)
staticinherited

Return seqno field from given header word.

Definition at line 513 of file L1CaloSubBlock.cxx.

514{
515 return (word >> s_seqnoBit) & s_seqnoMask;
516}

◆ setBunchCrossing()

void LVL1BS::L1CaloSubBlock::setBunchCrossing ( int bc)
inlineinherited

Set the Bunch Crossing number (neutral format only)

Definition at line 328 of file L1CaloSubBlock.h.

329{
330 if (bc) m_bunchCrossing = bc;
331}

◆ setCompStats()

void LVL1BS::PpmSubBlockV1::setCompStats ( const std::vector< uint32_t > & stats)
inline

Set compression stats.

Definition at line 378 of file PpmSubBlockV1.h.

◆ setDaqOverflow()

void LVL1BS::L1CaloSubBlock::setDaqOverflow ( int bit = 1)
inherited

Set DAQ FIFO Overflow bit in Sub-status word.

Definition at line 206 of file L1CaloSubBlock.cxx.

207{
208 if (bit)
209 {
210 if (m_trailer) m_trailer |= (1 << s_daqOverflowBit);
211 else setStatus(0, false, false, false, true, false, false, false);
212 }
213}
void setStatus(uint32_t failingBCN, bool glinkTimeout, bool glinkDown, bool upstreamError, bool daqOverflow, bool bcnMismatch, bool glinkProtocol, bool glinkParity)
Store error status trailer.

◆ setFadcBaseline()

void LVL1BS::PpmSubBlockV1::setFadcBaseline ( int baseline)
inline

Definition at line 328 of file PpmSubBlockV1.h.

329{
331}
@ baseline

◆ setFadcOffset()

void LVL1BS::PpmSubBlockV1::setFadcOffset ( int offset)
inline

Definition at line 318 of file PpmSubBlockV1.h.

319{
321}

◆ setFadcThreshold()

void LVL1BS::PpmSubBlockV1::setFadcThreshold ( int threshold)
inline

Definition at line 333 of file PpmSubBlockV1.h.

◆ setGlinkParity()

void LVL1BS::L1CaloSubBlock::setGlinkParity ( int bit = 1)
inherited

Set G-Link Parity bit in Sub-status word.

Definition at line 217 of file L1CaloSubBlock.cxx.

218{
219 if (bit)
220 {
221 if (m_trailer) m_trailer |= (1 << s_glinkParityBit);
222 else setStatus(0, false, false, false, false, false, false, true);
223 }
224}

◆ setHeader()

void LVL1BS::L1CaloSubBlock::setHeader ( int wordId,
int version,
int format,
int seqno,
int crate,
int module,
int slices2,
int slices1 )
inherited

Store header data.

Definition at line 99 of file L1CaloSubBlock.cxx.

103{
104 uint32_t word = 0;
105 word |= (wordId & s_wordIdMask) << s_wordIdBit;
106 word |= (version & s_versionMask) << s_versionBit;
107 word |= (format & s_formatMask) << s_formatBit;
108 word |= (seqno & s_seqnoMask) << s_seqnoBit;
109 word |= (crate & s_crateMask) << s_crateBit;
110 word |= (module & s_moduleMask) << s_moduleBit;
111 word |= (slices2 & s_slices2Mask) << s_slices2Bit;
112 word |= (slices1 & s_slices1Mask) << s_slices1Bit;
113 m_header = word;
114}
static const uint32_t s_wordIdMask
static const uint32_t s_slices1Mask
static const int s_slices2Bit
static const int s_versionBit
static const int s_slices1Bit
static const int s_wordIdBit
static const uint32_t s_versionMask
static const uint32_t s_slices2Mask

◆ setLutOffset()

void LVL1BS::PpmSubBlockV1::setLutOffset ( int offset)
inline

Definition at line 313 of file PpmSubBlockV1.h.

314{
316}

◆ setPedestal()

void LVL1BS::PpmSubBlockV1::setPedestal ( int pedval)
inline

Definition at line 323 of file PpmSubBlockV1.h.

324{
325 m_pedestal = pedval;
326}

◆ setPpmErrorHeader()

void LVL1BS::PpmSubBlockV1::setPpmErrorHeader ( int version,
int format,
int crate,
int module,
int slicesFadc,
int slicesLut )

Store PPM error block header.

Definition at line 79 of file PpmSubBlockV1.cxx.

82{
85}
void setHeader(int wordId, int version, int format, int seqno, int crate, int module, int slices2, int slices1)
Store header data.
static const uint32_t s_wordIdVal

◆ setPpmHeader()

void LVL1BS::PpmSubBlockV1::setPpmHeader ( int version,
int format,
int seqno,
int crate,
int module,
int slicesFadc,
int slicesLut )

Store PPM header.

Definition at line 68 of file PpmSubBlockV1.cxx.

◆ setRunNumber()

void LVL1BS::PpmSubBlockV1::setRunNumber ( int run)
inline

Definition at line 338 of file PpmSubBlockV1.h.

◆ setStatus()

void LVL1BS::L1CaloSubBlock::setStatus ( uint32_t failingBCN,
bool glinkTimeout,
bool glinkDown,
bool upstreamError,
bool daqOverflow,
bool bcnMismatch,
bool glinkProtocol,
bool glinkParity )
inherited

Store error status trailer.

Definition at line 179 of file L1CaloSubBlock.cxx.

183{
184 uint32_t word = 0;
187 word |= glinkDown << s_glinkDownBit;
189 word |= daqOverflow << s_daqOverflowBit;
190 word |= bcnMismatch << s_bcnMismatchBit;
192 word |= glinkParity << s_glinkParityBit;
193 if (word)
194 {
195 word |= (wordId() & s_wordIdMask) << s_wordIdBit;
196 word |= (s_statusVal & s_statusMask) << s_statusBit;
197 word |= (seqno() & s_seqnoMask) << s_seqnoBit;
198 word |= (crate() & s_crateMask) << s_crateBit;
199 word |= (module() & s_moduleMask) << s_moduleBit;
200 }
201 m_trailer = word;
202}
static const int s_upstreamErrorBit
uint32_t failingBCN() const
static const uint32_t s_statusVal
static const int s_statusBit
static const uint32_t s_statusMask

◆ setStreamed()

void LVL1BS::L1CaloSubBlock::setStreamed ( )
inlineinherited

Set continuous bit streaming for compressed formats.

Definition at line 348 of file L1CaloSubBlock.h.

349{
352}
static const uint32_t s_maxStreamedMask
static const int s_maxStreamedBits

◆ setUnpackErrorCode()

void LVL1BS::L1CaloSubBlock::setUnpackErrorCode ( int code)
inlineinherited

Set the unpacking error code.

Definition at line 338 of file L1CaloSubBlock.h.

339{
341}
int m_unpackError
Unpacking error code.

◆ slice()

int LVL1BS::L1CaloSubBlock::slice ( ) const
inlineinherited

Definition at line 258 of file L1CaloSubBlock.h.

259{
260 return seqno();
261}

◆ slices1()

int LVL1BS::L1CaloSubBlock::slices1 ( ) const
inlineinherited

Definition at line 278 of file L1CaloSubBlock.h.

279{
280 return (m_header >> s_slices1Bit) & s_slices1Mask;
281}

◆ slices2()

int LVL1BS::L1CaloSubBlock::slices2 ( ) const
inlineinherited

Definition at line 273 of file L1CaloSubBlock.h.

274{
275 return (m_header >> s_slices2Bit) & s_slices2Mask;
276}

◆ slicesFadc()

int LVL1BS::PpmSubBlockV1::slicesFadc ( ) const

Definition at line 89 of file PpmSubBlockV1.cxx.

90{
91 int slices = slices2();
92 if (slices == 0 && format() == NEUTRAL) {
94 }
95 if (slices <= 0) slices = 1;
96 return slices;
97}
int dataWords() const
Return number of data words.

◆ slicesLut()

int LVL1BS::PpmSubBlockV1::slicesLut ( ) const

Definition at line 101 of file PpmSubBlockV1.cxx.

102{
103 int slices = slices1();
104 if (slices == 0) slices = 1;
105 return slices;
106}

◆ subStatus()

uint32_t LVL1BS::L1CaloSubBlock::subStatus ( ) const
inlineinherited

Return Sub-status word.

Definition at line 323 of file L1CaloSubBlock.h.

324{
325 return m_trailer;
326}

◆ timeout() [1/2]

bool LVL1BS::PpmSubBlockV1::timeout ( ) const
inline

Definition at line 283 of file PpmSubBlockV1.h.

284{
285 return errorBit(s_timeoutBit);
286}
static const int s_timeoutBit

◆ timeout() [2/2]

bool LVL1BS::PpmSubBlockV1::timeout ( int chan) const
inline

Definition at line 223 of file PpmSubBlockV1.h.

224{
225 return errorBit(pin(chan), s_timeoutBit);
226}

◆ unpack()

bool LVL1BS::PpmSubBlockV1::unpack ( )

Unpack data.

Definition at line 269 of file PpmSubBlockV1.cxx.

270{
271 bool rc = false;
272 switch (version()) {
273 case 1:
274 switch (format()) {
275 case NEUTRAL:
276 rc = unpackNeutral();
277 break;
278 case UNCOMPRESSED:
279 switch (seqno()) {
280 case s_errorMarker:
282 break;
283 default:
285 break;
286 }
287 break;
288 case COMPRESSED:
289 case SUPERCOMPRESSED:
291 break;
292 default:
294 break;
295 }
296 break;
297 default:
299 break;
300 }
301 return rc;
302}
static bool unpack(PpmSubBlockV1 &subBlock)
Unpack data.
bool unpackUncompressedData()
Unpack uncompressed data.
bool unpackUncompressedErrors()
Unpack uncompressed error data.
bool unpackNeutral()
Unpack neutral data.

◆ unpacker() [1/2]

uint32_t LVL1BS::L1CaloSubBlock::unpacker ( int nbits)
inherited

Unpack given number of bits of data.

Definition at line 345 of file L1CaloSubBlock.cxx.

346{
347 uint32_t word = 0;
348 if (nbits > 0)
349 {
350 if (m_dataPos == m_dataPosEnd)
351 {
352 m_unpackerFlag = false;
353 return 0;
354 }
355 int nbitsDone = nbits;
356 if (nbitsDone > m_maxBits - m_currentBit)
357 {
358 nbitsDone = m_maxBits - m_currentBit;
359 }
360 word = (m_bitword >> m_currentBit) & m_unpackingMasks[nbitsDone];
361 m_currentBit += nbits;
362
363 if (m_currentBit >= m_maxBits)
364 {
365 m_bitword = 0;
366 if (m_dataPos != m_dataPosEnd)
367 {
368 ++m_dataPos;
369 if (m_dataPos != m_dataPosEnd)
370 {
372 }
373 }
374 m_currentBit = 0;
375 const int bitsLeft = nbits - nbitsDone;
376 if (bitsLeft > 0)
377 {
378 if (m_dataPos == m_dataPosEnd)
379 {
380 m_unpackerFlag = false;
381 return word;
382 }
383 word |= (m_bitword & m_unpackingMasks[bitsLeft]) << nbitsDone;
384 m_currentBit = bitsLeft;
385 }
386 }
387 }
388 return word;
389}
std::vector< uint32_t >::const_iterator m_dataPos
std::vector< uint32_t >::const_iterator m_dataPosEnd

◆ unpacker() [2/2]

uint32_t LVL1BS::L1CaloSubBlock::unpacker ( int nbits,
int align )
inherited

◆ unpackerInit()

void LVL1BS::L1CaloSubBlock::unpackerInit ( )
inherited

Initialise unpacker.

Definition at line 393 of file L1CaloSubBlock.cxx.

394{
395 m_bitword = 0;
396 m_currentBit = 0;
397 m_unpackerFlag = true;
398 m_dataPos = m_data.begin();
399 m_dataPosEnd = m_data.end();
400 // std::cout << "SASHA4 m_dataPosEnd - m_dataPos=" << (m_dataPosEnd - m_dataPos) << std::endl;
401 // uint16_t a = (*m_dataPos) & 0xFF;
402 // uint16_t b = (*m_dataPos >> 11) & 0xFF;
403
404 // std::cout << "SASHA5 first " << a << std::endl;
405 // std::cout << "SASHA5 second " << b << std::endl;
406 // std::cout << "SASHA5 datawords " << m_data.size() << std::endl;
407
409}

◆ unpackerNeutral()

uint32_t LVL1BS::L1CaloSubBlock::unpackerNeutral ( int pin,
int nbits )
inherited

Unpack given number of bits of neutral data for given pin.

Definition at line 445 of file L1CaloSubBlock.cxx.

446{
447 uint32_t word = 0;
448 if (pin >= 0 && pin < s_maxPins && nbits > 0
449 && m_currentPinBit[pin] + nbits <= m_dataWords)
450 {
451 for (int bit = 0; bit < nbits; ++bit)
452 {
453 word |= ((m_data[m_currentPinBit[pin] + bit] >> pin) & 0x1) << bit;
454 }
455 m_currentPinBit[pin] += nbits;
456 m_oddParity[pin] = parityBit(m_oddParity[pin], word, nbits);
457 }
458 else m_unpackerFlag = false;
459 return word;
460}

◆ unpackerNeutralParityError()

bool LVL1BS::L1CaloSubBlock::unpackerNeutralParityError ( int pin)
inherited

Unpack and test G-Link parity bit for given pin.

Definition at line 464 of file L1CaloSubBlock.cxx.

465{
466 bool error = true;
467 if (pin >= 0 && pin < s_maxPins)
468 {
469 int parity = m_oddParity[pin];
470 int bit = unpackerNeutral(pin, 1);
471 m_oddParity[pin] = 1;
472 error = !(bit == parity);
473 }
474 return error;
475}
uint32_t unpackerNeutral(int pin, int nbits)
Unpack given number of bits of neutral data for given pin.

◆ unpackErrorCode()

int LVL1BS::L1CaloSubBlock::unpackErrorCode ( ) const
inlineinherited

Return the unpacking error code.

Definition at line 343 of file L1CaloSubBlock.h.

344{
345 return m_unpackError;
346}

◆ unpackErrorMsg()

std::string LVL1BS::L1CaloSubBlock::unpackErrorMsg ( ) const
inherited

Return the unpacking error message for printing.

Definition at line 228 of file L1CaloSubBlock.cxx.

229{
230 std::string msg;
231 switch (m_unpackError)
232 {
233 case UNPACK_NONE:
234 msg = "No error";
235 break;
236 case UNPACK_VERSION:
237 msg = "Unsupported Data Version";
238 break;
239 case UNPACK_FORMAT:
240 msg = "Unsupported Data Format";
241 break;
243 msg = "Unsupported Compression Version";
244 break;
246 msg = "Unsupported Number of Slices for Compression Version";
247 break;
249 msg = "Premature End of Sub-block Data";
250 break;
252 msg = "Excess Data in Sub-block";
253 break;
254 case UNPACK_SOURCE_ID:
255 msg = "Invalid Source ID in Sub-block Data";
256 break;
258 msg = "Excess TOBs in Sub-block Data";
259 break;
260 case UNPACK_DATA_ID:
261 msg = "Invalid word ID in Sub-block Data";
262 break;
263 default:
264 msg = "Unknown Error Code";
265 break;
266 }
267 return msg;
268}
MsgStream & msg
Definition testRead.cxx:32

◆ unpackerSuccess()

bool LVL1BS::L1CaloSubBlock::unpackerSuccess ( ) const
inlineinherited

Return unpacker success flag.

Definition at line 354 of file L1CaloSubBlock.h.

355{
356 return m_unpackerFlag;
357}

◆ unpackNeutral()

bool LVL1BS::PpmSubBlockV1::unpackNeutral ( )
private

Unpack neutral data.

Definition at line 368 of file PpmSubBlockV1.cxx.

369{
370 const int slices = slicesLut() + slicesFadc();
371 m_datamap.clear();
372 // Bunch Crossing number
373 int bunchCrossing = 0;
374 for (int pin = 0; pin < s_glinkPins; ++pin) {
375 const int bc = unpackerNeutral(pin, 1);
377 }
379 // Data
380 for (int asic = 0; asic < s_asicChannels; ++asic) {
381 for (int pin = 0; pin < s_glinkPins; ++pin) {
382 for (int sl = 0; sl < slices; ++sl) {
384 }
385 }
386 }
387 const bool rc = unpackerSuccess();
389 // Errors
390 m_errormap.clear();
391 m_globalError = 0;
392 for (int pin = 0; pin < s_glinkPins; ++pin) {
395 m_errormap.push_back(error);
397 }
398 return rc;
399}
bool unpackerSuccess() const
Return unpacker success flag.
bool unpackerNeutralParityError(int pin)
Unpack and test G-Link parity bit for given pin.
void setBunchCrossing(int bc)
Set the Bunch Crossing number (neutral format only)

◆ unpackUncompressedData()

bool LVL1BS::PpmSubBlockV1::unpackUncompressedData ( )
private

Unpack uncompressed data.

Definition at line 403 of file PpmSubBlockV1.cxx.

404{
405 const int slices = slicesLut() + slicesFadc();
406 const int channels = channelsPerSubBlock();
407 m_datamap.resize(slices * channels);
408 unpackerInit();
409 for (int sl = 0; sl < slices; ++sl) {
410 for (int chan = 0; chan < channels; ++chan) {
412 }
413 }
414 bool rc = unpackerSuccess();
416 else {
417 // Check no more non-zero data
418 while (unpackerSuccess()) {
419 if (unpacker(s_wordLen)) {
421 rc = false;
422 break;
423 }
424 }
425 }
426 return rc;
427}
uint32_t unpacker(int nbits)
Unpack given number of bits of data.
void unpackerInit()
Initialise unpacker.

◆ unpackUncompressedErrors()

bool LVL1BS::PpmSubBlockV1::unpackUncompressedErrors ( )
private

Unpack uncompressed error data.

Definition at line 431 of file PpmSubBlockV1.cxx.

432{
433 unpackerInit();
434 m_errormap.clear();
435 m_globalError = 0;
436 for (int pin = 0; pin < s_glinkPins; ++pin) {
438 m_errormap.push_back(word);
439 m_globalError |= word;
440 }
441 bool rc = unpackerSuccess();
443 else {
444 while (unpackerSuccess()) {
445 if (unpacker(s_wordLen)) {
447 rc = false;
448 break;
449 }
450 }
451 }
452 return rc;
453}

◆ upstreamError()

bool LVL1BS::L1CaloSubBlock::upstreamError ( ) const
inlineinherited

Definition at line 298 of file L1CaloSubBlock.h.

299{
300 return m_trailer & (0x1 << s_upstreamErrorBit);
301}

◆ version() [1/2]

int LVL1BS::L1CaloSubBlock::version ( ) const
inlineinherited

Definition at line 243 of file L1CaloSubBlock.h.

244{
245 return (m_header >> s_versionBit) & s_versionMask;
246}

◆ version() [2/2]

int LVL1BS::L1CaloSubBlock::version ( uint32_t word)
staticinherited

Return version number from given header word.

Definition at line 499 of file L1CaloSubBlock.cxx.

500{
501 return (word >> s_versionBit) & s_versionMask;
502}

◆ wordId() [1/2]

int LVL1BS::L1CaloSubBlock::wordId ( ) const
inlineinherited

Definition at line 238 of file L1CaloSubBlock.h.

239{
240 return (m_header >> s_wordIdBit) & s_wordIdMask;
241}

◆ wordId() [2/2]

int LVL1BS::L1CaloSubBlock::wordId ( uint32_t word)
staticinherited

Return wordID field from given header word.

Definition at line 492 of file L1CaloSubBlock.cxx.

493{
494 return (word >> s_wordIdBit) & s_wordIdMask;
495}

◆ wordType()

L1CaloSubBlock::SubBlockWordType LVL1BS::L1CaloSubBlock::wordType ( uint32_t word)
staticinherited

Word identification.

Definition at line 479 of file L1CaloSubBlock.cxx.

480{
482 if (((word >> s_headerBit) & s_headerMask) == s_headerVal)
483 {
484 if (((word >> s_statusBit) & s_statusMask) == s_statusVal) type = STATUS;
485 else type = HEADER;
486 }
487 return type;
488}
static const int s_headerBit
static const uint32_t s_headerVal
static const uint32_t s_headerMask

◆ write()

void LVL1BS::L1CaloSubBlock::write ( FullEventAssembler< L1CaloSrcIdMap >::RODDATA * theROD) const
inherited

Output complete packed sub-block to ROD vector.

Definition at line 165 of file L1CaloSubBlock.cxx.

167{
168 theROD->push_back(m_header);
169 std::vector<uint32_t>::const_iterator pos;
170 for (pos = m_data.begin(); pos != m_data.end(); ++pos)
171 {
172 theROD->push_back(*pos);
173 }
174 if (m_trailer) theROD->push_back(m_trailer);
175}

Member Data Documentation

◆ m_bitword

uint32_t LVL1BS::L1CaloSubBlock::m_bitword
privateinherited

Definition at line 214 of file L1CaloSubBlock.h.

◆ m_bunchCrossing

int LVL1BS::L1CaloSubBlock::m_bunchCrossing
privateinherited

Bunch Crossing number (neutral format only)

Definition at line 210 of file L1CaloSubBlock.h.

◆ m_compStats

std::vector<uint32_t> LVL1BS::PpmSubBlockV1::m_compStats
private

Vector for compression statistics.

Definition at line 188 of file PpmSubBlockV1.h.

◆ m_currentBit

int LVL1BS::L1CaloSubBlock::m_currentBit
privateinherited

Definition at line 215 of file L1CaloSubBlock.h.

◆ m_currentPinBit

std::vector<int> LVL1BS::L1CaloSubBlock::m_currentPinBit
privateinherited

Definition at line 222 of file L1CaloSubBlock.h.

◆ m_data

std::vector<uint32_t> LVL1BS::L1CaloSubBlock::m_data
privateinherited

Sub-Block data.

Definition at line 227 of file L1CaloSubBlock.h.

◆ m_datamap

std::vector<uint32_t> LVL1BS::PpmSubBlockV1::m_datamap
private

Vector for intermediate data.

Definition at line 191 of file PpmSubBlockV1.h.

◆ m_dataPos

std::vector<uint32_t>::const_iterator LVL1BS::L1CaloSubBlock::m_dataPos {}
privateinherited

Definition at line 219 of file L1CaloSubBlock.h.

219{};

◆ m_dataPosEnd

std::vector<uint32_t>::const_iterator LVL1BS::L1CaloSubBlock::m_dataPosEnd {}
privateinherited

Definition at line 220 of file L1CaloSubBlock.h.

220{};

◆ m_dataWords

int LVL1BS::L1CaloSubBlock::m_dataWords
privateinherited

Current number of data words.

Definition at line 225 of file L1CaloSubBlock.h.

◆ m_errormap

std::vector<uint32_t> LVL1BS::PpmSubBlockV1::m_errormap
private

Vector for intermediate error data.

Definition at line 194 of file PpmSubBlockV1.h.

◆ m_fadcBaseline

int LVL1BS::PpmSubBlockV1::m_fadcBaseline
private

Definition at line 183 of file PpmSubBlockV1.h.

◆ m_fadcOffset

int LVL1BS::PpmSubBlockV1::m_fadcOffset
private

Definition at line 181 of file PpmSubBlockV1.h.

◆ m_fadcThreshold

int LVL1BS::PpmSubBlockV1::m_fadcThreshold
private

Definition at line 184 of file PpmSubBlockV1.h.

◆ m_globalError

uint32_t LVL1BS::PpmSubBlockV1::m_globalError
private

Definition at line 177 of file PpmSubBlockV1.h.

◆ m_header

uint32_t LVL1BS::L1CaloSubBlock::m_header
privateinherited

Sub-Block Header.

Definition at line 206 of file L1CaloSubBlock.h.

◆ m_lutOffset

int LVL1BS::PpmSubBlockV1::m_lutOffset
private

Definition at line 180 of file PpmSubBlockV1.h.

◆ m_maxBits

int LVL1BS::L1CaloSubBlock::m_maxBits
privateinherited

Definition at line 216 of file L1CaloSubBlock.h.

◆ m_maxMask

uint32_t LVL1BS::L1CaloSubBlock::m_maxMask
privateinherited

Definition at line 217 of file L1CaloSubBlock.h.

◆ m_oddParity

std::vector<int> LVL1BS::L1CaloSubBlock::m_oddParity
privateinherited

Definition at line 223 of file L1CaloSubBlock.h.

◆ m_pedestal

int LVL1BS::PpmSubBlockV1::m_pedestal
private

Definition at line 182 of file PpmSubBlockV1.h.

◆ m_runNumber

int LVL1BS::PpmSubBlockV1::m_runNumber
private

Definition at line 185 of file PpmSubBlockV1.h.

◆ m_trailer

uint32_t LVL1BS::L1CaloSubBlock::m_trailer
privateinherited

Sub-Block Status Trailer.

Definition at line 208 of file L1CaloSubBlock.h.

◆ m_unpackerFlag

bool LVL1BS::L1CaloSubBlock::m_unpackerFlag
privateinherited

Definition at line 218 of file L1CaloSubBlock.h.

◆ m_unpackError

int LVL1BS::L1CaloSubBlock::m_unpackError
privateinherited

Unpacking error code.

Definition at line 212 of file L1CaloSubBlock.h.

◆ m_unpackingMasks

std::vector<uint32_t> LVL1BS::L1CaloSubBlock::m_unpackingMasks
privateinherited

Unpacking masks.

Definition at line 229 of file L1CaloSubBlock.h.

◆ s_asicChannels

const int LVL1BS::PpmSubBlockV1::s_asicChannels = 4
staticprivate

Definition at line 137 of file PpmSubBlockV1.h.

◆ s_asicFullBit

const int LVL1BS::PpmSubBlockV1::s_asicFullBit = 6
staticprivate

Definition at line 147 of file PpmSubBlockV1.h.

◆ s_bcidFadcBit

const int LVL1BS::PpmSubBlockV1::s_bcidFadcBit = 0
staticprivate

Definition at line 129 of file PpmSubBlockV1.h.

◆ s_bcidFadcMask

const uint32_t LVL1BS::PpmSubBlockV1::s_bcidFadcMask = 0x1
staticprivate

Definition at line 133 of file PpmSubBlockV1.h.

◆ s_bcidLutBit

const int LVL1BS::PpmSubBlockV1::s_bcidLutBit = 8
staticprivate

Definition at line 127 of file PpmSubBlockV1.h.

◆ s_bcidLutMask

const uint32_t LVL1BS::PpmSubBlockV1::s_bcidLutMask = 0x7
staticprivate

Definition at line 131 of file PpmSubBlockV1.h.

◆ s_bcnMismatchBit

const int LVL1BS::L1CaloSubBlock::s_bcnMismatchBit = 2
staticprivateinherited

Definition at line 192 of file L1CaloSubBlock.h.

◆ s_bunchCrossingBits

const int LVL1BS::PpmSubBlockV1::s_bunchCrossingBits = 12
staticprivate

Definition at line 140 of file PpmSubBlockV1.h.

◆ s_bunchMismatchBit

const int LVL1BS::PpmSubBlockV1::s_bunchMismatchBit = 8
staticprivate

Definition at line 145 of file PpmSubBlockV1.h.

◆ s_channelDisabledBit

const int LVL1BS::PpmSubBlockV1::s_channelDisabledBit = 0
staticprivate

Definition at line 150 of file PpmSubBlockV1.h.

◆ s_channels

const int LVL1BS::PpmSubBlockV1::s_channels = 64
staticprivate

Definition at line 135 of file PpmSubBlockV1.h.

◆ s_crateBit

const int LVL1BS::L1CaloSubBlock::s_crateBit = 12
staticprivateinherited

Definition at line 174 of file L1CaloSubBlock.h.

◆ s_crateMask

const uint32_t LVL1BS::L1CaloSubBlock::s_crateMask = 0xf
staticprivateinherited

Definition at line 182 of file L1CaloSubBlock.h.

◆ s_daqOverflowBit

const int LVL1BS::L1CaloSubBlock::s_daqOverflowBit = 3
staticprivateinherited

Definition at line 191 of file L1CaloSubBlock.h.

◆ s_dataBits

const int LVL1BS::PpmSubBlockV1::s_dataBits = 11
staticprivate

Definition at line 138 of file PpmSubBlockV1.h.

◆ s_errorBits

const int LVL1BS::PpmSubBlockV1::s_errorBits = 10
staticprivate

Definition at line 139 of file PpmSubBlockV1.h.

◆ s_errorMarker

const int LVL1BS::PpmSubBlockV1::s_errorMarker = 63
staticprivate

Definition at line 123 of file PpmSubBlockV1.h.

◆ s_errorMask

const uint32_t LVL1BS::PpmSubBlockV1::s_errorMask = 0x7ff
staticprivate

Definition at line 142 of file PpmSubBlockV1.h.

◆ s_eventMismatchBit

const int LVL1BS::PpmSubBlockV1::s_eventMismatchBit = 7
staticprivate

Definition at line 146 of file PpmSubBlockV1.h.

◆ s_fadcBit

const int LVL1BS::PpmSubBlockV1::s_fadcBit = 1
staticprivate

Definition at line 128 of file PpmSubBlockV1.h.

◆ s_fadcMask

const uint32_t LVL1BS::PpmSubBlockV1::s_fadcMask = 0x3ff
staticprivate

Definition at line 132 of file PpmSubBlockV1.h.

◆ s_failingBcnBit

const int LVL1BS::L1CaloSubBlock::s_failingBcnBit = 22
staticprivateinherited

Definition at line 187 of file L1CaloSubBlock.h.

◆ s_failingBcnMask

const uint32_t LVL1BS::L1CaloSubBlock::s_failingBcnMask = 0x3f
staticprivateinherited

Definition at line 195 of file L1CaloSubBlock.h.

◆ s_formatBit

const int LVL1BS::L1CaloSubBlock::s_formatBit = 22
staticprivateinherited

Definition at line 172 of file L1CaloSubBlock.h.

◆ s_formatMask

const uint32_t LVL1BS::L1CaloSubBlock::s_formatMask = 0x7
staticprivateinherited

Definition at line 180 of file L1CaloSubBlock.h.

◆ s_fpgaCorruptBit

const int LVL1BS::PpmSubBlockV1::s_fpgaCorruptBit = 9
staticprivate

Definition at line 144 of file PpmSubBlockV1.h.

◆ s_glinkDavSet

const uint32_t LVL1BS::L1CaloSubBlock::s_glinkDavSet = 0x400000
staticprivateinherited

Definition at line 203 of file L1CaloSubBlock.h.

◆ s_glinkDownBit

const int LVL1BS::L1CaloSubBlock::s_glinkDownBit = 6
staticprivateinherited

Definition at line 189 of file L1CaloSubBlock.h.

◆ s_glinkParityBit

const int LVL1BS::L1CaloSubBlock::s_glinkParityBit = 0
staticprivateinherited

Definition at line 194 of file L1CaloSubBlock.h.

◆ s_glinkPinParityBit

const int LVL1BS::PpmSubBlockV1::s_glinkPinParityBit = 10
staticprivate

Definition at line 143 of file PpmSubBlockV1.h.

◆ s_glinkPins

const int LVL1BS::PpmSubBlockV1::s_glinkPins = 16
staticprivate

Definition at line 136 of file PpmSubBlockV1.h.

◆ s_glinkProtocolBit

const int LVL1BS::L1CaloSubBlock::s_glinkProtocolBit = 1
staticprivateinherited

Definition at line 193 of file L1CaloSubBlock.h.

◆ s_glinkTimeoutBit

const int LVL1BS::L1CaloSubBlock::s_glinkTimeoutBit = 7
staticprivateinherited

Definition at line 188 of file L1CaloSubBlock.h.

◆ s_headerBit

const int LVL1BS::L1CaloSubBlock::s_headerBit = 30
staticprivateinherited

Definition at line 161 of file L1CaloSubBlock.h.

◆ s_headerMask

const uint32_t LVL1BS::L1CaloSubBlock::s_headerMask = 0x3
staticprivateinherited

Definition at line 163 of file L1CaloSubBlock.h.

◆ s_headerVal

const uint32_t LVL1BS::L1CaloSubBlock::s_headerVal = 0x3
staticprivateinherited

Definition at line 165 of file L1CaloSubBlock.h.

◆ s_lutBit

const int LVL1BS::PpmSubBlockV1::s_lutBit = 0
staticprivate

Definition at line 126 of file PpmSubBlockV1.h.

◆ s_lutMask

const uint32_t LVL1BS::PpmSubBlockV1::s_lutMask = 0xff
staticprivate

Definition at line 130 of file PpmSubBlockV1.h.

◆ s_maxPins

const int LVL1BS::L1CaloSubBlock::s_maxPins = 20
staticprivateinherited

Definition at line 202 of file L1CaloSubBlock.h.

◆ s_maxStreamedBits

const int LVL1BS::L1CaloSubBlock::s_maxStreamedBits = 31
staticprivateinherited

Definition at line 198 of file L1CaloSubBlock.h.

◆ s_maxStreamedMask

const uint32_t LVL1BS::L1CaloSubBlock::s_maxStreamedMask = 0x7fffffff
staticprivateinherited

Definition at line 200 of file L1CaloSubBlock.h.

◆ s_maxWordBits

const int LVL1BS::L1CaloSubBlock::s_maxWordBits = 32
staticprivateinherited

Definition at line 197 of file L1CaloSubBlock.h.

◆ s_maxWordMask

const uint32_t LVL1BS::L1CaloSubBlock::s_maxWordMask = 0xffffffff
staticprivateinherited

Definition at line 199 of file L1CaloSubBlock.h.

◆ s_mcmAbsentBit

const int LVL1BS::PpmSubBlockV1::s_mcmAbsentBit = 4
staticprivate

Definition at line 149 of file PpmSubBlockV1.h.

◆ s_moduleBit

const int LVL1BS::L1CaloSubBlock::s_moduleBit = 8
staticprivateinherited

Definition at line 175 of file L1CaloSubBlock.h.

◆ s_moduleMask

const uint32_t LVL1BS::L1CaloSubBlock::s_moduleMask = 0xf
staticprivateinherited

Definition at line 183 of file L1CaloSubBlock.h.

◆ s_ppmCrates

const int LVL1BS::L1CaloSubBlock::s_ppmCrates = 8
staticprivateinherited

Definition at line 168 of file L1CaloSubBlock.h.

◆ s_seqnoBit

const int LVL1BS::L1CaloSubBlock::s_seqnoBit = 16
staticprivateinherited

Definition at line 173 of file L1CaloSubBlock.h.

◆ s_seqnoMask

const uint32_t LVL1BS::L1CaloSubBlock::s_seqnoMask = 0x3f
staticprivateinherited

Definition at line 181 of file L1CaloSubBlock.h.

◆ s_slices1Bit

const int LVL1BS::L1CaloSubBlock::s_slices1Bit = 0
staticprivateinherited

Definition at line 177 of file L1CaloSubBlock.h.

◆ s_slices1Mask

const uint32_t LVL1BS::L1CaloSubBlock::s_slices1Mask = 0x7
staticprivateinherited

Definition at line 185 of file L1CaloSubBlock.h.

◆ s_slices2Bit

const int LVL1BS::L1CaloSubBlock::s_slices2Bit = 3
staticprivateinherited

Definition at line 176 of file L1CaloSubBlock.h.

◆ s_slices2Mask

const uint32_t LVL1BS::L1CaloSubBlock::s_slices2Mask = 0x1f
staticprivateinherited

Definition at line 184 of file L1CaloSubBlock.h.

◆ s_statusBit

const int LVL1BS::L1CaloSubBlock::s_statusBit = 28
staticprivateinherited

Definition at line 162 of file L1CaloSubBlock.h.

◆ s_statusMask

const uint32_t LVL1BS::L1CaloSubBlock::s_statusMask = 0x1
staticprivateinherited

Definition at line 164 of file L1CaloSubBlock.h.

◆ s_statusVal

const uint32_t LVL1BS::L1CaloSubBlock::s_statusVal = 0x1
staticprivateinherited

Definition at line 166 of file L1CaloSubBlock.h.

◆ s_timeoutBit

const int LVL1BS::PpmSubBlockV1::s_timeoutBit = 5
staticprivate

Definition at line 148 of file PpmSubBlockV1.h.

◆ s_upstreamErrorBit

const int LVL1BS::L1CaloSubBlock::s_upstreamErrorBit = 4
staticprivateinherited

Definition at line 190 of file L1CaloSubBlock.h.

◆ s_versionBit

const int LVL1BS::L1CaloSubBlock::s_versionBit = 25
staticprivateinherited

Definition at line 171 of file L1CaloSubBlock.h.

◆ s_versionMask

const uint32_t LVL1BS::L1CaloSubBlock::s_versionMask = 0x7
staticprivateinherited

Definition at line 179 of file L1CaloSubBlock.h.

◆ s_wordIdBit

const int LVL1BS::L1CaloSubBlock::s_wordIdBit = 28
staticprivateinherited

Definition at line 170 of file L1CaloSubBlock.h.

◆ s_wordIdMask

const uint32_t LVL1BS::L1CaloSubBlock::s_wordIdMask = 0xf
staticprivateinherited

Definition at line 178 of file L1CaloSubBlock.h.

◆ s_wordIdVal

const uint32_t LVL1BS::PpmSubBlockV1::s_wordIdVal = 0xc
staticprivate

Definition at line 122 of file PpmSubBlockV1.h.

◆ s_wordLen

const int LVL1BS::PpmSubBlockV1::s_wordLen = 16
staticprivate

Definition at line 125 of file PpmSubBlockV1.h.


The documentation for this class was generated from the following files: