DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
dunedaq::trgdataformats Namespace Reference

Namespaces

namespace  python

Classes

struct  TriggerActivityData
struct  TriggerCandidateData
struct  TriggerObjectOverlay
struct  TriggerPrimitive
 A single energy deposition on a TPC or PDS channel. More...

Typedefs

using TriggerActivity = TriggerObjectOverlay<TriggerActivityData, TriggerPrimitive>
using TriggerCandidate = TriggerObjectOverlay<TriggerCandidateData, TriggerActivityData>
using timestamp_t = uint64_t
using timestamp_diff_t = int64_t
using detid_t = uint8_t
using trigger_number_t = uint64_t
using channel_t = uint32_t
using channel_diff_t = int32_t
using version_t = uint8_t

Functions

std::map< TriggerCandidateData::Type, std::string > get_trigger_candidate_type_names ()
int string_to_trigger_candidate_type (const std::string &name)
std::string trigger_candidate_type_to_string (const TriggerCandidateData::Type &type)

Variables

constexpr timestamp_t INVALID_TIMESTAMP = std::numeric_limits<timestamp_t>::max()
constexpr uint16_t INVALID_SAMPLES_OVER_THRESHOLD = std::numeric_limits<uint16_t>::max()
constexpr uint16_t INVALID_SAMPLES_TO_PEAK = std::numeric_limits<uint16_t>::max()
constexpr detid_t INVALID_DETID = std::numeric_limits<detid_t>::max()
constexpr detid_t WHOLE_DETECTOR = INVALID_DETID - 1
constexpr trigger_number_t INVALID_TRIGGER_NUMBER = std::numeric_limits<trigger_number_t>::max()
constexpr channel_t INVALID_CHANNEL = std::numeric_limits<channel_t>::max()
constexpr uint32_t INVALID_TP_CHANNEL = 0xFFFFFF
constexpr version_t INVALID_VERSION = std::numeric_limits<version_t>::max()

Typedef Documentation

◆ channel_diff_t

Definition at line 59 of file Types.hpp.

◆ channel_t

Definition at line 52 of file Types.hpp.

◆ detid_t

Definition at line 36 of file Types.hpp.

◆ timestamp_diff_t

Definition at line 24 of file Types.hpp.

◆ timestamp_t

Definition at line 20 of file Types.hpp.

◆ trigger_number_t

Definition at line 47 of file Types.hpp.

◆ TriggerActivity

◆ TriggerCandidate

◆ version_t

Definition at line 62 of file Types.hpp.

Function Documentation

◆ get_trigger_candidate_type_names()

std::map< TriggerCandidateData::Type, std::string > dunedaq::trgdataformats::get_trigger_candidate_type_names ( )
inline

Definition at line 102 of file TriggerCandidateData.hpp.

103{
104 return {
111 { TriggerCandidateData::Type::kADCSimpleWindow, "kADCSimpleWindow" },
112 { TriggerCandidateData::Type::kHorizontalMuon, "kHorizontalMuon" },
113 { TriggerCandidateData::Type::kMichelElectron, "kMichelElectron" },
114 { TriggerCandidateData::Type::kPlaneCoincidence, "kPlaneCoincidence" },
116 { TriggerCandidateData::Type::kChannelDistance, "kChannelDistance" },
118 { TriggerCandidateData::Type::kCTBFakeTrigger, "kCTBFakeTrigger" },
120 { TriggerCandidateData::Type::kCTBBeamChkvHL, "kCTBBeamChkvHL" },
125 { TriggerCandidateData::Type::kCTBBeamChkvHLx, "kCTBBeamChkvHLx" },
126 { TriggerCandidateData::Type::kCTBBeamChkvHxL, "kCTBBeamChkvHxL" },
127 { TriggerCandidateData::Type::kCTBBeamChkvHxLx, "kCTBBeamChkvHxLx" },
128 { TriggerCandidateData::Type::kNeutronSourceCalib, "kNeutronSourceCalib" },
129 { TriggerCandidateData::Type::kChannelAdjacency, "kChannelAdjacency" },
130 { TriggerCandidateData::Type::kCIBFakeTrigger, "kCIBFakeTrigger" },
131 { TriggerCandidateData::Type::kCIBLaserTriggerP1, "kCIBLaserTriggerP1" },
132 { TriggerCandidateData::Type::kCIBLaserTriggerP2, "kCIBLaserTriggerP2" },
133 { TriggerCandidateData::Type::kCIBLaserTriggerP3, "kCIBLaserTriggerP3" },
134 { TriggerCandidateData::Type::kCTBOffSpillSnapshot, "kCTBOffSpillSnapshot" },
135 { TriggerCandidateData::Type::kCTBOffSpillCosmicJura, "kCTBOffSpillCosmicJura" },
136 { TriggerCandidateData::Type::kCTBOffSpillCRTCosmic, "kCTBOffSpillCRTCosmic" },
137 { TriggerCandidateData::Type::kCTBBeamSpillStart, "kCTBBeamSpillStart" },
138 { TriggerCandidateData::Type::kCTBBeamSpillSnapshot, "kCTBBeamSpillSnapshot" },
140 { TriggerCandidateData::Type::kCTBCustomPulseTrain, "kCTBCustomPulseTrain" },
143 { TriggerCandidateData::Type::kSSPLEDCalibration, "kSSPLEDCalibration" },
144 { TriggerCandidateData::Type::kProtoDUNEBSMWindow, "kProtoDUNEBSMWindow" }
145 };
146}

◆ string_to_trigger_candidate_type()

int dunedaq::trgdataformats::string_to_trigger_candidate_type ( const std::string & name)
inline

Definition at line 149 of file TriggerCandidateData.hpp.

150{
151 for (auto& it : get_trigger_candidate_type_names()) {
152 if (it.second == name)
153 return static_cast<int>(it.first);
154 }
155 return static_cast<int>(TriggerCandidateData::Type::kUnknown);
156}
std::map< TriggerCandidateData::Type, std::string > get_trigger_candidate_type_names()

◆ trigger_candidate_type_to_string()

std::string dunedaq::trgdataformats::trigger_candidate_type_to_string ( const TriggerCandidateData::Type & type)
inline

Definition at line 159 of file TriggerCandidateData.hpp.

160{
161 try {
163 }
164 catch(std::exception &e) {
165 }
166 return "kUnknown";
167}

Variable Documentation

◆ INVALID_CHANNEL

channel_t dunedaq::trgdataformats::INVALID_CHANNEL = std::numeric_limits<channel_t>::max()
constexpr

Definition at line 54 of file Types.hpp.

◆ INVALID_DETID

detid_t dunedaq::trgdataformats::INVALID_DETID = std::numeric_limits<detid_t>::max()
constexpr

Definition at line 38 of file Types.hpp.

◆ INVALID_SAMPLES_OVER_THRESHOLD

uint16_t dunedaq::trgdataformats::INVALID_SAMPLES_OVER_THRESHOLD = std::numeric_limits<uint16_t>::max()
constexpr

Definition at line 26 of file Types.hpp.

◆ INVALID_SAMPLES_TO_PEAK

uint16_t dunedaq::trgdataformats::INVALID_SAMPLES_TO_PEAK = std::numeric_limits<uint16_t>::max()
constexpr

Definition at line 28 of file Types.hpp.

◆ INVALID_TIMESTAMP

timestamp_t dunedaq::trgdataformats::INVALID_TIMESTAMP = std::numeric_limits<timestamp_t>::max()
constexpr

Definition at line 22 of file Types.hpp.

◆ INVALID_TP_CHANNEL

uint32_t dunedaq::trgdataformats::INVALID_TP_CHANNEL = 0xFFFFFF
constexpr

Definition at line 57 of file Types.hpp.

◆ INVALID_TRIGGER_NUMBER

trigger_number_t dunedaq::trgdataformats::INVALID_TRIGGER_NUMBER = std::numeric_limits<trigger_number_t>::max()
constexpr

Definition at line 49 of file Types.hpp.

◆ INVALID_VERSION

version_t dunedaq::trgdataformats::INVALID_VERSION = std::numeric_limits<version_t>::max()
constexpr

Definition at line 64 of file Types.hpp.

◆ WHOLE_DETECTOR

detid_t dunedaq::trgdataformats::WHOLE_DETECTOR = INVALID_DETID - 1
constexpr

Definition at line 41 of file Types.hpp.