16 const char*
const readout_t =
"readout";
17 const char*
const physical_t =
"physical";
26 int main(
int argc,
char **argv)
38 JParser<> zap(
"Example program to print PMT logical addressing.");
43 zap[
'O'] =
make_field(option,
"sort") = readout_t, physical_t;
48 catch(
const exception &error) {
49 FATAL(error.what() << endl);
55 FATAL(
"No detector address map for detector identifier " << detectorID << endl);
62 if (option == readout_t)
63 sort(memo.begin(), memo.end(), less<JPMTReadoutAddress>());
64 else if (option == physical_t)
65 sort(memo.begin(), memo.end(), less<JPMTPhysicalAddress>());
69 for (JModuleAddressMap::const_iterator i = memo.begin(); i != memo.end(); ++i) {
70 cout << setw(2) << i->tdc <<
' ' << i->ring << i->position << endl;
KM3NeT DAQ constants, bit handling, etc.
General purpose messaging.
int main(int argc, char **argv)
Utility class to parse command line options.
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
Lookup table for PMT addresses in detector.
const JModuleAddressMap & get(const int id) const
Get module address map.
Lookup table for PMT addresses in optical module.
Utility class to parse command line options.
bool hasDetectorAddressMap(const int id)
Check if detector address map is available.
JDetectorAddressMap & getDetectorAddressMap()
Get detector address map.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).