from .....Internal.Core import Core
from .....Internal.CommandsGroup import CommandsGroup
from ..... import repcap
# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class HistogramCls:
"""
| Commands in total: 8
| Subgroups: 4
| Direct child commands: 1
"""
def __init__(self, core: Core, parent):
self._core = core
self._cmd_group = CommandsGroup("histogram", core, parent)
@property
def enable(self):
"""
| Commands in total: 1
| Subgroups: 0
| Direct child commands: 1
"""
if not hasattr(self, '_enable'):
from .Enable import EnableCls
self._enable = EnableCls(self._core, self._cmd_group)
return self._enable
@property
def hbIns(self):
"""
| Commands in total: 1
| Subgroups: 0
| Direct child commands: 1
"""
if not hasattr(self, '_hbIns'):
from .HbIns import HbInsCls
self._hbIns = HbInsCls(self._core, self._cmd_group)
return self._hbIns
@property
def autoScale(self):
"""
| Commands in total: 1
| Subgroups: 0
| Direct child commands: 1
"""
if not hasattr(self, '_autoScale'):
from .AutoScale import AutoScaleCls
self._autoScale = AutoScaleCls(self._core, self._cmd_group)
return self._autoScale
@property
def horizontal(self):
"""
| Commands in total: 4
| Subgroups: 4
| Direct child commands: 0
"""
if not hasattr(self, '_horizontal'):
from .Horizontal import HorizontalCls
self._horizontal = HorizontalCls(self._core, self._cmd_group)
return self._horizontal
[docs]
def reset(self, measIndex=repcap.MeasIndex.Default) -> None:
"""
``MEASurement<*>:STATistics:HISTogram:RESet`` \n
Snippet: ``driver.measurement.statistics.histogram.reset(measIndex = repcap.MeasIndex.Default)`` \n
Resets the cumulation of measurement results, all bins are set to zero.
:param measIndex: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Measurement')
"""
measIndex_cmd_val = self._cmd_group.get_repcap_cmd_value(measIndex, repcap.MeasIndex)
self._core.io.write(f'MEASurement{measIndex_cmd_val}:STATistics:HISTogram:RESet')
[docs]
def reset_and_wait(self, measIndex=repcap.MeasIndex.Default, opc_timeout_ms: int = -1) -> None:
measIndex_cmd_val = self._cmd_group.get_repcap_cmd_value(measIndex, repcap.MeasIndex)
"""
``MEASurement<*>:STATistics:HISTogram:RESet`` \n
Snippet: ``driver.measurement.statistics.histogram.reset_and_wait(measIndex = repcap.MeasIndex.Default)`` \n
Resets the cumulation of measurement results, all bins are set to zero.
Same as reset, but waits for the operation to complete before continuing further. Use the RsMxo.utilities.opc_timeout_set() to set the timeout value.
:param measIndex: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Measurement')
:param opc_timeout_ms: Maximum time to wait in milliseconds, valid only for this call.
"""
self._core.io.write_with_opc(f'MEASurement{measIndex_cmd_val}:STATistics:HISTogram:RESet', opc_timeout_ms)
def clone(self) -> 'HistogramCls':
"""
Clones the group by creating new object from it and its whole existing subgroups.
Also copies all the existing default Repeated Capabilities setting,
which you can change independently without affecting the original group.
"""
new_group = HistogramCls(self._core, self._cmd_group.parent)
self._cmd_group.synchronize_repcaps(new_group)
return new_group