CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes | Friends
TotemVFATStatus Class Reference

#include <TotemVFATStatus.h>

Public Member Functions

uint8_t chipPosition () const
 Chip position. More...
 
uint8_t ec () const
 event Counter More...
 
bool isBCProgressError () const
 BC number is incorrect. More...
 
bool isCRCError () const
 CRC error. More...
 
bool isECProgressError () const
 VFATFrame event number doesn't follow the number derived from DAQ. More...
 
bool isFootprintError () const
 Footprint error. More...
 
bool isFullyMaskedOut () const
 All channels from that VFAT are not taken into account. More...
 
bool isIDMismatch () const
 12-bit hw id from the header of the vfat frame is diffrent from the 16-bit one from hw mapping More...
 
bool isMissing () const
 VFAT is present in mapping but no data is present int raw event. More...
 
bool isNotMasked () const
 No channels are masked out. More...
 
bool isNumberOfClustersSpecified () const
 number of clusters More...
 
bool isOK () const
 
bool isPartiallyMaskedOut () const
 Some channels from VFAT ale masked out, but not all. More...
 
uint8_t numberOfClusters () const
 
bool operator< (const TotemVFATStatus &cmp) const
 
void setBCProgressError (bool val=true)
 
void setChipPosition (uint8_t cp)
 
void setCRCError (bool val=true)
 
void setEC (const uint8_t ec)
 
void setECProgressError (bool val=true)
 
void setFootprintError (bool val=true)
 
void setFullyMaskedOut ()
 
void setIDMismatch (bool val=true)
 
void setMissing (bool val=true)
 
void setNotMasked ()
 
void setNumberOfClusters (uint8_t v)
 
void setNumberOfClustersSpecified (bool v)
 
void setPartiallyMaskedOut ()
 
 TotemVFATStatus (uint8_t cp=0)
 

Private Attributes

uint8_t chipPosition_
 describes placement of the VFAT within the detector More...
 
uint8_t eventCounter
 event counter in the VFAT frame More...
 
uint8_t numberOfClusters_
 
bool numberOfClustersSpecified
 the number of hit clusters before DAQ trimming More...
 
std::bitset< 8 > status
 the status bits More...
 

Friends

std::ostream & operator<< (std::ostream &s, const TotemVFATStatus &st)
 

Detailed Description

Class which contains information about conversion from RAW to DIGI for a single read-out chip (VFAT).

Definition at line 21 of file TotemVFATStatus.h.

Constructor & Destructor Documentation

◆ TotemVFATStatus()

TotemVFATStatus::TotemVFATStatus ( uint8_t  cp = 0)
inline

Definition at line 23 of file TotemVFATStatus.h.

uint8_t numberOfClusters_
bool numberOfClustersSpecified
the number of hit clusters before DAQ trimming
uint8_t chipPosition_
describes placement of the VFAT within the detector
std::bitset< 8 > status
the status bits
uint8_t eventCounter
event counter in the VFAT frame

Member Function Documentation

◆ chipPosition()

uint8_t TotemVFATStatus::chipPosition ( ) const
inline

Chip position.

Definition at line 27 of file TotemVFATStatus.h.

References chipPosition_.

27 { return chipPosition_; }
uint8_t chipPosition_
describes placement of the VFAT within the detector

◆ ec()

uint8_t TotemVFATStatus::ec ( ) const
inline

event Counter

Definition at line 80 of file TotemVFATStatus.h.

References eventCounter.

Referenced by setEC().

80 { return eventCounter; }
uint8_t eventCounter
event counter in the VFAT frame

◆ isBCProgressError()

bool TotemVFATStatus::isBCProgressError ( ) const
inline

BC number is incorrect.

Definition at line 51 of file TotemVFATStatus.h.

References status.

51 { return status[5]; }
std::bitset< 8 > status
the status bits

◆ isCRCError()

bool TotemVFATStatus::isCRCError ( ) const
inline

CRC error.

Definition at line 43 of file TotemVFATStatus.h.

References status.

43 { return status[3]; }
std::bitset< 8 > status
the status bits

◆ isECProgressError()

bool TotemVFATStatus::isECProgressError ( ) const
inline

VFATFrame event number doesn't follow the number derived from DAQ.

Definition at line 47 of file TotemVFATStatus.h.

References status.

47 { return status[4]; }
std::bitset< 8 > status
the status bits

◆ isFootprintError()

bool TotemVFATStatus::isFootprintError ( ) const
inline

Footprint error.

Definition at line 39 of file TotemVFATStatus.h.

References status.

39 { return status[2]; }
std::bitset< 8 > status
the status bits

◆ isFullyMaskedOut()

bool TotemVFATStatus::isFullyMaskedOut ( ) const
inline

All channels from that VFAT are not taken into account.

Definition at line 55 of file TotemVFATStatus.h.

References status.

55 { return status[6]; }
std::bitset< 8 > status
the status bits

◆ isIDMismatch()

bool TotemVFATStatus::isIDMismatch ( ) const
inline

12-bit hw id from the header of the vfat frame is diffrent from the 16-bit one from hw mapping

Definition at line 35 of file TotemVFATStatus.h.

References status.

35 { return status[1]; }
std::bitset< 8 > status
the status bits

◆ isMissing()

bool TotemVFATStatus::isMissing ( ) const
inline

VFAT is present in mapping but no data is present int raw event.

Definition at line 31 of file TotemVFATStatus.h.

References status.

31 { return status[0]; }
std::bitset< 8 > status
the status bits

◆ isNotMasked()

bool TotemVFATStatus::isNotMasked ( ) const
inline

No channels are masked out.

Definition at line 63 of file TotemVFATStatus.h.

References status.

63 { return !(status[6] || status[7]); }
std::bitset< 8 > status
the status bits

◆ isNumberOfClustersSpecified()

bool TotemVFATStatus::isNumberOfClustersSpecified ( ) const
inline

number of clusters

Definition at line 69 of file TotemVFATStatus.h.

References numberOfClustersSpecified.

69 { return numberOfClustersSpecified; }
bool numberOfClustersSpecified
the number of hit clusters before DAQ trimming

◆ isOK()

bool TotemVFATStatus::isOK ( ) const
inline

Definition at line 66 of file TotemVFATStatus.h.

References status.

66 { return !(status[0] || status[1] || status[2] || status[3] || status[4] || status[5]); }
std::bitset< 8 > status
the status bits

◆ isPartiallyMaskedOut()

bool TotemVFATStatus::isPartiallyMaskedOut ( ) const
inline

Some channels from VFAT ale masked out, but not all.

Definition at line 59 of file TotemVFATStatus.h.

References status.

59 { return status[7]; }
std::bitset< 8 > status
the status bits

◆ numberOfClusters()

uint8_t TotemVFATStatus::numberOfClusters ( ) const
inline

Definition at line 72 of file TotemVFATStatus.h.

References numberOfClusters_.

72 { return numberOfClusters_; }
uint8_t numberOfClusters_

◆ operator<()

bool TotemVFATStatus::operator< ( const TotemVFATStatus cmp) const
inline

Definition at line 75 of file TotemVFATStatus.h.

References fileCollector::cmp, and status.

75 { return (status.to_ulong() < cmp.status.to_ulong()); }
std::bitset< 8 > status
the status bits

◆ setBCProgressError()

void TotemVFATStatus::setBCProgressError ( bool  val = true)
inline

Definition at line 52 of file TotemVFATStatus.h.

References status, and heppy_batch::val.

52 { status[5] = val; }
std::bitset< 8 > status
the status bits

◆ setChipPosition()

void TotemVFATStatus::setChipPosition ( uint8_t  cp)
inline

Definition at line 28 of file TotemVFATStatus.h.

References chipPosition_, and CommonMethods::cp().

28 { chipPosition_ = cp; }
uint8_t chipPosition_
describes placement of the VFAT within the detector
def cp(fromDir, toDir, listOfFiles, overwrite=False, smallList=False)

◆ setCRCError()

void TotemVFATStatus::setCRCError ( bool  val = true)
inline

Definition at line 44 of file TotemVFATStatus.h.

References status, and heppy_batch::val.

44 { status[3] = val; }
std::bitset< 8 > status
the status bits

◆ setEC()

void TotemVFATStatus::setEC ( const uint8_t  ec)
inline

Definition at line 81 of file TotemVFATStatus.h.

References ec(), and eventCounter.

81 { eventCounter = ec; }
uint8_t ec() const
event Counter
uint8_t eventCounter
event counter in the VFAT frame

◆ setECProgressError()

void TotemVFATStatus::setECProgressError ( bool  val = true)
inline

Definition at line 48 of file TotemVFATStatus.h.

References status, and heppy_batch::val.

48 { status[4] = val; }
std::bitset< 8 > status
the status bits

◆ setFootprintError()

void TotemVFATStatus::setFootprintError ( bool  val = true)
inline

Definition at line 40 of file TotemVFATStatus.h.

References status, and heppy_batch::val.

40 { status[2] = val; }
std::bitset< 8 > status
the status bits

◆ setFullyMaskedOut()

void TotemVFATStatus::setFullyMaskedOut ( )
inline

Definition at line 56 of file TotemVFATStatus.h.

References status.

56 { status[6] = true; }
std::bitset< 8 > status
the status bits

◆ setIDMismatch()

void TotemVFATStatus::setIDMismatch ( bool  val = true)
inline

Definition at line 36 of file TotemVFATStatus.h.

References status, and heppy_batch::val.

36 { status[1] = val; }
std::bitset< 8 > status
the status bits

◆ setMissing()

void TotemVFATStatus::setMissing ( bool  val = true)
inline

Definition at line 32 of file TotemVFATStatus.h.

References status, and heppy_batch::val.

Referenced by RawToDigiConverter::runCommon().

32 { status[0] = val; }
std::bitset< 8 > status
the status bits

◆ setNotMasked()

void TotemVFATStatus::setNotMasked ( )
inline

Definition at line 64 of file TotemVFATStatus.h.

References status.

64 { status[6] = status[7] = false; }
std::bitset< 8 > status
the status bits

◆ setNumberOfClusters()

void TotemVFATStatus::setNumberOfClusters ( uint8_t  v)
inline

Definition at line 73 of file TotemVFATStatus.h.

References numberOfClusters_, and findQualityFiles::v.

◆ setNumberOfClustersSpecified()

void TotemVFATStatus::setNumberOfClustersSpecified ( bool  v)
inline

Definition at line 70 of file TotemVFATStatus.h.

References numberOfClustersSpecified, and findQualityFiles::v.

bool numberOfClustersSpecified
the number of hit clusters before DAQ trimming

◆ setPartiallyMaskedOut()

void TotemVFATStatus::setPartiallyMaskedOut ( )
inline

Definition at line 60 of file TotemVFATStatus.h.

References status.

60 { status[7] = true; }
std::bitset< 8 > status
the status bits

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  s,
const TotemVFATStatus st 
)
friend

Definition at line 14 of file TotemVFATStatus.cc.

14  {
15  return s << "miss=" << st.status[0] << ",ID=" << st.status[1] << ",foot=" << st.status[2] << ",CRC=" << st.status[3]
16  << ",EC=" << st.status[4] << ",BC=" << st.status[5] << ",fm=" << st.status[6] << ",pm=" << st.status[7];
17 }
std::bitset< 8 > status
the status bits

Member Data Documentation

◆ chipPosition_

uint8_t TotemVFATStatus::chipPosition_
private

describes placement of the VFAT within the detector

Definition at line 85 of file TotemVFATStatus.h.

Referenced by chipPosition(), and setChipPosition().

◆ eventCounter

uint8_t TotemVFATStatus::eventCounter
private

event counter in the VFAT frame

Definition at line 95 of file TotemVFATStatus.h.

Referenced by ec(), and setEC().

◆ numberOfClusters_

uint8_t TotemVFATStatus::numberOfClusters_
private

Definition at line 92 of file TotemVFATStatus.h.

Referenced by numberOfClusters(), and setNumberOfClusters().

◆ numberOfClustersSpecified

bool TotemVFATStatus::numberOfClustersSpecified
private

the number of hit clusters before DAQ trimming

Definition at line 91 of file TotemVFATStatus.h.

Referenced by isNumberOfClustersSpecified(), and setNumberOfClustersSpecified().

◆ status

std::bitset<8> TotemVFATStatus::status
private