Source code for rsrtx.Implementations.Timebase.Horizontal

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


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

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

[docs] def get_position(self) -> float: """ ``TIMebase:HORizontal:POSition`` \n Snippet: ``value: float = driver.timebase.horizontal.get_position()`` \n Defines the time distance between the reference point and the trigger point (the zero point of the diagram) . The reference point marks the rescaling center of the time scale. """ response = self._core.io.query_str_with_opc('TIMebase:HORizontal:POSition?') return Conversions.str_to_float(response)
[docs] def set_position(self, rescale_ctr_time: float) -> None: """ ``TIMebase:HORizontal:POSition`` \n Snippet: ``driver.timebase.horizontal.set_position(rescale_ctr_time = 1.0)`` \n Defines the time distance between the reference point and the trigger point (the zero point of the diagram) . The reference point marks the rescaling center of the time scale. :param rescale_ctr_time: -100E+24 to 100E+24 """ param = Conversions.decimal_value_to_str(rescale_ctr_time) self._core.io.write_with_opc(f'TIMebase:HORizontal:POSition {param}')