FACT++  1.0
States ConnectionFTM::GetState ( ) const
inline

Definition at line 1206 of file ftmctrl.cc.

References FTM::Header::fState, MCP::State::kConfigured, Agilent::State::kConnected, Agilent::State::kDisconnected, FTM::kFtmCalib, FTM::kFtmConfig, FTM::kFtmIdle, FTM::kFtmRunning, FTM::kFtmStates, FTM::kFtmUndefined, EventServer::State::kIdle, FTM::State::kTriggerOn, and FTM::StaticData::valid().

1207  {
1208  if (!IsConnected())
1209  return kDisconnected; // rc=1
1210 
1211  switch (fHeader.fState&FTM::kFtmStates)
1212  {
1213  case FTM::kFtmUndefined: // 0
1214  return fBufStaticData.valid() ? kConnected : kDisconnected; // rc=2
1215 
1216  case FTM::kFtmRunning: // 3
1217  case FTM::kFtmCalib: // 4
1218  return kTriggerOn; // rc=4
1219 
1220  case FTM::kFtmIdle: // 1
1221  case FTM::kFtmConfig: // 2 // rc=7 // rc=3
1223  }
1224 
1225  throw runtime_error("ConnectionFTM::GetState - Impossible code reached.");
1226  }
FTM::StaticData fBufStaticData
Definition: ftmctrl.cc:57
FTM and FTUs are being reconfigured.
Definition: HeadersFTM.h:22
uint16_t fState
State of the FTM central state machine.
Definition: HeadersFTM.h:109
FTM::StaticData fStaticData
Definition: ftmctrl.cc:53
bool valid() const
Definition: HeadersFTM.h:266
Trigger output disabled, configuration possible.
Definition: HeadersFTM.h:21
FTM::Header fHeader
Definition: ftmctrl.cc:51
Trigger output enabled, configuration ignored.
Definition: HeadersFTM.h:23

+ Here is the call graph for this function: