FACT++  1.0
int StateMachineRateControl::HandleStaticData ( const EventImp evt)
inlineprivate

Definition at line 376 of file ratecontrol.cc.

References FTM::DimStaticData::fThreshold, EventImp::GetData(), EventImp::GetQoS(), EventImp::GetTime(), FTM::DimStaticData::HasTrigger(), FTM::kFtmRunning, FTM::kFtmStates, RateControl::State::kGlobalThresholdSet, and RateControl::State::kSettingGlobalThreshold.

Referenced by StateMachineRateControl().

377  {
378  if (!CheckEventSize(evt, sizeof(FTM::DimStaticData)))
379  return GetCurrentState();
380 
381  const FTM::DimStaticData &sdata = *static_cast<const FTM::DimStaticData*>(evt.GetData());
384 
385  Out() << "\n" << evt.GetTime() << ": " << (bool)fTriggerOn << " " << (bool)fPhysTriggerEnabled << endl;
386  PrintThresholds(sdata);
387 
389  {
390  if (fThresholds.empty())
392 
393  if (!std::equal(sdata.fThreshold, sdata.fThreshold+160, fThresholds.begin()))
395 
397  }
398 
399  fThresholds.assign(sdata.fThreshold, sdata.fThreshold+160);
400 
401  return GetCurrentState();
402  }
bool HasTrigger() const
Definition: HeadersFTM.h:415
int GetCurrentState() const
return the current state of the machine
void PrintThresholds(const FTM::DimStaticData &sdata)
Definition: ratecontrol.cc:100
std::ostream & Out() const
Definition: MessageImp.h:73
virtual Time GetTime() const
Definition: EventImp.h:57
virtual int GetQoS() const
Definition: EventImp.h:58
uint16_t fThreshold[160]
Definition: HeadersFTM.h:410
virtual const void * GetData() const
Definition: EventImp.h:54
Trigger output enabled, configuration ignored.
Definition: HeadersFTM.h:23
vector< uint32_t > fThresholds
Definition: ratecontrol.cc:98
bool CheckEventSize(const EventImp &evt, size_t size)
Definition: ratecontrol.cc:84

+ Here is the call graph for this function:

+ Here is the caller graph for this function: