Skip to content
Snippets Groups Projects
Commit 32618436 authored by echio's avatar echio
Browse files

Protect Correct Call to CATS1TS if not in the config

parent 2210b064
No related branches found
No related tags found
No related merge requests found
...@@ -73,7 +73,6 @@ IdLISE::IdLISE(const Char_t *Name, ...@@ -73,7 +73,6 @@ IdLISE::IdLISE(const Char_t *Name,
DetD4 = DM->GetDetector("D4_LISE"); DetD4 = DM->GetDetector("D4_LISE");
ICD6 = DM->GetDetector("CHIO_LISE"); ICD6 = DM->GetDetector("CHIO_LISE");
TAC_LISE = DM->GetDetector("TAC_LISE"); TAC_LISE = DM->GetDetector("TAC_LISE");
CATS1TS = DM->GetDetector("DATATRIG_CATS1");
// GetRefeence TS for TS Plots // GetRefeence TS for TS Plots
RefTS = 0; RefTS = 0;
...@@ -96,6 +95,17 @@ IdLISE::IdLISE(const Char_t *Name, ...@@ -96,6 +95,17 @@ IdLISE::IdLISE(const Char_t *Name,
} }
// Try to Get ZDD Detector when available
try{
CATS1TS = DM->GetDetector("DATATRIG_CATS1");
}
catch(MErr *Er)
{
Er->Print();
CATS1TS = NULL;
delete Er;
}
// Try to Get ZDD Detector when available // Try to Get ZDD Detector when available
try{ try{
PL_ZDD = DM->GetDetector("Plastic"); PL_ZDD = DM->GetDetector("Plastic");
...@@ -354,7 +364,9 @@ Bool_t IdLISE::Treat(void) ...@@ -354,7 +364,9 @@ Bool_t IdLISE::Treat(void)
// cout << " ----- " << endl; // cout << " ----- " << endl;
SetCalData(13,DetCaviar->GetCal(3)); SetCalData(13,DetCaviar->GetCal(3));
CATSTime = CATS1TS->GetRawTS(0); if(CATS1TS)
CATSTime = CATS1TS->GetRawTS(0);
if(CATSTime>0) if(CATSTime>0)
{ {
// cout << "CATS : " << CATSTime << " - " << RefTS << " " << (CATSTime-RefTS)*1e-8 << " sec "<< endl; // cout << "CATS : " << CATSTime << " - " << RefTS << " " << (CATSTime-RefTS)*1e-8 << " sec "<< endl;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment