@@ -81,24 +81,24 @@ void ReadRaw::readRawData(const LookUpTable& lut)
8181 for (int i = 0 ; i < eventHeader.nGBTWords ; ++i) {
8282 mRawFileIn .read (reinterpret_cast <char *>(&eventData[2 * i]), o2::fdd::EventData::PayloadSizeFirstWord);
8383 posPayload += o2::fdd::EventData::PayloadSizeFirstWord;
84- chData = {Short_t (lut.getChannel (link, int (eventData[2 * i].channelID ))),
85- Float_t (eventData[2 * i].time ),
86- Short_t (eventData[2 * i].charge ), 0 };
84+ chData = {static_cast < uint8_t > (lut.getChannel (link, int (eventData[2 * i].channelID ))),
85+ int (eventData[2 * i].time ),
86+ int (eventData[2 * i].charge ), 0 };
8787 mDigitAccum [intrec].emplace_back (chData);
8888 LOG (DEBUG) << " Read 1st half-word: (PMchannel, globalChannel, Q, T, posPayload) = "
8989 << std::setw (3 ) << int (eventData[2 * i].channelID )
9090 << std::setw (4 ) << lut.getChannel (link, int (eventData[2 * i].channelID ))
9191 << std::setw (5 ) << int (eventData[2 * i].charge )
92- << std::setw (5 ) << float (eventData[2 * i].time )
92+ << std::setw (5 ) << int (eventData[2 * i].time )
9393 << std::setw (5 ) << posPayload;
9494
9595 Short_t channelIdFirstHalfWord = chData.mPMNumber ;
9696
9797 mRawFileIn .read (reinterpret_cast <char *>(&eventData[2 * i + 1 ]), EventData::PayloadSizeSecondWord);
9898 posPayload += o2::fdd::EventData::PayloadSizeSecondWord;
99- chData = {Short_t (lut.getChannel (link, (eventData[2 * i + 1 ].channelID ))),
100- Float_t (eventData[2 * i + 1 ].time ),
101- Short_t (eventData[2 * i + 1 ].charge ), 0 };
99+ chData = {static_cast < uint8_t > (lut.getChannel (link, int (eventData[2 * i + 1 ].channelID ))),
100+ int (eventData[2 * i + 1 ].time ),
101+ int (eventData[2 * i + 1 ].charge ), 0 };
102102 if (chData.mPMNumber <= channelIdFirstHalfWord) {
103103 // Don't save the second half-word if it is only filled with zeroes (empty-data)
104104 // TODO: Verify if it works correctly with real data from readout
@@ -109,7 +109,7 @@ void ReadRaw::readRawData(const LookUpTable& lut)
109109 << std::setw (3 ) << int (eventData[2 * i + 1 ].channelID )
110110 << std::setw (4 ) << lut.getChannel (link, int (eventData[2 * i + 1 ].channelID ))
111111 << std::setw (5 ) << int (eventData[2 * i + 1 ].charge )
112- << std::setw (5 ) << float (eventData[2 * i + 1 ].time )
112+ << std::setw (5 ) << int (eventData[2 * i + 1 ].time )
113113 << std::setw (5 ) << posPayload;
114114 }
115115 }
@@ -152,7 +152,7 @@ void ReadRaw::writeDigits(const std::string& outputDigitsFilePath)
152152 size_t nStored = 0 ;
153153 size_t first = chDataVecTree.size ();
154154 for (auto & sec : digit.second ) {
155- chDataVecTree.emplace_back (int ( sec.mPMNumber ), float ( sec.mTime ), short ( sec.mChargeADC ), short ( 0 ) );
155+ chDataVecTree.emplace_back (sec.mPMNumber , sec.mTime , sec.mChargeADC , sec. mFEEBits );
156156 nStored++;
157157 }
158158 chBcVecTree.emplace_back (first, nStored, digit.first , Triggers ());
0 commit comments