This commit is contained in:
2020-06-04 12:12:40 +02:00
parent 3bdc8e95ce
commit 9a8300ca08
7 changed files with 778 additions and 359 deletions

View File

@ -1468,7 +1468,7 @@ void Detector::setExternalSamplingSource(int value, Positions pos) {
pimpl->Parallel(&Module::setExternalSamplingSource, pos, value);
}
Result<int> Detector::getExternalSampling(Positions pos) const {
Result<bool> Detector::getExternalSampling(Positions pos) const {
return pimpl->Parallel(&Module::getExternalSampling, pos);
}

View File

@ -2201,11 +2201,14 @@ int Module::getExternalSamplingSource() {
return setExternalSamplingSource(-1);
}
int Module::setExternalSampling(int value) {
return sendToDetector<int>(F_EXTERNAL_SAMPLING, value);
void Module::setExternalSampling(bool value) {
sendToDetector<int>(F_EXTERNAL_SAMPLING, static_cast<int>(value));
}
int Module::getExternalSampling() { return setExternalSampling(-1); }
bool Module::getExternalSampling() {
int arg = -1;
return sendToDetector<int>(F_EXTERNAL_SAMPLING, arg);
}
void Module::setReceiverDbitList(const std::vector<int> &list) {
LOG(logDEBUG1) << "Setting Receiver Dbit List";

View File

@ -1079,20 +1079,9 @@ class Module : public virtual slsDetectorDefs {
*/
int getExternalSamplingSource();
/**
* Set external sampling enable (CTB only)
* @param value external sampling source (Option: 0-63)
* @param detPos -1 for all detectors in list or specific detector position
* @returns external sampling enable
*/
int setExternalSampling(int value);
void setExternalSampling(bool value);
/**
* Get external sampling source (CTB only)
* @param detPos -1 for all detectors in list or specific detector position
* @returns external sampling enable
*/
int getExternalSampling();
bool getExternalSampling();
/** digital data bits enable (CTB only) */
void setReceiverDbitList(const std::vector<int> &list);