Changeset 436 for trunk/MagicSoft/include-Classes
- Timestamp:
- 09/22/00 18:40:18 (24 years ago)
- Location:
- trunk/MagicSoft/include-Classes
- Files:
-
- 2 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/include-Classes/LinkDef.h
r374 r436 10 10 #pragma link C++ class MMcEvt; 11 11 #pragma link C++ class MMcTrig; 12 #pragma link C++ class MHeaderTrig; 12 13 13 14 #pragma link C++ class MPedData; -
trunk/MagicSoft/include-Classes/MMcTrig.cxx
r394 r436 23 23 Int_t i; 24 24 25 topology = -1 ; 26 multiplicity = -1 ; 27 for(i=0;i<TRIGGER_PIXELS;i++){ 28 threshold[i] = -1.0; 25 nFirstLevel = 0 ; 26 27 for(i=0;i<TOTAL_TRIGGER_TIME/LEVEL1_DEAD_TIME+1;i++){ 28 timeFirst[i] = -99.9; 29 pixelFirst[i] = -9; 29 30 } 30 31 31 nFirstLevel = 0 ;32 timeFirst = -99.9;33 pixelFirst = -9;34 35 32 nSecondLevel = 0 ; 36 33 for(i=0;i<TOTAL_TRIGGER_TIME/LEVEL2_DEAD_TIME+1;i++){ 34 FirstToSecond[i]=0; 35 } 37 36 } 38 37 … … 50 49 51 50 nFirstLevel = 0 ; 52 timeFirst = -99.9; 53 pixelFirst = -9; 51 for(i=0;i<TOTAL_TRIGGER_TIME/LEVEL1_DEAD_TIME+1;i++){ 52 timeFirst[i] = -99.9; 53 pixelFirst[i] = -9; 54 } 54 55 55 nSecondLevel = 0 ; 56 nSecondLevel = 0 ; 57 for(i=0;i<TOTAL_TRIGGER_TIME/LEVEL2_DEAD_TIME+1;i++){ 58 FirstToSecond[i]=0; 59 } 56 60 57 61 // cout << "MMcTrig::Clear() " << endl ; … … 65 69 66 70 cout <<endl << "Monte Carlo Trigger output:" <<endl; 67 cout << " Topology Trigger in this event : "<<topology<<endl;68 cout << " Multiplicity Trigger in this event : "<<multiplicity<<endl;69 71 cout << " First Level Trigger in this Event : "<<nFirstLevel<<endl; 70 cout << " Time of first Level Trigger in this Event : "<< timeFirst<<endl; 71 cout << " Pixels of first Level Trigger in this Event : "<<pixelFirst<<endl; 72 cout << " Times of first Level Trigger in this Event : "; 73 for (i=0;i<nFirstLevel;i++){ 74 cout<< timeFirst[i]<<"-"; 75 } 76 cout<<endl; 77 cout << " Pixels of first Level Trigger in this Event : "; 78 for (i=0;i<nFirstLevel;i++){ 79 cout<<pixelFirst[i]<<"-"; 80 } 81 cout<<endl; 72 82 cout << " Second Level Trigger in this Event : " << nSecondLevel << endl ; 73 83 cout << endl ; -
trunk/MagicSoft/include-Classes/MMcTrig.hxx
r420 r436 15 15 class MMcTrig : public TObject { 16 16 private: 17 Short_t topology ; // Topology of the trigger 18 // 0 = N-1 neighbours of one pixel 19 // 1 = N neighbours 20 // 2 = N closed pack 21 Short_t multiplicity ; // Pixel multiplicity of trigger configuration 22 Float_t threshold[TRIGGER_PIXELS] ; // Threshold for trigger 23 24 Short_t nZeroLevel ; 17 25 18 Short_t nFirstLevel ; // Number of First Level Trigger in this Event 26 19 Short_t nSecondLevel ; // Number of Second Level Trigger in this Event 27 20 28 Float_t timeFirst; // Time when it triggers 29 Int_t pixelFirst; // Pixel which triggers 21 Float_t timeFirst[((Int_t)(TOTAL_TRIGGER_TIME/LEVEL1_DEAD_TIME))+1]; 22 // Time when it triggers 23 Int_t pixelFirst[((Int_t)(TOTAL_TRIGGER_TIME/LEVEL1_DEAD_TIME))+1]; 24 // Pixel which triggers 25 Short_t FirstToSecond[((Int_t)(TOTAL_TRIGGER_TIME/LEVEL2_DEAD_TIME))+1]; 30 26 31 27 public: … … 38 34 void Print(Option_t *); 39 35 40 void SetTopology(Short_t nTop) {41 topology=nTop;42 }43 44 void SetMultiplicity(Short_t nMul) {45 multiplicity=nMul;46 }47 48 void SetThreshold(Float_t fthr[]){49 int i;50 for(i=0;i<TRIGGER_PIXELS;i++){51 threshold[i]=fthr[i];52 }53 }54 55 void SetZeroLevel (Short_t nTr) {56 nZeroLevel = nTr ;57 }58 59 36 void SetFirstLevel ( Short_t nTr ) { 60 37 nFirstLevel = nTr ; … … 64 41 } 65 42 66 void SetTime( Float_t t){ 67 timeFirst=t; 43 void SetTime( Float_t t, Int_t i){ 44 if (i>TOTAL_TRIGGER_TIME/LEVEL1_DEAD_TIME+1 || i<1){ 45 cout<<"nFirstLevel out of range. Time will be -99"<<endl; 46 } 47 else{ 48 timeFirst[i-1]=t; 49 } 68 50 } 69 51 70 void SetPixel( Int_t iPix){ 71 pixelFirst=iPix; 52 void SetPixel( Int_t iPix, Int_t i){ 53 if (i>TOTAL_TRIGGER_TIME/LEVEL1_DEAD_TIME+1 || i<1){ 54 cout<<"nFirstLevel out of range. Pixel will be -1"<<endl; 55 } 56 else{ 57 pixelFirst[i-1]=iPix; 58 } 72 59 } 73 60 74 int GetFirstLevel() {61 Int_t GetFirstLevel() { 75 62 return ( nFirstLevel ); 76 63 } … … 81 68 82 69 #endif 83
Note:
See TracChangeset
for help on using the changeset viewer.