13 #include "Timeslice.hpp"
14 #include "TimesliceInputArchive.hpp"
15 #include "TimesliceSubscriber.hpp"
17 #include "FairLogger.h"
25 , fInputFileList(new TObjString())
35 while (
auto timeslice =
fSource->get()) {
36 const fles::Timeslice& ts = *timeslice;
37 auto tsIndex = ts.index();
39 if (0 == tsIndex % 1000) {
40 LOG(info) <<
"Reading Timeslice " << tsIndex;
43 UInt_t fuNbCoreMsPerTs = ts.num_core_microslices();
44 UInt_t fuNbComponents = ts.num_components();
46 for (UInt_t uMsIdx = 0; uMsIdx < fuNbCoreMsPerTs; uMsIdx++) {
48 for (UInt_t uMsCompIdx = 0; uMsCompIdx < fuNbComponents; ++uMsCompIdx) {
49 bool bCrcOk = ts.get_microslice(uMsCompIdx, uMsIdx).check_crc();
52 auto msDescriptor = ts.descriptor(uMsCompIdx, uMsIdx);
53 uint32_t uSize = msDescriptor.size;
54 const uint8_t* msContent =
55 reinterpret_cast<const uint8_t*
>(ts.content(uMsCompIdx, uMsIdx));
56 LOG(info) <<
"-----------------------------------------------------"
60 << Form(
" MS %3u Component %2u, dump following",
63 LOG(info) <<
"-----------------------------------------------------"
76 for (UInt_t uByte = 0; uByte < uSize; ++uByte) {
77 ss << Form(
"%02x", msContent[uByte]);
78 if (3 == uByte % 4) ss <<
" ";
79 if (15 == uByte % 16) ss <<
"\n";
81 if (0 == uSize % 16) ss <<
"\n";
82 LOG(info) << ss.str();
89 LOG(info) <<
"Analysed " <<
fTSCounter <<
" TS ";
110 LOG(info) <<
"Open the Flib input file " <<
fFileName;
112 FILE* inputFile = fopen(
fFileName.Data(),
"r");
114 LOG(error) <<
"Input file " <<
fFileName <<
" doesn't exist.";
120 LOG(error) <<
"Could not open input file.";
125 LOG(info) <<
"End of files list reached: file counter is " <<
fFileCounter
127 <<
" entries in the file list.";