mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-28 01:00:02 +02:00
wip doc
This commit is contained in:
parent
a2ec86006d
commit
550ab51f34
@ -206,6 +206,21 @@ class Detector(CppDetectorApi):
|
||||
def exptime(self):
|
||||
"""
|
||||
Exposure time, accepts either a value in seconds or datetime.timedelta
|
||||
|
||||
Note
|
||||
-----
|
||||
[Mythen3] sets exposure time to all gate signals in auto and trigger mode (internal gating). To specify gateIndex, use getExptime or setExptime.
|
||||
|
||||
:getter: always returns in seconds. To get in datetime.delta, use getExptime
|
||||
|
||||
Examples
|
||||
-----------
|
||||
>>> d.exptime = 1.05
|
||||
>>> d.exptime = datetime.timedelta(minutes = 3, seconds = 1.23)
|
||||
>>> d.exptime
|
||||
181.23
|
||||
>>> d.getExptime()
|
||||
[datetime.timedelta(seconds=181, microseconds=230000)]
|
||||
"""
|
||||
if self.type == detectorType.MYTHEN3:
|
||||
res = self.getExptimeForAllGates()
|
||||
@ -231,6 +246,22 @@ class Detector(CppDetectorApi):
|
||||
@property
|
||||
@element
|
||||
def delay(self):
|
||||
"""
|
||||
[Gotthard][Jungfrau][CTB][Moench][Mythen3][Gotthard2] Delay after trigger, accepts either a value in seconds or datetime.timedelta
|
||||
|
||||
Note
|
||||
-----
|
||||
:getter: always returns in seconds. To get in datetime.delta, use getDelayAfterTrigger
|
||||
|
||||
Examples
|
||||
-----------
|
||||
>>> d.delay = 1.05
|
||||
>>> d.delay = datetime.timedelta(minutes = 3, seconds = 1.23)
|
||||
>>> d.delay
|
||||
181.23
|
||||
>>> d.getDelayAfterTrigger()
|
||||
[datetime.timedelta(seconds=181, microseconds=230000)]
|
||||
"""
|
||||
return ut.reduce_time(self.getDelayAfterTrigger())
|
||||
|
||||
@delay.setter
|
||||
|
@ -176,10 +176,13 @@ class Detector {
|
||||
|
||||
void setNumberOfTriggers(int64_t value);
|
||||
|
||||
/** [Gotthard][Jungfrau][Eiger][CTB][Moench][Gotthard2] For Mythen3, use
|
||||
* function with gate index **/
|
||||
/** [Gotthard][Jungfrau][Eiger][CTB][Moench][Gotthard2] \n
|
||||
* [Mythen3] use function with gate index **/
|
||||
Result<ns> getExptime(Positions pos = {}) const;
|
||||
|
||||
/** [Gotthard][Jungfrau][Eiger][CTB][Moench][Gotthard2] \n
|
||||
* [Mythen3] sets exptime for all gate signals. To specify gate index, use
|
||||
* function with gate index **/
|
||||
void setExptime(ns t, Positions pos = {});
|
||||
|
||||
Result<ns> getPeriod(Positions pos = {}) const;
|
||||
|
@ -387,25 +387,21 @@ std::string CmdProxy::Exptime(int action) {
|
||||
os << "[duration] [(optional unit) "
|
||||
"ns|us|ms|s]\n\t[Eiger][Jungfrau][Gotthard][Gotthard2]["
|
||||
"Moench][Ctb] Exposure time"
|
||||
"\n\t[Gotthard2] Uploaded to detector just before "
|
||||
"acquisition starts"
|
||||
"\n\t[Mythen3] Exposure time of all gate signals in auto and "
|
||||
"trigger mode (internal gating)."
|
||||
"trigger mode (internal gating). To specify gate index, use "
|
||||
"exptime1, exptime2, exptime3."
|
||||
<< '\n';
|
||||
} else if (cmd == "exptime1") {
|
||||
os << "[n_value]\n\t[Mythen3] Exposure time of gate signal 1 in "
|
||||
"auto and "
|
||||
"trigger mode (internal gating)."
|
||||
"auto and trigger mode (internal gating)."
|
||||
<< '\n';
|
||||
} else if (cmd == "exptime2") {
|
||||
os << "[n_value]\n\t[Mythen3] Exposure time of gate signal 2 in "
|
||||
"auto and "
|
||||
"trigger mode (internal gating)."
|
||||
"auto and trigger mode (internal gating)."
|
||||
<< '\n';
|
||||
} else {
|
||||
os << "[n_value]\n\t[Mythen3] Exposure time of gate signal 3 in "
|
||||
"auto and "
|
||||
"trigger mode (internal gating)."
|
||||
"auto and trigger mode (internal gating)."
|
||||
<< '\n';
|
||||
}
|
||||
} else if (action == defs::GET_ACTION) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user