Source code for rsmxo.Implementations.Acquire.Segmented

from ...Internal.Core import Core
from ...Internal.CommandsGroup import CommandsGroup
from ...Internal import Conversions


# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class SegmentedCls:
	"""
	| Commands in total: 2
	| Subgroups: 0
	| Direct child commands: 2
	"""

	def __init__(self, core: Core, parent):
		self._core = core
		self._cmd_group = CommandsGroup("segmented", core, parent)

[docs] def get_state(self) -> bool: """ ``ACQuire:SEGMented:STATe`` \n Snippet: ``value: bool = driver.acquire.segmented.get_state()`` \n If fast segmentation is enabled, the acquisitions are performed as fast as possible, without processing and displaying the waveforms. When acquisition has been stopped, the data is processed and the latest waveform is displayed. Older waveforms are stored in segments. You can display and analyze the segments using the history. :return: state: OFF | ON """ response = self._core.io.query_str('ACQuire:SEGMented:STATe?') return Conversions.str_to_bool(response)
[docs] def set_state(self, state: bool) -> None: """ ``ACQuire:SEGMented:STATe`` \n Snippet: ``driver.acquire.segmented.set_state(state = False)`` \n If fast segmentation is enabled, the acquisitions are performed as fast as possible, without processing and displaying the waveforms. When acquisition has been stopped, the data is processed and the latest waveform is displayed. Older waveforms are stored in segments. You can display and analyze the segments using the history. :param state: OFF | ON """ param = Conversions.bool_to_str(state) self._core.io.write(f'ACQuire:SEGMented:STATe {param}')
[docs] def get_max(self) -> bool: """ ``ACQuire:SEGMented:MAX`` \n Snippet: ``value: bool = driver.acquire.segmented.get_max()`` \n If ON, the instrument acquires the maximum number of segments that can be stored in the memory. The maximum number depends on the current sample rate and record length settings. If OFF, define the number of segments in a fast segmentation cycle with method ``RsMxo.acquire.count()`` . :return: max_acqs: OFF | ON """ response = self._core.io.query_str('ACQuire:SEGMented:MAX?') return Conversions.str_to_bool(response)
[docs] def set_max(self, max_acqs: bool) -> None: """ ``ACQuire:SEGMented:MAX`` \n Snippet: ``driver.acquire.segmented.set_max(max_acqs = False)`` \n If ON, the instrument acquires the maximum number of segments that can be stored in the memory. The maximum number depends on the current sample rate and record length settings. If OFF, define the number of segments in a fast segmentation cycle with method ``RsMxo.acquire.count()`` . :param max_acqs: OFF | ON """ param = Conversions.bool_to_str(max_acqs) self._core.io.write(f'ACQuire:SEGMented:MAX {param}')