Changeset 5803 for trunk/MagicSoft/Mars/mtrigger
- Timestamp:
- 01/11/05 16:46:58 (20 years ago)
- Location:
- trunk/MagicSoft/Mars/mtrigger
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mtrigger/MTriggerPattern.h
r5725 r5803 27 27 28 28 public: 29 MTriggerPattern(const char *name, const char *title); 29 MTriggerPattern(const char *name=0, const char *title=0); 30 31 void Reset() { fPrescaled=0; fUnprescaled=0; } 30 32 31 33 Byte_t GetPrescaled() const { return fPrescaled; } -
trunk/MagicSoft/Mars/mtrigger/MTriggerPatternDecode.cc
r5725 r5803 17 17 ! 18 18 ! Author(s): Nicola Galante 12/2004 <mailto:nicola.galante@pi.infn.it> 19 ! Author(s): Nicola Galante12/2004 <mailto:tbretz@astro.uni-wuerzburg.de>19 ! Author(s): Thomas Bretz 12/2004 <mailto:tbretz@astro.uni-wuerzburg.de> 20 20 ! 21 21 ! Copyright: MAGIC Software Development, 2004 … … 43 43 #include "MParList.h" 44 44 #include "MRawEvtHeader.h" 45 #include "MRawRunHeader.h" 45 46 #include "MTriggerPattern.h" 46 47 … … 54 55 // 55 56 MTriggerPatternDecode::MTriggerPatternDecode(const char *name, const char *title) 57 : fRunHeader(0), fEvtHeader(0), fPattern(0) 56 58 { 57 59 fName = name ? name : "MTriggerPatternDecode"; … … 63 65 Int_t MTriggerPatternDecode::PreProcess(MParList *pList) 64 66 { 67 fRunHeader = (MRawRunHeader*)pList->FindCreateObj("MRawRunHeader"); 68 if (!fRunHeader) 69 { 70 *fLog << err << "MRawRunHeader not found... abort." << endl; 71 return kFALSE; 72 } 73 65 74 fEvtHeader = (MRawEvtHeader *)pList->FindObject("MRawEvtHeader"); 66 75 if (!fEvtHeader) … … 84 93 Int_t MTriggerPatternDecode::Process() 85 94 { 95 if (fRunHeader->GetFormatVersion()<5) 96 return kTRUE; 97 86 98 UInt_t pattern = ~fEvtHeader->GetTriggerID(); 87 99 -
trunk/MagicSoft/Mars/mtrigger/MTriggerPatternDecode.h
r5725 r5803 2 2 #define MARS_MTriggerPatternDecode 3 3 4 ///////////////////////////////////////////////////////////////////////////// 5 // // 6 // MTriggerPatternDecode 7 // 8 // auth. N.Galante 9 // created 17.11.04 // 10 // // 11 ///////////////////////////////////////////////////////////////////////////// 12 13 #ifndef MARS_MFilter 14 #include "MFilter.h" 4 #ifndef MARS_MTask 5 #include "MTask.h" 15 6 #endif 16 7 17 8 class MParList; 18 9 class MRawEvtHeader; 10 class MRawRunHeader; 19 11 class MTriggerPattern; 20 12 21 class MTriggerPatternDecode : public M Filter13 class MTriggerPatternDecode : public MTask 22 14 { 23 15 private: 24 // enum pattern {PLT1=1, PCAL=2, PLT2=4, PPED=8, PPIND=16, 25 // ULT1=256, UCAL=512, ULT2=1024, UPED=2048, UPIND=4096}; 16 MRawRunHeader *fRunHeader; 17 MRawEvtHeader *fEvtHeader; 18 MTriggerPattern *fPattern; 26 19 27 MRawEvtHeader *fEvtHeader; 28 MTriggerPattern *fPattern; 29 30 // UInt_t fMaskAllowed; // Mask for filtering Trigger Pattern allowed 31 // UInt_t fMaskDenied; // Mask for filtering Trigger Pattern denied 32 // UInt_t fPattern; // Trigger Pattern stored into event 33 // UInt_t fMachArch; 34 35 // Bool_t fBitInv; // Flag to invert bits of Pattern (1=yes,0=no) 36 // default 1=yes 37 //Bool_t fPrescaled; // Flag to set if using prescaled (=1) or 38 // unprescaled (=0) pattern. Default 1 39 // Bool_t fResult; 40 41 Int_t PreProcess(MParList *pList); 42 Int_t Process(); 20 Int_t PreProcess(MParList *pList); 21 Int_t Process(); 43 22 44 23 public: 24 MTriggerPatternDecode(const char *name=0, const char *title=0); 45 25 46 MTriggerPatternDecode(const char *name, const char *title); 47 MTriggerPatternDecode(MTriggerPatternDecode &trigpatt); 48 49 // Bool_t IsExpressionTrue() const; 50 51 // void AllowPresTrigger(TString patt); 52 // void DenyPresTrigger(TString patt); 53 // void AllowUnpresTrigger(TString patt); 54 // void DenyUnpresTrigger(TString patt); 55 // 56 //// UInt_t GetMaskAllowed() const { return fMaskAllowed; }; 57 // UInt_t GetMaskDenied() const { return fMaskDenied; }; 58 //Bool_t GetPrescaled() const { return fPrescaled; }; 59 // Bool_t GetBitInv() const { return fBitInv; } 60 61 // void SetBitInv(const Bool_t inv) { fBitInv = inv; } 62 //void SetPrescaled() { fPrescaled = kTRUE; }; 63 //void SetUnprescaled() { fPrescaled = kFALSE; }; 64 65 // Low level settings. USE THESE ONLY IF YOU ARE AN EXPERT! 66 // void SetMaskAllowed(const UInt_t mask) { fMaskAllowed = mask; } 67 // void SetMaskDenied(const UInt_t mask) { fMaskDenied = mask; } 68 69 ClassDef(MTriggerPatternDecode, 1) // Task to decode the Trigger Pattern 26 ClassDef(MTriggerPatternDecode, 1) // Task to decode the Trigger Pattern 70 27 }; 71 28
Note:
See TracChangeset
for help on using the changeset viewer.