FACT++  1.0
bool StateMachineFeedback::LoadOffsets ( const string &  file)
inlineprivate

Definition at line 1063 of file feedback.cc.

References data, Error(), BIAS::kNumChannels, and DimDescribedService::Update().

1064  {
1065  vector<double> data(BIAS::kNumChannels);
1066 
1067  ifstream fin(file);
1068 
1069  int cnt = 0;
1070  while (fin && cnt<320)
1071  fin >> data[cnt++];
1072 
1073  if (cnt!=320)
1074  {
1075  Error("Reading offsets from "+file+" failed [N="+to_string(cnt-1)+"]");
1076  return false;
1077  }
1078 
1079  fVoltOffset = data;
1080 
1082 
1083  Info("New voltage offsets loaded from "+file);
1084  return true;
1085 
1086  }
DimDescribedService fDimOffsets
Definition: feedback.cc:44
int Error(const std::string &str)
Definition: MessageImp.h:49
vector< double > fVoltOffset
Definition: feedback.cc:75
float data[4 *1440]
int Info(const std::string &str)
Definition: MessageImp.h:47

+ Here is the call graph for this function: