83 std::vector<uint8_t>
GetAsicList(uint16_t equipmentId);
91 size_t GetNumChans(uint16_t equipmentId, uint16_t asicId);
115 void InitComponentMap(
const std::map<uint32_t, std::vector<uint16_t>>& map);
119 const std::map<
size_t, std::map<
size_t, std::map<
size_t, std::tuple<int32_t, bool, uint8_t, uint16_t>>>>&
138 std::map<uint16_t, std::map<uint8_t, std::vector<ChanMapping>>>
fChannelMap = {};
144 "Maps equipment, ASIC and channel to pad address, mask flag and DAQ offset",
#define CBM_YAML_EXTERN_DECL(type)
Declare the external instantiation of the Read and Dump functions for a type.
Provides the hardware-to-software address mapping for the CBM-TRD2D.
int64_t fSystemTimeOffset
ReadoutConfig()
Constructor.
ChanMapping ChanMap(uint16_t equipId, uint16_t asic, uint16_t chan)
API: Mapping from component, asic and channel to tuple (pad address, R pairing flag,...
size_t GetNumAsics(uint16_t equipmentId)
Number of ASICS of a component.
CBM_YAML_PROPERTIES(yaml::Property(&ReadoutConfig::fSystemTimeOffset, "timeOffset", "System time offset for TRD2D"), yaml::Property(&ReadoutConfig::fReadoutMap, "readoutMap", "Maps equipment to module and Optical fibre Id", YAML::Hex), yaml::Property(&ReadoutConfig::fChannelMap, "channelMap", "Maps equipment, ASIC and channel to pad address, mask flag and DAQ offset", YAML::Hex))
void SetSystemTimeOffset(int64_t offsetNs)
Get system time offset.
std::string PrintReadoutMap()
Debug output of readout map.
size_t GetNumChans(uint16_t equipmentId, uint16_t asicId)
Number of channels of a component - ASIC pair.
void InitComponentMap(const std::map< uint32_t, std::vector< uint16_t > > &map)
Initialisation of readout map.
std::vector< uint8_t > GetAsicList(uint16_t equipmentId)
Number of ASICS of a component.
~ReadoutConfig()
Destructor.
std::vector< uint16_t > GetEquipmentIds()
Equipment in the configuration.
void InitChannelMap(const std::map< size_t, std::map< size_t, std::map< size_t, std::tuple< int32_t, bool, uint8_t, uint16_t > > > > &channelMap)
Initialisation of channel map.
std::map< uint16_t, CompMapping > fReadoutMap
int64_t GetSystemTimeOffset()
Get system time offset.
std::map< uint16_t, std::map< uint8_t, std::vector< ChanMapping > > > fChannelMap
CompMapping CompMap(uint16_t equipId)
API: Mapping from component to pair (module id, crob id)
CBM_YAML_PROPERTIES(yaml::Property(&ChanMapping::padAddress, "address", "Pad address"), yaml::Property(&ChanMapping::maskFlag, "mask", "Channel masking flag"), yaml::Property(&ChanMapping::tOffset, "toff", "Channel wise time offset"), yaml::Property(&ChanMapping::lThreshold, "thres", "SW masking by threshold"))
CBM_YAML_FORMAT(YAML::Flow)
SW threshold for ringing channels.
bool maskFlag
map pad and pairing to FASP channel
uint8_t tOffset
HW mask flag for channel.
uint16_t lThreshold
time correction in clk
CBM_YAML_FORMAT(YAML::Flow)
CBM_YAML_PROPERTIES(yaml::Property(&CompMapping::moduleId, "moduleId", "Module ID"), yaml::Property(&CompMapping::fiberId, "fiberId", "Optical Fibre ID"))