FACT++  1.0
template<class T>
int StateMachineFAD< T >::SetTriggerRate ( const EventImp evt)
inlineprivate

Definition at line 751 of file fadctrl.cc.

References Error(), EventImp::GetSize(), EventImp::GetUInt(), EventImp::GetUShort(), and i.

Referenced by StateMachineFAD< T >::StateMachineFAD().

752  {
753  if (!CheckEventSize(evt.GetSize(), "SetTriggerRate", 4))
754  return T::kSM_FatalError;
755 
756  if (evt.GetUInt()>0xffff)
757  {
758  ostringstream msg;
759  msg << hex << "Value " << evt.GetUShort() << " out of range, max=" << 0xffff << "(?)";
760  T::Error(msg);
761  return T::GetCurrentState();
762  }
763 
764  for (BoardList::iterator i=fBoards.begin(); i!=fBoards.end(); i++)
765  i->second->CmdSetTriggerRate(evt.GetUInt());
766 
767  return T::GetCurrentState();
768  }
BoardList fBoards
Definition: fadctrl.cc:555
int i
Definition: db_dim_client.c:21
uint16_t GetUShort() const
Definition: EventImp.h:92
uint32_t GetUInt() const
Definition: EventImp.h:94
Error()
Definition: HeadersFTM.h:197
bool CheckEventSize(size_t has, const char *name, size_t size)
Definition: fadctrl.cc:562
virtual size_t GetSize() const
Definition: EventImp.h:55

+ Here is the call graph for this function:

+ Here is the caller graph for this function: