Source code for rsrtx.Implementations.Lane

from ...Internal.Core import Core
from ...Internal.CommandsGroup import CommandsGroup
from ...Internal.RepeatedCapability import RepeatedCapability
from ... import repcap


# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class LaneCls:
	"""
	| Commands in total: 116
	| Subgroups: 10
	| Direct child commands: 3

	Repeated Capability Setting:
	
	.. code-block:: python
	
			# Range: Nr1 .. Nr4 \n
			driver.lane.repcap_lane_set(repcap.Lane.Nr1)
	"""

	def __init__(self, core: Core, parent):
		self._core = core
		self._cmd_group = CommandsGroup("lane", core, parent)
		self._cmd_group.rep_cap = RepeatedCapability(self._cmd_group.group_name, 'repcap_lane_get', 'repcap_lane_set', repcap.Lane.Nr1)

	def repcap_lane_set(self, lane: repcap.Lane) -> None:
		"""
		Repeated Capability default value numeric suffix.
		This value is used, if you do not explicitely set it in the child set/get methods, or if you leave it to Lane.Default.
		Default value after init: Lane.Nr1
		"""
		self._cmd_group.set_repcap_enum_value(lane)

	def repcap_lane_get(self) -> repcap.Lane:
		"""
		Returns the current default repeated capability for the child set/get methods.
		"""
		# noinspection PyTypeChecker
		return self._cmd_group.get_repcap_enum_value()

	@property
	def state(self):
		"""
		| Commands in total: 1
		| Subgroups: 0
		| Direct child commands: 1
		"""
		if not hasattr(self, '_state'):
			from .State import StateCls
			self._state = StateCls(self._core, self._cmd_group)
		return self._state

	@property
	def cmpo(self):
		"""
		| Commands in total: 1
		| Subgroups: 0
		| Direct child commands: 1
		"""
		if not hasattr(self, '_cmpo'):
			from .Cmpo import CmpoCls
			self._cmpo = CmpoCls(self._core, self._cmd_group)
		return self._cmpo

	@property
	def source(self):
		"""
		| Commands in total: 1
		| Subgroups: 0
		| Direct child commands: 1
		"""
		if not hasattr(self, '_source'):
			from .Source import SourceCls
			self._source = SourceCls(self._core, self._cmd_group)
		return self._source

	@property
	def symRate(self):
		"""
		| Commands in total: 1
		| Subgroups: 0
		| Direct child commands: 1
		"""
		if not hasattr(self, '_symRate'):
			from .SymRate import SymRateCls
			self._symRate = SymRateCls(self._core, self._cmd_group)
		return self._symRate

	@property
	def name(self):
		"""
		| Commands in total: 1
		| Subgroups: 0
		| Direct child commands: 1
		"""
		if not hasattr(self, '_name'):
			from .Name import NameCls
			self._name = NameCls(self._core, self._cmd_group)
		return self._name

	@property
	def vertical(self):
		"""
		| Commands in total: 4
		| Subgroups: 4
		| Direct child commands: 0
		"""
		if not hasattr(self, '_vertical'):
			from .Vertical import VerticalCls
			self._vertical = VerticalCls(self._core, self._cmd_group)
		return self._vertical

	@property
	def comFilter(self):
		"""
		| Commands in total: 3
		| Subgroups: 1
		| Direct child commands: 0
		"""
		if not hasattr(self, '_comFilter'):
			from .ComFilter import ComFilterCls
			self._comFilter = ComFilterCls(self._core, self._cmd_group)
		return self._comFilter

	@property
	def tffe(self):
		"""
		| Commands in total: 6
		| Subgroups: 4
		| Direct child commands: 0
		"""
		if not hasattr(self, '_tffe'):
			from .Tffe import TffeCls
			self._tffe = TffeCls(self._core, self._cmd_group)
		return self._tffe

	@property
	def equalization(self):
		"""
		| Commands in total: 68
		| Subgroups: 6
		| Direct child commands: 3
		"""
		if not hasattr(self, '_equalization'):
			from .Equalization import EqualizationCls
			self._equalization = EqualizationCls(self._core, self._cmd_group)
		return self._equalization

	@property
	def embedding(self):
		"""
		| Commands in total: 27
		| Subgroups: 10
		| Direct child commands: 3
		"""
		if not hasattr(self, '_embedding'):
			from .Embedding import EmbeddingCls
			self._embedding = EmbeddingCls(self._core, self._cmd_group)
		return self._embedding

[docs] def preset(self, lane=repcap.Lane.Default, opc_timeout_ms: int = -1) -> None: """ ``LANE<*>:PRESet`` \n Snippet: ``driver.lane.preset(lane = repcap.Lane.Default)`` \n Presets the equalization lane. :param lane: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Lane') :param opc_timeout_ms: Maximum time to wait in milliseconds, valid only for this call. """ lane_cmd_val = self._cmd_group.get_repcap_cmd_value(lane, repcap.Lane) self._core.io.write_with_opc(f'LANE{lane_cmd_val}:PRESet', opc_timeout_ms)
[docs] def save(self, lane=repcap.Lane.Default, opc_timeout_ms: int = -1) -> None: """ ``LANE<*>:SAVE`` \n Snippet: ``driver.lane.save(lane = repcap.Lane.Default)`` \n Saves the embedding configuration to the file specified with method ``RsRtx.lane.name.set()`` . :param lane: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Lane') :param opc_timeout_ms: Maximum time to wait in milliseconds, valid only for this call. """ lane_cmd_val = self._cmd_group.get_repcap_cmd_value(lane, repcap.Lane) self._core.io.write_with_opc(f'LANE{lane_cmd_val}:SAVE', opc_timeout_ms)
[docs] def open(self, lane=repcap.Lane.Default, opc_timeout_ms: int = -1) -> None: """ ``LANE<*>:OPEN`` \n Snippet: ``driver.lane.open(lane = repcap.Lane.Default)`` \n Opens and loads the lane configuration from the file specified with method ``RsRtx.lane.save()`` . :param lane: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Lane') :param opc_timeout_ms: Maximum time to wait in milliseconds, valid only for this call. """ lane_cmd_val = self._cmd_group.get_repcap_cmd_value(lane, repcap.Lane) self._core.io.write_with_opc(f'LANE{lane_cmd_val}:OPEN', opc_timeout_ms)
def clone(self) -> 'LaneCls': """ 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 = LaneCls(self._core, self._cmd_group.parent) self._cmd_group.synchronize_repcaps(new_group) return new_group