#include <SiStripFEDBufferComponents.h>
Public Member Functions | |
uint16_t | cmMedian (const uint8_t apvIndex) const |
const uint8_t * | data () const |
FEDChannel (const uint8_t *const data, const size_t offset, const uint16_t length) | |
FEDChannel (const uint8_t *const data, const size_t offset) | |
uint16_t | length () const |
size_t | offset () const |
Private Member Functions | |
uint8_t | packetCode () const |
Private Attributes | |
const uint8_t * | data_ |
uint16_t | length_ |
size_t | offset_ |
Friends | |
class | FEDBuffer |
Definition at line 515 of file SiStripFEDBufferComponents.h.
sistrip::FEDChannel::FEDChannel | ( | const uint8_t *const | data, |
const size_t | offset, | ||
const uint16_t | length | ||
) | [inline] |
sistrip::FEDChannel::FEDChannel | ( | const uint8_t *const | data, |
const size_t | offset | ||
) | [inline] |
uint16_t sistrip::FEDChannel::cmMedian | ( | const uint8_t | apvIndex | ) | const |
Definition at line 1385 of file SiStripFEDBufferComponents.cc.
References data_, Exception, offset_, sistrip::PACKET_CODE_ZERO_SUPPRESSED, packetCode(), and query::result.
Referenced by SiStripCMMonitorPlugin::analyze().
{ if (packetCode() != PACKET_CODE_ZERO_SUPPRESSED) { std::ostringstream ss; ss << "Request for CM median from channel with non-ZS packet code. " << "Packet code is " << uint16_t(packetCode()) << "." << std::endl; throw cms::Exception("FEDBuffer") << ss.str(); } if (apvIndex > 1) { std::ostringstream ss; ss << "Channel APV index out of range when requesting CM median for APV. " << "Channel APV index is " << uint16_t(apvIndex) << "." << std::endl; throw cms::Exception("FEDBuffer") << ss.str(); } uint16_t result = 0; //CM median is 10 bits with lowest order byte first. First APV CM median starts in 4th byte of channel data result |= data_[(offset_+3+2*apvIndex)^7]; result |= ( ((data_[(offset_+4+2*apvIndex)^7]) << 8) & 0x300 ); return result; }
const uint8_t * sistrip::FEDChannel::data | ( | ) | const [inline] |
Definition at line 1571 of file SiStripFEDBufferComponents.h.
References data_.
Referenced by sistrip::FEDZSChannelUnpacker::zeroSuppressedLiteModeUnpacker(), and sistrip::FEDZSChannelUnpacker::zeroSuppressedModeUnpacker().
{ return data_; }
uint16_t sistrip::FEDChannel::length | ( | ) | const [inline] |
Definition at line 1561 of file SiStripFEDBufferComponents.h.
References length_.
Referenced by SiStripCMMonitorPlugin::analyze(), sistrip::FEDBuffer::checkChannelLengthsMatchBufferLength(), sistrip::FEDRawChannelUnpacker::FEDRawChannelUnpacker(), sistrip::FEDZSChannelUnpacker::zeroSuppressedLiteModeUnpacker(), and sistrip::FEDZSChannelUnpacker::zeroSuppressedModeUnpacker().
{ return length_; }
size_t sistrip::FEDChannel::offset | ( | ) | const [inline] |
Definition at line 1576 of file SiStripFEDBufferComponents.h.
References offset_.
Referenced by sistrip::FEDBuffer::checkChannelLengthsMatchBufferLength(), sistrip::FEDZSChannelUnpacker::zeroSuppressedLiteModeUnpacker(), and sistrip::FEDZSChannelUnpacker::zeroSuppressedModeUnpacker().
{ return offset_; }
uint8_t sistrip::FEDChannel::packetCode | ( | ) | const [inline, private] |
Definition at line 1566 of file SiStripFEDBufferComponents.h.
References data_, and offset_.
Referenced by cmMedian().
friend class FEDBuffer [friend] |
Definition at line 526 of file SiStripFEDBufferComponents.h.
const uint8_t* sistrip::FEDChannel::data_ [private] |
Definition at line 529 of file SiStripFEDBufferComponents.h.
Referenced by cmMedian(), data(), FEDChannel(), and packetCode().
uint16_t sistrip::FEDChannel::length_ [private] |
Definition at line 531 of file SiStripFEDBufferComponents.h.
Referenced by FEDChannel(), and length().
size_t sistrip::FEDChannel::offset_ [private] |
Definition at line 530 of file SiStripFEDBufferComponents.h.
Referenced by cmMedian(), FEDChannel(), offset(), and packetCode().