fixes
This commit is contained in:
parent
bb28f0aa03
commit
610d09ee98
@ -430,12 +430,13 @@ std::string RaptorEagleCCD::AcquisitionProcess::status()
|
||||
_statusString = std::format("{}", CAMERA_ATTR_CAMERA_STATUS_IDLE);
|
||||
break;
|
||||
case STATUS_ACQ: {
|
||||
std::chrono::duration<double> curr_exp = _acqParams->abortTime - _acqParams->startTime;
|
||||
if (curr_exp.count() <= 0) {
|
||||
std::chrono::duration<double> curr_exp = std::chrono::utc_clock::now() - _acqParams->startTime;
|
||||
auto remain_exp = _acqParams->expTime - curr_exp.count();
|
||||
if (remain_exp < 0) {
|
||||
_status = STATUS_READ;
|
||||
_statusString = std::format("{} {}", CAMERA_ATTR_CAMERA_STATUS_READ, _acqParams->filename);
|
||||
} else {
|
||||
_statusString = std::format("{} {}", CAMERA_ATTR_CAMERA_STATUS_ACQ, curr_exp.count());
|
||||
_statusString = std::format("{} {}", CAMERA_ATTR_CAMERA_STATUS_ACQ, remain_exp);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
@ -1059,13 +1059,10 @@ void RaptorEagleCCD::startAquisition()
|
||||
xclibApiCall(status = pxd_goneLive(_cameraUnitmap, 0), std::format("pxd_goneLive({}, 0)", _cameraUnitmap));
|
||||
if (status == 0) {
|
||||
logError("CANNOT START ACQUIRING!!!");
|
||||
sptr->_status = AcquisitionProcess::STATUS_IDLE;
|
||||
} else {
|
||||
sptr->_status = AcquisitionProcess::STATUS_ACQ;
|
||||
}
|
||||
|
||||
// std::lock_guard lock(sptr->_statusMutex);
|
||||
sptr->_status = AcquisitionProcess::STATUS_IDLE;
|
||||
// sptr->_status = std::format("{} {}", CAMERA_ATTR_CAMERA_STATUS_ACQ, sptr->_acqParams->expTime);
|
||||
|
||||
// _cameraStatus = CAMERA_ATTR_CAMERA_STATUS_ACQ;
|
||||
}
|
||||
|
||||
|
||||
@ -1230,6 +1227,7 @@ void RaptorEagleCCD::initAttrComm()
|
||||
std::ranges::copy(st, std::back_inserter(s));
|
||||
s += ", ";
|
||||
}
|
||||
++it;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user