mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2026-02-20 13:48:41 +01:00
Removed Padding option for Deactivated half modules.
This commit is contained in:
@@ -1669,50 +1669,6 @@ std::string CmdProxy::RateCorrection(int action) {
|
||||
return os.str();
|
||||
}
|
||||
|
||||
std::string CmdProxy::Activate(int action) {
|
||||
std::ostringstream os;
|
||||
os << cmd << ' ';
|
||||
if (action == defs::HELP_ACTION) {
|
||||
os << "[0, 1] [(optional) padding|nopadding]\n\t[Eiger] 1 is default. "
|
||||
"0 deactivates readout and does not send data. \n\tPadding will "
|
||||
"pad data files for deactivates readouts."
|
||||
<< '\n';
|
||||
} else if (action == defs::GET_ACTION) {
|
||||
if (!args.empty()) {
|
||||
WrongNumberOfParameters(0);
|
||||
}
|
||||
auto t = det->getActive(std::vector<int>{det_id});
|
||||
auto p = det->getRxPadDeactivatedMode(std::vector<int>{det_id});
|
||||
Result<std::string> pResult(p.size());
|
||||
for (unsigned int i = 0; i < p.size(); ++i) {
|
||||
pResult[i] = p[i] ? "padding" : "nopadding";
|
||||
}
|
||||
os << OutString(t) << ' ' << OutString(pResult) << '\n';
|
||||
} else if (action == defs::PUT_ACTION) {
|
||||
if (args.empty() || args.size() > 2) {
|
||||
WrongNumberOfParameters(2);
|
||||
}
|
||||
int t = StringTo<int>(args[0]);
|
||||
det->setActive(t, std::vector<int>{det_id});
|
||||
os << args[0];
|
||||
if (args.size() == 2) {
|
||||
bool p = true;
|
||||
if (args[1] == "nopadding") {
|
||||
p = false;
|
||||
} else if (args[1] != "padding") {
|
||||
throw sls::RuntimeError(
|
||||
"Unknown argument for deactivated padding.");
|
||||
}
|
||||
det->setRxPadDeactivatedMode(p, std::vector<int>{det_id});
|
||||
os << ' ' << args[1];
|
||||
}
|
||||
os << '\n';
|
||||
} else {
|
||||
throw sls::RuntimeError("Unknown action");
|
||||
}
|
||||
return os.str();
|
||||
}
|
||||
|
||||
std::string CmdProxy::PulsePixel(int action) {
|
||||
std::ostringstream os;
|
||||
os << cmd << ' ';
|
||||
|
||||
Reference in New Issue
Block a user