mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-05 17:40:40 +02:00
Merge branch 'jungfrau1.1' into j11udpate
This commit is contained in:
commit
6dfcd9607f
@ -38,6 +38,9 @@ This document describes the differences between 5.2.0 and 5.1.0 releases.
|
|||||||
|
|
||||||
1. Bad Channels moved to a new register
|
1. Bad Channels moved to a new register
|
||||||
|
|
||||||
|
|
||||||
|
Jungfrau- many Features
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
2. Resolved Issues
|
2. Resolved Issues
|
||||||
@ -59,7 +62,7 @@ This document describes the differences between 5.2.0 and 5.1.0 releases.
|
|||||||
detector server to reset core until firmware release.
|
detector server to reset core until firmware release.
|
||||||
|
|
||||||
|
|
||||||
|
getAutoCompDisable->getAutoComparatorDisable
|
||||||
|
|
||||||
3. Firmware Requirements
|
3. Firmware Requirements
|
||||||
========================
|
========================
|
||||||
|
@ -2016,11 +2016,11 @@ class Detector(CppDetectorApi):
|
|||||||
By default, the on-chip gain switching is active during the entire exposure. This mode disables the on-chip gain switching comparator automatically after 93.75% of exposure time (only for longer than 100us). The % is only for chipv1.0, the duration can be set for chipv1.1.\n
|
By default, the on-chip gain switching is active during the entire exposure. This mode disables the on-chip gain switching comparator automatically after 93.75% of exposure time (only for longer than 100us). The % is only for chipv1.0, the duration can be set for chipv1.1.\n
|
||||||
Default is 0 or this mode disabled (comparator enabled throughout). 1 enables mode. 0 disables mode.
|
Default is 0 or this mode disabled (comparator enabled throughout). 1 enables mode. 0 disables mode.
|
||||||
"""
|
"""
|
||||||
return self.getAutoCompDisable()
|
return self.getAutoComparatorDisable()
|
||||||
|
|
||||||
@auto_comp_disable.setter
|
@auto_comp_disable.setter
|
||||||
def auto_comp_disable(self, value):
|
def auto_comp_disable(self, value):
|
||||||
ut.set_using_dict(self.setAutoCompDisable, value)
|
ut.set_using_dict(self.setAutoComparatorDisable, value)
|
||||||
|
|
||||||
@property
|
@property
|
||||||
@element
|
@element
|
||||||
|
@ -970,13 +970,13 @@ void init_det(py::module &m) {
|
|||||||
(void (Detector::*)(sls::Positions)) &
|
(void (Detector::*)(sls::Positions)) &
|
||||||
Detector::resetTemperatureEvent,
|
Detector::resetTemperatureEvent,
|
||||||
py::arg() = Positions{})
|
py::arg() = Positions{})
|
||||||
.def("getAutoCompDisable",
|
.def("getAutoComparatorDisable",
|
||||||
(Result<bool>(Detector::*)(sls::Positions) const) &
|
(Result<bool>(Detector::*)(sls::Positions) const) &
|
||||||
Detector::getAutoCompDisable,
|
Detector::getAutoComparatorDisable,
|
||||||
py::arg() = Positions{})
|
py::arg() = Positions{})
|
||||||
.def("setAutoCompDisable",
|
.def("setAutoComparatorDisable",
|
||||||
(void (Detector::*)(bool, sls::Positions)) &
|
(void (Detector::*)(bool, sls::Positions)) &
|
||||||
Detector::setAutoCompDisable,
|
Detector::setAutoComparatorDisable,
|
||||||
py::arg(), py::arg() = Positions{})
|
py::arg(), py::arg() = Positions{})
|
||||||
.def("getComparatorDisableTime",
|
.def("getComparatorDisableTime",
|
||||||
(Result<sls::ns>(Detector::*)(sls::Positions) const) &
|
(Result<sls::ns>(Detector::*)(sls::Positions) const) &
|
||||||
|
@ -1127,7 +1127,7 @@ class Detector {
|
|||||||
void resetTemperatureEvent(Positions pos = {});
|
void resetTemperatureEvent(Positions pos = {});
|
||||||
|
|
||||||
/** [Jungfrau] */
|
/** [Jungfrau] */
|
||||||
Result<bool> getAutoCompDisable(Positions pos = {}) const;
|
Result<bool> getAutoComparatorDisable(Positions pos = {}) const;
|
||||||
|
|
||||||
/** [Jungfrau] Advanced
|
/** [Jungfrau] Advanced
|
||||||
* //TODO naming
|
* //TODO naming
|
||||||
@ -1139,7 +1139,7 @@ class Detector {
|
|||||||
* disabled(comparator enabled throughout). true enables mode. 0 disables
|
* disabled(comparator enabled throughout). true enables mode. 0 disables
|
||||||
* mode.
|
* mode.
|
||||||
*/
|
*/
|
||||||
void setAutoCompDisable(bool value, Positions pos = {});
|
void setAutoComparatorDisable(bool value, Positions pos = {});
|
||||||
|
|
||||||
/** [Jungfrau] */
|
/** [Jungfrau] */
|
||||||
Result<ns> getComparatorDisableTime(Positions pos = {}) const;
|
Result<ns> getComparatorDisableTime(Positions pos = {}) const;
|
||||||
|
@ -1838,7 +1838,7 @@ class CmdProxy {
|
|||||||
"cleared.");
|
"cleared.");
|
||||||
|
|
||||||
INTEGER_COMMAND_VEC_ID(
|
INTEGER_COMMAND_VEC_ID(
|
||||||
auto_comp_disable, getAutoCompDisable, setAutoCompDisable,
|
auto_comp_disable, getAutoComparatorDisable, setAutoComparatorDisable,
|
||||||
StringTo<int>,
|
StringTo<int>,
|
||||||
"[0, 1]\n\t[Jungfrau] Auto comparator disable mode. By default, the "
|
"[0, 1]\n\t[Jungfrau] Auto comparator disable mode. By default, the "
|
||||||
"on-chip gain switching is active during the entire exposure.This mode "
|
"on-chip gain switching is active during the entire exposure.This mode "
|
||||||
|
@ -1451,11 +1451,11 @@ void Detector::resetTemperatureEvent(Positions pos) {
|
|||||||
pimpl->Parallel(&Module::resetTemperatureEvent, pos);
|
pimpl->Parallel(&Module::resetTemperatureEvent, pos);
|
||||||
}
|
}
|
||||||
|
|
||||||
Result<bool> Detector::getAutoCompDisable(Positions pos) const {
|
Result<bool> Detector::getAutoComparatorDisable(Positions pos) const {
|
||||||
return pimpl->Parallel(&Module::getAutoComparatorDisableMode, pos);
|
return pimpl->Parallel(&Module::getAutoComparatorDisableMode, pos);
|
||||||
}
|
}
|
||||||
|
|
||||||
void Detector::setAutoCompDisable(bool value, Positions pos) {
|
void Detector::setAutoComparatorDisable(bool value, Positions pos) {
|
||||||
pimpl->Parallel(&Module::setAutoComparatorDisableMode, pos, value);
|
pimpl->Parallel(&Module::setAutoComparatorDisableMode, pos, value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -258,7 +258,7 @@ TEST_CASE("auto_comp_disable", "[.cmd]") {
|
|||||||
CmdProxy proxy(&det);
|
CmdProxy proxy(&det);
|
||||||
auto det_type = det.getDetectorType().squash();
|
auto det_type = det.getDetectorType().squash();
|
||||||
if (det_type == defs::JUNGFRAU) {
|
if (det_type == defs::JUNGFRAU) {
|
||||||
auto prev_val = det.getAutoCompDisable();
|
auto prev_val = det.getAutoComparatorDisable();
|
||||||
{
|
{
|
||||||
std::ostringstream oss;
|
std::ostringstream oss;
|
||||||
proxy.Call("auto_comp_disable", {"0"}, -1, PUT, oss);
|
proxy.Call("auto_comp_disable", {"0"}, -1, PUT, oss);
|
||||||
@ -275,7 +275,7 @@ TEST_CASE("auto_comp_disable", "[.cmd]") {
|
|||||||
REQUIRE(oss.str() == "auto_comp_disable 1\n");
|
REQUIRE(oss.str() == "auto_comp_disable 1\n");
|
||||||
}
|
}
|
||||||
for (int i = 0; i != det.size(); ++i) {
|
for (int i = 0; i != det.size(); ++i) {
|
||||||
det.setAutoCompDisable(prev_val[i], {i});
|
det.setAutoComparatorDisable(prev_val[i], {i});
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
REQUIRE_THROWS(proxy.Call("auto_comp_disable", {}, -1, GET));
|
REQUIRE_THROWS(proxy.Call("auto_comp_disable", {}, -1, GET));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user