Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
run_hcal_server.C
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file run_hcal_server.C
1 #include "ServerFuncs.C"
2 
3 #include <onlmon/hcal/HcalMon.h>
4 
5 #include <onlmon/OnlMonServer.h>
6 
7 // cppcheck-suppress unknownMacro
8 R__LOAD_LIBRARY(libonlhcalmon_server.so)
9 
10 void run_hcal_server(const std::string &name = "HCALMON", unsigned int serverid = 0, const std::string &prdffile = "/bbox/commissioning/HCal/calib/calib_West-00011989-0000.prdf")
11 {
12  char OHCALMON_STR[100];
13  sprintf(OHCALMON_STR, "O%s", name.c_str());
14  char IHCALMON_STR[100];
15  sprintf(IHCALMON_STR, "I%s", name.c_str());
16  OnlMon *m = new HcalMon(OHCALMON_STR); // create subsystem Monitor object
17  m->SetMonitorServerId(serverid);
18 
19  // m->AddTrigger("PPG(Laser)"); // high efficiency triggers selection at et pool
20  // m->AddTrigger("ONLMONBBCLL1"); // generic bbcll1 minbias trigger (defined in ServerFuncs.C)
21  OnlMonServer *se = OnlMonServer::instance(); // get pointer to Server Framework
22  se->registerMonitor(m); // register subsystem Monitor with Framework
23  m = new HcalMon(IHCALMON_STR);
24  m->SetMonitorServerId(serverid);
25  se->registerMonitor(m);
27  return;
28 }