#include <SiStripFEDBufferGenerator.h>
Public Member Functions | |
FEDDAQHeader & | daqHeader () |
FEDDAQTrailer & | daqTrailer () |
FEDBufferGenerator (const uint32_t l1ID=0, const uint16_t bxID=0, const std::vector< bool > &feUnitsEnabled=std::vector< bool >(FEUNITS_PER_FED, true), const std::vector< bool > &channelsEnabled=std::vector< bool >(FEDCH_PER_FED, true), const FEDReadoutMode readoutMode=READOUT_MODE_ZERO_SUPPRESSED, const FEDHeaderType headerType=HEADER_TYPE_FULL_DEBUG, const FEDBufferFormat bufferFormat=BUFFER_FORMAT_OLD_SLINK, const FEDDAQEventType evtType=DAQ_EVENT_TYPE_PHYSICS) | |
FEDFEHeader & | feHeader () |
void | generateBuffer (FEDRawData *rawDataObject, const FEDStripData &data, uint16_t sourceID, uint8_t packetCode) const |
FEDBufferFormat | getBufferFormat () const |
uint16_t | getBXID () const |
bool | getChannelEnabled (const uint8_t internalFEDChannelNumber) const |
FEDDAQEventType | getDAQEventType () const |
bool | getFEUnitEnabled (const uint8_t internalFEUnitNumber) const |
FEDHeaderType | getHeaderType () const |
uint32_t | getL1ID () const |
FEDReadoutMode | getReadoutMode () const |
FEDBufferGenerator & | setBufferFormat (const FEDBufferFormat newBufferFormat) |
FEDBufferGenerator & | setBXID (const uint16_t newBXID) |
FEDBufferGenerator & | setChannelEnable (const uint8_t internalFEDChannelNumber, const bool enabled) |
FEDBufferGenerator & | setChannelEnables (const std::vector< bool > &channelsEnabled) |
FEDBufferGenerator & | setDAQEventType (const FEDDAQEventType newDAQEventType) |
FEDBufferGenerator & | setFEUnitEnable (const uint8_t internalFEUnitNumber, const bool enabled) |
FEDBufferGenerator & | setFEUnitEnables (const std::vector< bool > &feUnitsEnabled) |
FEDBufferGenerator & | setHeaderType (const FEDHeaderType newHeaderType) |
FEDBufferGenerator & | setL1ID (const uint32_t newL1ID) |
FEDBufferGenerator & | setReadoutMode (const FEDReadoutMode newReadoutMode) |
TrackerSpecialHeader & | trackerSpecialHeader () |
Static Private Member Functions | |
static size_t | bufferSizeInBytes (const FEDFEHeader &feHeader, const FEDBufferPayload &payload) |
static void | fillBuffer (uint8_t *pointerToStartOfBuffer, const FEDDAQHeader &daqHeader, const FEDDAQTrailer &daqTrailer, const TrackerSpecialHeader &tkSpecialHeader, const FEDFEHeader &feHeader, const FEDBufferPayload &payload) |
Private Attributes | |
std::vector< bool > | channelsEnabled_ |
FEDDAQHeader | defaultDAQHeader_ |
FEDDAQTrailer | defaultDAQTrailer_ |
std::unique_ptr< FEDFEHeader > | defaultFEHeader_ |
TrackerSpecialHeader | defaultTrackerSpecialHeader_ |
std::vector< bool > | feUnitsEnabled_ |
Definition at line 126 of file SiStripFEDBufferGenerator.h.
sistrip::FEDBufferGenerator::FEDBufferGenerator | ( | const uint32_t | l1ID = 0 , |
const uint16_t | bxID = 0 , |
||
const std::vector< bool > & | feUnitsEnabled = std::vector<bool>(FEUNITS_PER_FED, true) , |
||
const std::vector< bool > & | channelsEnabled = std::vector<bool>(FEDCH_PER_FED, true) , |
||
const FEDReadoutMode | readoutMode = READOUT_MODE_ZERO_SUPPRESSED , |
||
const FEDHeaderType | headerType = HEADER_TYPE_FULL_DEBUG , |
||
const FEDBufferFormat | bufferFormat = BUFFER_FORMAT_OLD_SLINK , |
||
const FEDDAQEventType | evtType = DAQ_EVENT_TYPE_PHYSICS |
||
) |
Definition at line 438 of file SiStripFEDBufferGenerator.cc.
References defaultFEHeader_, Exception, and contentValuesCheck::ss.
|
inlinestaticprivate |
Definition at line 356 of file SiStripFEDBufferGenerator.h.
References sistrip::FEDBufferPayload::lengthInBytes(), and sistrip::FEDFEHeader::lengthInBytes().
Referenced by fillBuffer(), and generateBuffer().
|
inline |
Definition at line 348 of file SiStripFEDBufferGenerator.h.
References defaultDAQHeader_.
Referenced by sistrip::DigiToRaw::createFedBuffers_(), and generateBuffer().
|
inline |
Definition at line 350 of file SiStripFEDBufferGenerator.h.
References defaultDAQTrailer_.
Referenced by sistrip::DigiToRaw::createFedBuffers_().
|
inline |
Definition at line 354 of file SiStripFEDBufferGenerator.h.
References defaultFEHeader_.
Referenced by sistrip::DigiToRaw::createFedBuffers_().
|
staticprivate |
Definition at line 563 of file SiStripFEDBufferGenerator.cc.
References bufferSizeInBytes(), sistrip::calculateFEDBufferCRC(), sistrip::FEDBufferPayload::data(), sistrip::FEDDAQHeader::data(), sistrip::FEDDAQTrailer::data(), sistrip::TrackerSpecialHeader::data(), sistrip::FEDFEHeader::data(), mps_fire::i, sistrip::FEDBufferPayload::lengthInBytes(), sistrip::FEDFEHeader::lengthInBytes(), sistrip::FEDDAQTrailer::setCRC(), sistrip::FEDDAQTrailer::setEventLengthIn64BitWords(), and sistrip::TrackerSpecialHeader::wasSwapped().
Referenced by generateBuffer().
void sistrip::FEDBufferGenerator::generateBuffer | ( | FEDRawData * | rawDataObject, |
const FEDStripData & | data, | ||
uint16_t | sourceID, | ||
uint8_t | packetCode | ||
) | const |
Definition at line 526 of file SiStripFEDBufferGenerator.cc.
References bufferSizeInBytes(), channelsEnabled_, daqHeader(), FEDRawData::data(), defaultDAQHeader_, defaultDAQTrailer_, defaultFEHeader_, defaultTrackerSpecialHeader_, gedGsfElectrons_cfi::enabled, sistrip::FEDCH_PER_FED, sistrip::FEDCH_PER_FEUNIT, sistrip::FEUNITS_PER_FED, feUnitsEnabled_, fillBuffer(), sistrip::FEDBufferPayload::getFELength(), getReadoutMode(), jetCorrFactors_cfi::payload, FEDRawData::resize(), sistrip::TrackerSpecialHeader::setFEEnableForFEUnit(), and sistrip::FEDDAQHeader::setSourceID().
Referenced by sistrip::DigiToRaw::createFedBuffers_().
|
inline |
Definition at line 312 of file SiStripFEDBufferGenerator.h.
References sistrip::TrackerSpecialHeader::bufferFormat(), and defaultTrackerSpecialHeader_.
Referenced by sistrip::DigiToRaw::createFedBuffers_().
|
inline |
Definition at line 304 of file SiStripFEDBufferGenerator.h.
References sistrip::FEDDAQHeader::bxID(), and defaultDAQHeader_.
bool sistrip::FEDBufferGenerator::getChannelEnabled | ( | const uint8_t | internalFEDChannelNumber | ) | const |
Definition at line 469 of file SiStripFEDBufferGenerator.cc.
References channelsEnabled_, Exception, and contentValuesCheck::ss.
|
inline |
Definition at line 316 of file SiStripFEDBufferGenerator.h.
References defaultDAQHeader_, and sistrip::FEDDAQHeader::eventType().
Referenced by sistrip::DigiToRaw::createFedBuffers_().
bool sistrip::FEDBufferGenerator::getFEUnitEnabled | ( | const uint8_t | internalFEUnitNumber | ) | const |
Definition at line 459 of file SiStripFEDBufferGenerator.cc.
References Exception, feUnitsEnabled_, and contentValuesCheck::ss.
|
inline |
Definition at line 310 of file SiStripFEDBufferGenerator.h.
References defaultTrackerSpecialHeader_, and sistrip::TrackerSpecialHeader::headerType().
|
inline |
Definition at line 302 of file SiStripFEDBufferGenerator.h.
References defaultDAQHeader_, and sistrip::FEDDAQHeader::l1ID().
|
inline |
Definition at line 306 of file SiStripFEDBufferGenerator.h.
References defaultTrackerSpecialHeader_, and sistrip::TrackerSpecialHeader::readoutMode().
Referenced by generateBuffer().
|
inline |
Definition at line 338 of file SiStripFEDBufferGenerator.h.
References defaultTrackerSpecialHeader_, and sistrip::TrackerSpecialHeader::setBufferFormat().
|
inline |
Definition at line 323 of file SiStripFEDBufferGenerator.h.
References defaultDAQHeader_, and sistrip::FEDDAQHeader::setBXID().
FEDBufferGenerator & sistrip::FEDBufferGenerator::setChannelEnable | ( | const uint8_t | internalFEDChannelNumber, |
const bool | enabled | ||
) |
Definition at line 492 of file SiStripFEDBufferGenerator.cc.
References channelsEnabled_, gedGsfElectrons_cfi::enabled, Exception, and contentValuesCheck::ss.
FEDBufferGenerator & sistrip::FEDBufferGenerator::setChannelEnables | ( | const std::vector< bool > & | channelsEnabled | ) |
Definition at line 515 of file SiStripFEDBufferGenerator.cc.
References channelsEnabled_, Exception, sistrip::FEDCH_PER_FED, and contentValuesCheck::ss.
|
inline |
Definition at line 343 of file SiStripFEDBufferGenerator.h.
References defaultDAQHeader_, and sistrip::FEDDAQHeader::setEventType().
FEDBufferGenerator & sistrip::FEDBufferGenerator::setFEUnitEnable | ( | const uint8_t | internalFEUnitNumber, |
const bool | enabled | ||
) |
Definition at line 480 of file SiStripFEDBufferGenerator.cc.
References gedGsfElectrons_cfi::enabled, Exception, feUnitsEnabled_, and contentValuesCheck::ss.
FEDBufferGenerator & sistrip::FEDBufferGenerator::setFEUnitEnables | ( | const std::vector< bool > & | feUnitsEnabled | ) |
Definition at line 504 of file SiStripFEDBufferGenerator.cc.
References Exception, sistrip::FEUNITS_PER_FED, feUnitsEnabled_, and contentValuesCheck::ss.
Referenced by sistrip::DigiToRaw::createFedBuffers_().
|
inline |
Definition at line 333 of file SiStripFEDBufferGenerator.h.
References defaultTrackerSpecialHeader_, and sistrip::TrackerSpecialHeader::setHeaderType().
Referenced by sistrip::DigiToRaw::createFedBuffers_().
|
inline |
Definition at line 318 of file SiStripFEDBufferGenerator.h.
References defaultDAQHeader_, and sistrip::FEDDAQHeader::setL1ID().
Referenced by sistrip::DigiToRaw::createFedBuffers_().
|
inline |
Definition at line 328 of file SiStripFEDBufferGenerator.h.
References defaultTrackerSpecialHeader_, and sistrip::TrackerSpecialHeader::setReadoutMode().
Referenced by sistrip::DigiToRaw::createFedBuffers_(), and sistrip::DigiToRaw::DigiToRaw().
|
inline |
Definition at line 352 of file SiStripFEDBufferGenerator.h.
References defaultTrackerSpecialHeader_.
Referenced by sistrip::DigiToRaw::createFedBuffers_().
|
private |
Definition at line 189 of file SiStripFEDBufferGenerator.h.
Referenced by generateBuffer(), getChannelEnabled(), setChannelEnable(), and setChannelEnables().
|
private |
Definition at line 184 of file SiStripFEDBufferGenerator.h.
Referenced by daqHeader(), generateBuffer(), getBXID(), getDAQEventType(), getL1ID(), setBXID(), setDAQEventType(), and setL1ID().
|
private |
Definition at line 185 of file SiStripFEDBufferGenerator.h.
Referenced by daqTrailer(), and generateBuffer().
|
private |
Definition at line 187 of file SiStripFEDBufferGenerator.h.
Referenced by FEDBufferGenerator(), feHeader(), and generateBuffer().
|
private |
Definition at line 186 of file SiStripFEDBufferGenerator.h.
Referenced by generateBuffer(), getBufferFormat(), getHeaderType(), getReadoutMode(), setBufferFormat(), setHeaderType(), setReadoutMode(), and trackerSpecialHeader().
|
private |
Definition at line 188 of file SiStripFEDBufferGenerator.h.
Referenced by generateBuffer(), getFEUnitEnabled(), setFEUnitEnable(), and setFEUnitEnables().