Difference between revisions of "Hall A analyzer"
(→FAQ) |
|||
(3 intermediate revisions by the same user not shown) | |||
Line 6: | Line 6: | ||
//_____________________________________________________________________________ | //_____________________________________________________________________________ | ||
+ | |||
void THaDecData::TrigBits(UInt_t ibit, BdataLoc *dataloc) { | void THaDecData::TrigBits(UInt_t ibit, BdataLoc *dataloc) { | ||
+ | |||
// Figure out which triggers got a hit. These are multihit TDCs, so we | // Figure out which triggers got a hit. These are multihit TDCs, so we | ||
+ | |||
// need to sort out which hit we want to take by applying cuts. | // need to sort out which hit we want to take by applying cuts. | ||
Line 25: | Line 28: | ||
} | } | ||
//_____________________________________________________________________________ | //_____________________________________________________________________________ | ||
− | + | ||
+ | |||
+ | so one has to look at the time distributions D.bit[n] and make sure those are withing the range of the cut. If they are not one should change the limits so that all triggers fit inside and recompile the class. |
Latest revision as of 15:33, 6 February 2007
FAQ
THaDecData : trigger pattern
The trigger pattern word D.evtypbits uses the trigger latch TDC data to generate this data. A window has to be defined to have a hit counted as a trigger.
//_____________________________________________________________________________
void THaDecData::TrigBits(UInt_t ibit, BdataLoc *dataloc) {
// Figure out which triggers got a hit. These are multihit TDCs, so we
// need to sort out which hit we want to take by applying cuts.
if( ibit >= kBitsPerByte*sizeof(UInt_t) ) return; //Limit of evtypebits bits.ResetBitNumber(ibit);
static const UInt_t cutlo = 400; static const UInt_t cuthi = 1200; for (int ihit = 0; ihit < dataloc->NumHits(); ihit++) { if (dataloc->Get(ihit) > cutlo && dataloc->Get(ihit) < cuthi) { bits.SetBitNumber(ibit); evtypebits |= BIT(ibit); } }
} //_____________________________________________________________________________
so one has to look at the time distributions D.bit[n] and make sure those are withing the range of the cut. If they are not one should change the limits so that all triggers fit inside and recompile the class.