|
ATLAS Offline Software
|
Go to the documentation of this file.
5 #ifndef TRIGT1CALOBYTESTREAM_ZDCL1CALOSUBBLOCK_H
6 #define TRIGT1CALOBYTESTREAM_ZDCL1CALOSUBBLOCK_H
std::vector< uint32_t >::const_iterator m_dataPosEnd
void unpackerInit()
Initialise unpacker.
static const int s_moduleBit
static const uint32_t s_wordIdMask
static const int s_ppmCrates
uint32_t subStatus() const
Return Sub-status word.
static const uint32_t s_slices1Mask
void packerNeutralParity(int pin)
Pack current G-Link parity bit for given pin.
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.
static const uint32_t s_failingBcnMask
void packer(uint32_t datum, int nbits)
Pack given data into given number of bits.
static const int s_failingBcnBit
static const uint32_t s_headerMask
static const int s_wordIdBit
static SubBlockWordType wordType(uint32_t word)
Word identification.
void setUnpackErrorCode(int code)
Set the unpacking error code.
bool unpackerNeutralParityError(int pin)
Unpack and test G-Link parity bit for given pin.
void setStatus(uint32_t failingBCN, bool glinkTimeout, bool glinkDown, bool upstreamError, bool daqOverflow, bool bcnMismatch, bool glinkProtocol, bool glinkParity)
Output complete packed sub-block to ROD vector.
int m_unpackError
Unpacking error code.
static const int s_maxStreamedBits
static const int s_headerBit
int minBits(uint32_t datum) const
Return the minimum number of bits needed for given data.
static const uint32_t s_versionMask
int bunchCrossing() const
Return the Bunch Crossing number (neutral format only)
uint32_t unpacker(int nbits, int align)
std::vector< int > m_currentPinBit
uint32_t failingBCN() const
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_slices2Mask
void setStreamed()
Set continuous bit streaming for compressed formats.
int dataWords() const
Return number of data words.
static const int s_glinkTimeoutBit
int parityBit(int init, uint32_t datum, int nbits) const
Return the parity bit for given data.
bool unpackerSuccess() const
Return unpacker success flag.
static const uint32_t s_maxWordMask
bool glinkProtocol() const
bool glinkTimeout() const
void clear()
Clear all data.
static const int s_maxPins
const DataType * PointerType
static const uint32_t s_moduleMask
std::vector< uint32_t > m_unpackingMasks
Unpacking masks.
static const int s_statusBit
std::vector< uint32_t > m_data
Sub-Block data.
static const int s_glinkProtocolBit
void packerFlush()
Flush the current data word padded with zeros.
int currentPinBit(int pin) const
Return current pin bit for given pin.
bool upstreamError() const
static const uint32_t s_crateMask
static const uint32_t s_statusVal
static const int s_formatBit
@ UNPACK_COMPRESSION_SLICES
void setBunchCrossing(int bc)
Set the Bunch Crossing number (neutral format only)
static const int s_maxWordBits
int m_dataWords
Current number of data words.
std::vector< uint32_t >::const_iterator m_dataPos
static const int s_slices1Bit
static const int s_glinkDownBit
static const int s_seqnoBit
static const int s_glinkParityBit
@ UNPACK_COMPRESSION_VERSION
static int seqno(uint32_t word)
Return seqno field from given header word.
L1Calo Sub-Block base class.
int unpackErrorCode() const
Return the unpacking error code.
uint32_t m_header
Sub-Block Header.
def init(v_theApp, v_rootStream=None)
static int format(uint32_t word)
Return data format from given header word.
std::vector< int > m_oddParity
uint32_t unpackerNeutral(int pin, int nbits)
Unpack given number of bits of neutral data for given pin.
static const uint32_t s_seqnoMask
static const int s_upstreamErrorBit
static const int s_daqOverflowBit
static const int s_crateBit
static const int s_versionBit
static const int s_bcnMismatchBit
int m_bunchCrossing
Bunch Crossing number (neutral format only)
static int module(uint32_t word)
Return module field from given header word.
std::string unpackErrorMsg() const
Return the unpacking error message for printing.
static const uint32_t s_statusMask
uint32_t unpacker(int nbits)
Unpack given number of bits of data.
static const uint32_t s_maxStreamedMask
void setDaqOverflow(int bit=1)
Set DAQ FIFO Overflow bit in Sub-status word.
static int version(uint32_t word)
Return version number from given header word.
void packerNeutral(int pin, uint32_t datum, int nbits)
Pack given neutral data from given pin.
static const uint32_t s_formatMask
static const int s_slices2Bit
static const uint32_t s_headerVal
void setGlinkParity(int bit=1)
Set G-Link Parity bit in Sub-status word.
static const uint32_t s_glinkDavSet
uint32_t m_trailer
Sub-Block Status Trailer.
static int wordId(uint32_t word)
Return wordID field from given header word.