Changeset 12505


Ignore:
Timestamp:
11/13/11 15:42:36 (13 years ago)
Author:
tbretz
Message:
Do not change rates if a ratescan is in progress.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/src/ratecontrol.cc

    r12488 r12505  
    5050    pair<Time, int> fStatusDim;
    5151    pair<Time, int> fStatusFTM;
     52    pair<Time, int> fStatusRS;
    5253
    5354    DimStampedInfo fDim;
     
    5556    DimStampedInfo fRates;
    5657    DimStampedInfo fStatic;
     58    DimStampedInfo fRateScan;
    5759
    5860//    DimDescribedService fDimData;
     
    348350            return;
    349351        }
     352        if (curr==&fRateScan)
     353        {
     354            fStatusRS = GetNewState(fRateScan);
     355            fStatusRS.second = curr->getSize()==4 ? curr->getInt() : 0;
     356            return;
     357        }
    350358
    351359        static vector<uint8_t> counter(160);
     
    371379
    372380            if (!fTriggerOn && !fEnabled)
     381                return;
     382
     383            if (fStatusRS.second==5)
    373384                return;
    374385
     
    515526        // At least one subsystem is not connected
    516527        //        if (fStatusFTM.second>=FTM::kConnected)
    517         return fTriggerOn && fEnabled ? kStateInProgress : kStateConnected;
     528        return fTriggerOn && fEnabled && fStatusRS.second!=5 ? kStateInProgress : kStateConnected;
    518529    }
    519530
Note: See TracChangeset for help on using the changeset viewer.