 |
Belle II Software
release-05-02-19
|
13 #include <top/dbobjects/TOPChannelMap.h>
14 #include <framework/gearbox/GearDir.h>
15 #include <framework/database/DBArray.h>
16 #include <framework/database/IntervalOfValidity.h>
109 unsigned pix = pixel - 1;
156 unsigned& boardstack,
159 unsigned& chan)
const;
A class that describes the interval of experiments/runs for which an object in the database is valid.
const TOPChannelMap * m_channels[c_numRows][c_numColumns]
conversion array
Provides mapping between electronic channels and pixels.
int getPixelID(unsigned channel) const
Converts hardware channel number to pixel ID (1-based)
@ c_numPixelRows
per module
@ c_numChannels
number of channels per ASIC
EType
Enum for electornic types.
ChannelMapper & operator=(const ChannelMapper &)
Assignment operator.
std::string m_typeName
electronic type name
Class for accessing arrays of objects in the database.
@ c_numRows
number of pixel rows per carrier board
bool isValid() const
Checks if mapping is available.
@ c_numColumns
number of pixel columns per carrier board
void splitChannelNumber(unsigned channel, unsigned &boardstack, unsigned &carrier, unsigned &asic, unsigned &chan) const
Splits hardware channel number into boardstack, carrier, asic and asic channel.
bool m_fromDB
true, if from database
void initialize()
Initialize from database.
bool isPixelIDValid(int pixel) const
Checks validity of pixel ID.
void test() const
test that the conversion and inverse of it gives identity, if not B2ERROR
@ c_numPixelColumns
per module
@ c_invalidPixelID
value of invalid pixel ID
unsigned getChannel(int pixel) const
Converts pixel to hardware channel number (0-based)
bool isChannelValid(unsigned channel) const
Checks validity of hardware channel number.
@ c_numBoardstacks
number of boardstacks per TOP module
std::string getName() const
Return electornic name.
Abstract base class for different kinds of events.
GearDir is the basic class used for accessing the parameter store.
@ c_invalidChannel
value of invalid channel number
Map of pixels and channels within the carrier board.
bool m_valid
true if mapping available
DBArray< TOPChannelMap > * m_mappingDB
mappings from database
EType m_type
electornic type
@ c_numCarrierBoards
number of carrier boards per boardstack
~ChannelMapper()
destructor
const TOPChannelMap * m_pixels[c_numAsics][c_numChannels]
conversion array
EType getType() const
Return electornic type (see enum)
std::vector< TOPChannelMap > m_mapping
mappings from gearbox
void print() const
Print mappings to terminal screen.
int getPmtID(int pixel) const
Returns PMT ID (1-based)
void update()
re-do conversion arrays when DBArray has changed
@ c_numAsics
number of ASIC's per carrier board
ChannelMapper()
constructor