|
ATLAS Offline Software
|
Go to the documentation of this file.
8 #ifndef LARBYTESTREAM_LARRODBLOCKSTRUCTURE_H
9 #define LARBYTESTREAM_LARRODBLOCKSTRUCTURE_H
79 virtual void setPulsed (
const unsigned channelNumber);
82 virtual void setEx(
double);
83 virtual void setEy(
double);
84 virtual void setEz(
double);
90 virtual void sortDataVector( std::vector<const LArAccumulatedCalibDigit*>& );
91 virtual void sortDataVector( std::vector<const LArAccumulatedDigit*>& );
113 virtual inline int32_t
getEx()
const;
114 virtual inline int32_t
getEy()
const;
115 virtual inline int32_t
getEz()
const;
116 virtual inline int32_t
getSumE()
const;
118 virtual inline int32_t
getVROBEx()
const;
119 virtual inline int32_t
getVROBEy()
const;
120 virtual inline int32_t
getVROBEz()
const;
134 virtual inline bool getPulsed(
unsigned channelNumber)
const;
142 virtual int setGain(
const int GainValue);
176 {
return (
ch>>3) + ((
ch&0x7)<<4); };
233 typedef std::map<uint32_t, std::vector<uint32_t> >
FEBMAPTYPE;
261 std::cout <<
"Error while decoding LArByteStream: Got Rod block size 0" << std::endl;
267 std::cout <<
"Error while decoding LArByteStream: Found FEB block of size " << BlockSize <<
" in a ROD block of size " <<
n << std::endl;
286 if (
n<2 ) { std::cout <<
"Error" << std::endl;
return 0;}
290 std::cout <<
"Error AGAIN" << std::endl;
360 return m_FebBlock[
n>>1] & 0xffff;
362 return m_FebBlock[
n>>1] >> 16;
366 {
return m_FebBlock[
n>>1];}
370 return (std::as_const(*m_vFragment).at(
n>>1) & 0xffff);
372 return (std::as_const(*m_vFragment).at(
n>>1) >> 16);
377 return (*m_vFragment)[
n>>1];
382 #ifdef LARBYTESTREAMRODBLOCK_CHCKBOUNDARIES
384 std::cout <<
"Error WRITE BEYOND ARRAY BONDARY!" << std::endl;
396 #ifdef LARBYTESTREAMRODBLOCK_CHCKBOUNDARIES
398 std::cout <<
"Error WRITE BEYOND ARRAY BONDARY!" << std::endl;
407 return (
reinterpret_cast<const uint16_t*
>(m_FebBlock))[
n];
412 const uint32_t* data32 = std::as_const(*m_vFragment).data();
419 #ifdef LARBYTESTREAMRODBLOCK_CHCKBOUNDARIES
421 std::cout <<
"LArRodBlockStructure::LE_setHeader16 Error: WRITE BEYOND ARRAY BONDARY!" << std::endl;
440 return (*(
p+
a)>>
r) & 0x1;
458 std::cout <<
"Error: Function getNextEnergy not implemented in this instance of LArRodBlockStructure!\n";
464 std::cout <<
"Error: Function getPulsed not implemented in this instance of LArRodBlockStructure!\n";
470 std::cout <<
"Error: Function getDAC not implemented in this instance of LArRodBlockStructure!\n";
476 std::cout <<
"Error: Function getDelay not implemented in this instance of LArRodBlockStructure!\n";
482 std::cout <<
"Error: Function getNTrigger not implemented in this instance of LArRodBlockStructure!\n";
488 std::cout <<
"Error: Function getStepIndex not implemented in this instance of LArRodBlockStructure!\n";
493 std::cout <<
"Error: Function getNStep not implemented in this instance of LArRodBlockStructure!\n";
503 if ( LeftSize<=0 )
return false;
508 if (BlockSize>LeftSize) {
509 std::cout <<
"Error while decoding LArByteStream: Found FEB block of size " << BlockSize <<
" in a ROD block of size " << LeftSize << std::endl;
virtual void setNTrigger(const uint16_t NTrigger)
virtual uint16_t getNbSweetCells1() const
virtual uint32_t getNumberOfSamples() const
virtual uint32_t getRadd(uint32_t adc, uint32_t sample) const
Data class for calibration ADC samples preprocessed by the DSP.
std::vector< uint32_t > * m_vFragment
virtual uint32_t hasAccumBlock() const
virtual uint32_t hasPhysicsBlock() const
virtual bool canSetNTrigger()
virtual uint16_t getStepIndex() const
virtual void setEz(double)
virtual int setGain(const int GainValue)
virtual uint16_t getNbSweetCells2() const
virtual int getNextAccumulatedDigit(int &channelNumber, std::vector< uint64_t > &SamplesSum, std::vector< uint64_t > &corr2Sum, uint32_t &gain)
uint32_t getVectorHeader32(const unsigned n) const
uint32_t getNumberOfWords() const
virtual void setNextEnergy(const int channel, const int32_t energy, const int32_t time, const int32_t quality, const uint32_t gain)
std::map< uint32_t, std::vector< uint32_t > > FEBMAPTYPE
uint16_t LE_getVectorHeader16(const unsigned n) const
virtual void setTDCPhase(const uint8_t n)
virtual uint16_t getNTrigger() const
virtual uint16_t getRawDataSize() const
virtual uint16_t getNStep() const
virtual void concatinateFEBs()
virtual void setPulsed(const unsigned channelNumber)
const uint32_t * m_FebBlock
void setHeader16(const unsigned n, const uint16_t w)
virtual int32_t getVROBEx() const
virtual void setEy(double)
virtual uint32_t hasRawDataBlock() const
virtual int getNextEnergy(int &channelNumber, int32_t &energy, int32_t &time, int32_t &quality, uint32_t &gain)
std::vector< uint32_t > * m_pRODblock
virtual uint16_t getCtrl2(uint32_t adc) const
uint32_t OfflineToRawGain(const uint32_t gain) const
virtual bool canSetRawData()
virtual uint32_t offlineCheckSum() const
virtual uint32_t getDspCodeVersion() const
virtual bool setPointers()
virtual int32_t getSumE() const
unsigned short m_iHeadBlockSize
virtual void dumpFragment()
unsigned int m_rearrangeFirstSample
virtual void setDAC(const uint16_t DACValue)
uint32_t getHeader32(const unsigned n) const
virtual void initializeFragment(std::vector< uint32_t > &fragment)
Data class for ADC samples and autocorr preprocessed by the DSP.
uint16_t getVectorHeader16(const unsigned n) const
virtual bool canIncludeRawData()
virtual int32_t getDspEventCounter() const
uint32_t RawToOfflineGain(const uint32_t gain) const
Liquid Argon digit base class.
Liquid Argon ROD output object base class.
virtual int32_t getEx() const
virtual int FebToRodChannel(int ch) const
virtual bool canSetRawDataFixed()
virtual bool canSetCalibration()
uint32_t getFEBSN() const
virtual void finalizeFEB()
virtual void setEtQ(const int channel, const int32_t energy, const int32_t time, const int32_t quality, const uint32_t gain)
virtual void setNumberOfSamples(const uint8_t n)
virtual uint32_t hasControlWords() const
const uint32_t * m_virtualROBPointerLocal
uint32_t getFEBID() const
virtual void resetPointers()
virtual void setSumE(double)
static const uint32_t m_RawToOfflineGainMap[4]
int getBit(const uint32_t *const p, const unsigned chan) const
void LE_setHeader16(const unsigned n, const uint16_t w)
virtual int32_t getEy() const
virtual ~LArRodBlockStructure()
virtual int setFragmentVirtualROB(const uint32_t *p, uint32_t n)
bool report_error(void) const
Base class for LArDigits taken during calibration runs.
const uint32_t * m_virtualROBPointer
virtual void setRawDataFixed(const int channel, const std::vector< short > &samples, const uint32_t gain)
virtual uint16_t getResults2Size() const
virtual bool canSetEnergy()
virtual void sortDataVector(std::vector< const LArRawChannel * > &)
virtual void initializeFEB(const uint32_t id)
uint16_t LE_getHeader16(const unsigned n) const
int32_t m_MiddleHeaderSize
virtual void setEx(double)
virtual int32_t getVROBEz() const
def time(flags, cells_name, *args, **kw)
virtual int getNextRawData(int &channelNumber, std::vector< short > &samples, uint32_t &gain)
virtual uint16_t getCtrl3(uint32_t adc) const
virtual uint32_t getStatus() const
virtual uint16_t getCtrl1(uint32_t adc) const
virtual void setNumberOfGains(const uint8_t n)
virtual int32_t getVROBEy() const
bool setFragment(const uint32_t *p, uint32_t n)
virtual void setDelay(const uint16_t DelayValue)
virtual uint16_t getDelay() const
virtual uint32_t hasCalibBlock() const
void setBit(uint32_t *const p, const unsigned chan)
virtual uint16_t getDAC() const
static const uint32_t m_OfflineToRawGainMap[3]
virtual int getNextAccumulatedCalibDigit(int &channelNumber, std::vector< uint64_t > &SamplesSum, std::vector< uint64_t > &Samples2Sum, uint32_t &nStepTriggers, uint32_t &gain)
virtual uint32_t getNumberOfGains() const
virtual uint32_t onlineCheckSum() const
virtual bool getPulsed(unsigned channelNumber) const
const uint32_t * m_RodBlock
virtual uint8_t getTDCPhase() const
virtual uint32_t getVROBFebId()
virtual uint16_t getResults1Size() const
virtual void setRawData(const int channel, const std::vector< short > &samples, const uint32_t gain)
uint16_t getHeader16(const unsigned n) const
uint32_t m_virtualROBJump
virtual int32_t getEz() const
virtual int32_t getVROBSumE() const
void setFirstSample(const int rearrangeFirstSample)
void setHeader32(const unsigned n, const uint32_t w)