66 template <
typename DigiType>
93 <<
"Unknown sub-system string " <<
subSystemName <<
"." << endl;
137 LogDebug(
"TotemVFATRawToDigi").log([
this](
auto &
log) {
138 log <<
"List of FEDs handled by this instance: ";
155 run<DetSetVector<TotemRPDigi>>(
event, es);
158 run<DetSetVector<CTPPSDiamondDigi>>(
event, es);
161 run<DetSetVector<TotemTimingDigi>>(
event, es);
164 run<edmNew::DetSetVector<TotemT2Digi>>(
event, es);
167 template <
typename DigiType>
180 vector<TotemFEDInfo> fedInfo;
196 event.put(make_unique<vector<TotemFEDInfo>>(fedInfo),
subSystemName);
208 desc.add<std::vector<unsigned int>>(
"fedIds", {})
210 "IMPORTANT: leave empty to load the default configuration from " 211 "DataFormats/FEDRawData/interface/FEDNumbering.h");
221 "0-3: 1=one line/event with some corrupted VFAT frame, 2=list all corrupt VFAT frames/event, 3=all " 222 "problems with every corrupt frame");
223 psd0.
add<
unsigned int>(
"testFootprint", 2)->setComment(
"0=no test, 1=warn only, 2=warn and skip");
224 psd0.
add<
unsigned int>(
"testCRC", 2);
225 psd0.
add<
unsigned int>(
"testID", 2)->setComment(
"compare the ID from data and mapping");
226 psd0.
add<
unsigned int>(
"testECMostFrequent", 2)
227 ->setComment(
"compare frame EC with the most frequent value in the event");
228 psd0.
add<
unsigned int>(
"testBCMostFrequent", 2);
230 ->setComment(
"minimal number of frames to search for the most frequent counter value");
234 "the most frequent counter value is accepted provided its relative occupancy is higher than this fraction");
236 psd0.
add<
bool>(
"useOlderT2TestFile",
false)
237 ->setComment(
"treat hwID field as two separate 8-bit fields instead of one 16-bit");
238 psd0.
addUntracked<
bool>(
"printErrorSummary",
false)->setComment(
"per-VFAT error summary at the end of the job");
239 psd0.
addUntracked<
bool>(
"printUnknownFrameSummary",
false)
240 ->setComment(
"summary of frames found in data, but not in the mapping");
243 descriptions.
add(
"totemVFATRawToDigi",
desc);
void setComment(std::string const &value)
T getParameter(std::string const &) const
edm::ESGetToken< TotemAnalysisMask, TotemReadoutRcd > analysisMaskToken
ParameterDescriptionBase * addUntracked(U const &iLabel, T const &value)
pps::RawDataUnpacker rawDataUnpacker
edm::ESGetToken< TotemDAQMapping, TotemReadoutRcd > totemMappingToken
void run(edm::Event &, const edm::EventSetup &)
~TotemVFATRawToDigi() override
std::vector< unsigned int > fedIds
TotemVFATRawToDigi(const edm::ParameterSet &)
#define DEFINE_FWK_MODULE(type)
ParameterDescriptionBase * add(U const &iLabel, T const &value)
enum TotemVFATRawToDigi::@505 subSystem
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
int run(int fedId, const FEDRawData &data, std::vector< TotemFEDInfo > &fedInfoColl, SimpleVFATFrameCollection &coll) const
Unpack data from FED with fedId into ‘coll’ collection.
Collection of code to convert TOTEM raw data into digi.
edm::EDGetTokenT< FEDRawDataCollection > fedDataToken
void add(std::string const &label, ParameterSetDescription const &psetDescription)
Collection of code for unpacking of TOTEM raw-data.
ParameterSet const & getParameterSet(ParameterSetID const &id)
char data[epos_bytes_allocation]
void printSummaries() const
Print error summaries.
RawToDigiConverter rawToDigiConverter
static void fillDescriptions(edm::ConfigurationDescriptions &)
void produce(edm::Event &, const edm::EventSetup &) override
std::string subSystemName
void run(const VFATFrameCollection &coll, const TotemDAQMapping &mapping, const TotemAnalysisMask &mask, edm::DetSetVector< TotemRPDigi > &digi, edm::DetSetVector< TotemVFATStatus > &status)
Creates RP digi.
void endStream() override