@@ -42,7 +42,7 @@ constexpr int DefRDHVersion = o2::raw::RDHUtils::getVersion<o2::header::RAWDataH
4242
4343void setupLinks (o2::itsmft::MC2RawEncoder<MAP>& m2r, std::string_view outDir, std::string_view outPrefix, std::string_view fileFor);
4444void digi2raw (std::string_view inpName, std::string_view outDir, std::string_view fileFor, int verbosity, uint32_t rdhV = DefRDHVersion, bool enablePadding = false ,
45- bool noEmptyHBF = false , int superPageSizeInB = 1024 * 1024 );
45+ bool noEmptyHBF = false , bool noEmptyROF = false , int superPageSizeInB = 1024 * 1024 );
4646
4747int main (int argc, char ** argv)
4848{
@@ -63,6 +63,7 @@ int main(int argc, char** argv)
6363 add_option (" rdh-version,r" , bpo::value<uint32_t >()->default_value (DefRDHVersion), " RDH version to use" );
6464 add_option (" enable-padding" , bpo::value<bool >()->default_value (false )->implicit_value (true ), " enable GBT word padding to 128 bits even for RDH V7" );
6565 add_option (" no-empty-hbf,e" , bpo::value<bool >()->default_value (false )->implicit_value (true ), " do not create empty HBF pages (except for HBF starting TF)" );
66+ add_option (" no-empty-rof" , bpo::value<bool >()->default_value (false )->implicit_value (true ), " do not create empty ROF blocks" );
6667 add_option (" hbfutils-config,u" , bpo::value<std::string>()->default_value (std::string (o2::base::NameConf::DIGITIZATIONCONFIGFILE)), " config file for HBFUtils (or none)" );
6768 add_option (" configKeyValues" , bpo::value<std::string>()->default_value (" " ), " comma-separated configKeyValues" );
6869
@@ -96,15 +97,16 @@ int main(int argc, char** argv)
9697 vm[" verbosity" ].as <uint32_t >(),
9798 vm[" rdh-version" ].as <uint32_t >(),
9899 vm[" enable-padding" ].as <bool >(),
99- vm[" no-empty-hbf" ].as <bool >());
100+ vm[" no-empty-hbf" ].as <bool >(),
101+ vm[" no-empty-rof" ].as <bool >());
100102 LOG (info) << " HBFUtils settings used for conversion:" ;
101103
102104 o2::raw::HBFUtils::Instance ().print ();
103105
104106 return 0 ;
105107}
106108
107- void digi2raw (std::string_view inpName, std::string_view outDir, std::string_view fileFor, int verbosity, uint32_t rdhV, bool enablePadding, bool noEmptyHBF, int superPageSizeInB)
109+ void digi2raw (std::string_view inpName, std::string_view outDir, std::string_view fileFor, int verbosity, uint32_t rdhV, bool enablePadding, bool noEmptyHBF, bool noEmptyROF, int superPageSizeInB)
108110{
109111 TStopwatch swTot;
110112 swTot.Start ();
@@ -178,9 +180,9 @@ void digi2raw(std::string_view inpName, std::string_view outDir, std::string_vie
178180 LOG (info) << " Processing ROF:" << rofRec.getROFrame () << " with " << nDigROF << " entries" ;
179181 rofRec.print ();
180182 }
181- if (!nDigROF) {
183+ if (!nDigROF && noEmptyROF ) {
182184 if (verbosity) {
183- LOG (info) << " Frame is empty" ; // ??
185+ LOG (info) << " Frame is empty" ;
184186 }
185187 continue ;
186188 }
0 commit comments