removed setClockFrequency and added some python commands

This commit is contained in:
Erik Frojdh
2020-09-17 16:03:58 +02:00
parent e8cd75a6ac
commit 6d01348bf4
7 changed files with 132 additions and 23 deletions

View File

@ -310,9 +310,6 @@ class Detector {
/** [Mythen3][Gotthard2] Hz */
Result<int> getClockFrequency(int clkIndex, Positions pos = {});
/** [not implemented] Hz */
void setClockFrequency(int clkIndex, int value, Positions pos = {});
/** [Mythen3][Gotthard2] */
Result<int> getClockPhase(int clkIndex, Positions pos = {});

View File

@ -699,13 +699,7 @@ std::string CmdProxy::ClockFrequency(int action) {
std::vector<int>{det_id});
os << OutString(t) << '\n';
} else if (action == defs::PUT_ACTION) {
if (args.size() != 2) {
WrongNumberOfParameters(2);
}
det->setClockFrequency(StringTo<int>(args[0]),
StringTo<int>(args[1]),
std::vector<int>{det_id});
os << StringTo<int>(args[1]) << '\n';
throw sls::RuntimeError("cannot put");
} else {
throw sls::RuntimeError("Unknown action");
}

View File

@ -384,9 +384,6 @@ Result<int> Detector::getClockFrequency(int clkIndex, Positions pos) {
return pimpl->Parallel(&Module::getClockFrequency, pos, clkIndex);
}
void Detector::setClockFrequency(int clkIndex, int value, Positions pos) {
pimpl->Parallel(&Module::setClockFrequency, pos, clkIndex, value);
}
Result<int> Detector::getClockPhase(int clkIndex, Positions pos) {
return pimpl->Parallel(&Module::getClockPhase, pos, clkIndex, false);