CbmRoot
Loading...
Searching...
No Matches
MQ/mcbm/runUnpack.cxx
Go to the documentation of this file.
1/* Copyright (C) 2021 Facility for Antiproton and Ion Research in Europe, Darmstadt
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Pierre-Alain Loizeau [committer] */
4
5#include "CbmDeviceUnpack.h"
6
7#include <iomanip>
8#include <string>
9
10#include "runFairMQDevice.h"
11
12namespace bpo = boost::program_options;
13using namespace std;
14
15void addCustomOptions(bpo::options_description& options)
16{
17 options.add_options()("Setup", bpo::value<std::string>()->default_value("mcbm_beam_2021_07_surveyed"),
18 "Name/tag of the geomatry setup");
19 options.add_options()("RunId", bpo::value<uint32_t>()->default_value(1588), "Run ID");
20 options.add_options()("UnpBmon", bpo::value<bool>()->default_value(false), "Enable Bmon unpacking if true");
21 options.add_options()("UnpSts", bpo::value<bool>()->default_value(true), "Enable STS unpacking if true");
22 options.add_options()("UnpMuch", bpo::value<bool>()->default_value(false), "Enable MUCH unpacking if true");
23 options.add_options()("UnpTrd1d", bpo::value<bool>()->default_value(true), "Enable TRD 1D unpacking if true");
24 options.add_options()("UnpTrd2d", bpo::value<bool>()->default_value(true), "Enable TRD 2D unpacking if true");
25 options.add_options()("UnpTof", bpo::value<bool>()->default_value(true), "Enable TOF unpacking if true");
26 options.add_options()("UnpRich", bpo::value<bool>()->default_value(true), "Enable RICH unpacking if true");
27 options.add_options()("UnpPsd", bpo::value<bool>()->default_value(true), "Enable PSD unpacking if true");
28 options.add_options()("IgnOverMs", bpo::value<bool>()->default_value(true), "Ignore overlap MS if true");
29 options.add_options()("FullTimeSort", bpo::value<bool>()->default_value(true),
30 "Full time sorting per detector before sending output array");
31 options.add_options()("SetTimeOffs", bpo::value<std::vector<std::string>>()->multitoken()->composing(),
32 "Set time offset in ns for selected detector, use string matching "
33 "ECbmModuleId,dOffs e.g. kTof,-35.2");
34 options.add_options()("TsNameIn", bpo::value<std::string>()->default_value("ts-request"),
35 "MQ channel name for raw TS data");
36 options.add_options()("TsNameOut", bpo::value<std::string>()->default_value("unpts_0"),
37 "MQ channel name for unpacked TS data");
38
39 options.add_options()("PubFreqTs", bpo::value<uint32_t>()->default_value(0), "Histo publishing frequency in TS");
40 options.add_options()("PubTimeMin", bpo::value<double_t>()->default_value(1.0),
41 "Minimal time between two publishing");
42 options.add_options()("PubTimeMax", bpo::value<double_t>()->default_value(10.0),
43 "Maximal time between two publishing");
44 options.add_options()("ChNameIn", bpo::value<std::string>()->default_value("histogram-in"),
45 "MQ channel name for histos");
46}
47
48FairMQDevicePtr getDevice(const FairMQProgOptions& /*config*/) { return new CbmDeviceUnpack(); }
FairMQDevicePtr getDevice(const FairMQProgOptions &)
void addCustomOptions(bpo::options_description &options)
Hash for CbmL1LinkKey.