Ignore:
Timestamp:
01/19/05 14:44:48 (20 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars/mtrigger
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/mtrigger/MFTriggerPattern.cc

    r5900 r5903  
    9292
    9393    // Check whether all the bits required are ON
    94     if ( ((p & fMaskRequiredPrescaled) == fMaskRequiredPrescaled)
    95          && ((u & fMaskRequiredUnprescaled) == fMaskRequiredUnprescaled))
     94    if ( ((p & fMaskRequiredPrescaled)   == fMaskRequiredPrescaled) &&
     95        ((u & fMaskRequiredUnprescaled) == fMaskRequiredUnprescaled))
    9696      fResult = kTRUE;
    9797
     
    105105void MFTriggerPattern::RequireTriggerLvl1(Prescale_t prescaled)
    106106{
    107     prescaled ? (fMaskRequiredPrescaled |= MTriggerPattern::kTriggerLvl1) : (fMaskRequiredUnprescaled |= MTriggerPattern::kTriggerLvl1);
     107    prescaled==kPrescaled ? (fMaskRequiredPrescaled |= MTriggerPattern::kTriggerLvl1) : (fMaskRequiredUnprescaled |= MTriggerPattern::kTriggerLvl1);
    108108}
    109109
    110110void MFTriggerPattern::RequireTriggerLvl2(Prescale_t prescaled)
    111111{
    112     prescaled ? (fMaskRequiredPrescaled |= MTriggerPattern::kTriggerLvl2) : (fMaskRequiredUnprescaled |= MTriggerPattern::kTriggerLvl2);
     112    prescaled==kPrescaled ? (fMaskRequiredPrescaled |= MTriggerPattern::kTriggerLvl2) : (fMaskRequiredUnprescaled |= MTriggerPattern::kTriggerLvl2);
    113113}
    114114
    115115void MFTriggerPattern::RequireCalibration(Prescale_t prescaled)
    116116{
    117     prescaled ? (fMaskRequiredPrescaled |= MTriggerPattern::kCalibration) : (fMaskRequiredUnprescaled |= MTriggerPattern::kCalibration);
     117    prescaled==kPrescaled ? (fMaskRequiredPrescaled |= MTriggerPattern::kCalibration) : (fMaskRequiredUnprescaled |= MTriggerPattern::kCalibration);
    118118}
    119119
    120120void MFTriggerPattern::RequirePedestal(Prescale_t prescaled)
    121121{
    122     prescaled ? (fMaskRequiredPrescaled |= MTriggerPattern::kPedestal)    : (fMaskRequiredUnprescaled |= MTriggerPattern::kPedestal);
     122    prescaled==kPrescaled ? (fMaskRequiredPrescaled |= MTriggerPattern::kPedestal)    : (fMaskRequiredUnprescaled |= MTriggerPattern::kPedestal);
    123123}
    124124
    125125void MFTriggerPattern::RequirePinDiode(Prescale_t prescaled)
    126126{
    127     prescaled ? (fMaskRequiredPrescaled |= MTriggerPattern::kPinDiode)    : (fMaskRequiredUnprescaled |= MTriggerPattern::kPinDiode);
     127    prescaled==kPrescaled ? (fMaskRequiredPrescaled |= MTriggerPattern::kPinDiode)    : (fMaskRequiredUnprescaled |= MTriggerPattern::kPinDiode);
    128128}
    129129
     
    131131void MFTriggerPattern::DenyTriggerLvl1(Prescale_t prescaled)
    132132{
    133     prescaled ? (fMaskDeniedPrescaled |= MTriggerPattern::kTriggerLvl1) : (fMaskDeniedUnprescaled |= MTriggerPattern::kTriggerLvl1);
     133    prescaled==kPrescaled ? (fMaskDeniedPrescaled |= MTriggerPattern::kTriggerLvl1) : (fMaskDeniedUnprescaled |= MTriggerPattern::kTriggerLvl1);
    134134}
    135135
    136136void MFTriggerPattern::DenyTriggerLvl2(Prescale_t prescaled)
    137137{
    138     prescaled ? (fMaskDeniedPrescaled |= MTriggerPattern::kTriggerLvl2) : (fMaskDeniedUnprescaled |= MTriggerPattern::kTriggerLvl2);
     138    prescaled==kPrescaled ? (fMaskDeniedPrescaled |= MTriggerPattern::kTriggerLvl2) : (fMaskDeniedUnprescaled |= MTriggerPattern::kTriggerLvl2);
    139139}
    140140
    141141void MFTriggerPattern::DenyCalibration(Prescale_t prescaled)
    142142{
    143     prescaled ? (fMaskDeniedPrescaled |= MTriggerPattern::kCalibration) : (fMaskDeniedUnprescaled |= MTriggerPattern::kCalibration);
     143    prescaled==kPrescaled ? (fMaskDeniedPrescaled |= MTriggerPattern::kCalibration) : (fMaskDeniedUnprescaled |= MTriggerPattern::kCalibration);
    144144}
    145145
    146146void MFTriggerPattern::DenyPedestal(Prescale_t prescaled)
    147147{
    148     prescaled ? (fMaskDeniedPrescaled |= MTriggerPattern::kPedestal)    : (fMaskDeniedUnprescaled |= MTriggerPattern::kPedestal);
     148    prescaled==kPrescaled ? (fMaskDeniedPrescaled |= MTriggerPattern::kPedestal)    : (fMaskDeniedUnprescaled |= MTriggerPattern::kPedestal);
    149149}
    150150
    151151void MFTriggerPattern::DenyPinDiode(Prescale_t prescaled)
    152152{
    153     prescaled ? (fMaskDeniedPrescaled |= MTriggerPattern::kPinDiode)    : (fMaskDeniedUnprescaled |= MTriggerPattern::kPinDiode);
     153    prescaled==kPrescaled ? (fMaskDeniedPrescaled |= MTriggerPattern::kPinDiode)    : (fMaskDeniedUnprescaled |= MTriggerPattern::kPinDiode);
    154154}
    155155
     
    176176void MFTriggerPattern::SetMaskRequired(const Byte_t mask, Prescale_t prescaled)
    177177{
    178     prescaled ? (fMaskRequiredPrescaled = mask) : (fMaskRequiredUnprescaled = mask);
     178    prescaled==kPrescaled ? (fMaskRequiredPrescaled = mask) : (fMaskRequiredUnprescaled = mask);
    179179}
    180180
     
    201201void MFTriggerPattern::SetMaskDenied(const Byte_t mask, Prescale_t prescaled)
    202202{
    203     prescaled ? (fMaskDeniedPrescaled  = mask) : (fMaskDeniedUnprescaled  = mask);
     203    prescaled==kPrescaled ? (fMaskDeniedPrescaled  = mask) : (fMaskDeniedUnprescaled  = mask);
    204204}
    205205
  • trunk/MagicSoft/Mars/mtrigger/MFTriggerPattern.h

    r5900 r5903  
    1010class MFTriggerPattern : public MFilter
    1111{
    12  private:
     12public:
     13    enum Prescale_t {
     14        kUnPrescaled,
     15        kPrescaled
     16    };
     17
     18private:
    1319  MTriggerPattern *fPattern;        //!
    1420 
     
    2531  Bool_t IsExpressionTrue() const;
    2632 
    27  public:
    28   enum Prescale_t {
    29     kUnPrescaled = kFALSE,
    30     kPrescaled   = kTRUE };
    31 
     33public:
    3234  MFTriggerPattern(const char *name=NULL, const char *title=NULL);
    3335  MFTriggerPattern(MFTriggerPattern &trigpatt);
Note: See TracChangeset for help on using the changeset viewer.