mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-20 02:40:03 +02:00
merge from 6.1.2.rc for stop detector (eiger)
This commit is contained in:
parent
61c31ed44a
commit
255a75a646
@ -821,7 +821,19 @@ void Detector::startDetectorReadout() {
|
||||
}
|
||||
|
||||
void Detector::stopDetector(Positions pos) {
|
||||
pimpl->Parallel(&Module::stopAcquisition, pos);
|
||||
|
||||
// stop and check status X times
|
||||
int retries{0};
|
||||
// avoid default construction of runStatus::IDLE on squash
|
||||
auto status = getDetectorStatus().squash(defs::runStatus::RUNNING);
|
||||
while (status != defs::runStatus::IDLE) {
|
||||
pimpl->Parallel(&Module::stopAcquisition, pos);
|
||||
status = getDetectorStatus().squash(defs::runStatus::RUNNING);
|
||||
++retries;
|
||||
|
||||
if (retries == 10)
|
||||
throw RuntimeError("Could not stop detector");
|
||||
}
|
||||
|
||||
// validate consistent frame numbers
|
||||
switch (getDetectorType().squash()) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user