Source code for rsmxo.Implementations.Power.Soa.Mtest.Segment.Point.Valid

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


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

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

[docs] def get(self, power=repcap.Power.Default, maskTest=repcap.MaskTest.Default, segment=repcap.Segment.Default, point=repcap.Point.Default) -> bool: """ ``POWer<*>:SOA:MTESt<*>:SEGMent<*>:POINt<*>:VALid`` \n Snippet: ``value: bool = driver.power.soa.mtest.segment.point.valid.get(power = repcap.Power.Default, maskTest = repcap.MaskTest.Default, segment = repcap.Segment.Default, point = repcap.Point.Default)`` \n Checks the validity of the selected point. :param power: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Power') :param maskTest: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Mtest') :param segment: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Segment') :param point: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Point') :return: valid: ON = valid OFF = invalid """ power_cmd_val = self._cmd_group.get_repcap_cmd_value(power, repcap.Power) maskTest_cmd_val = self._cmd_group.get_repcap_cmd_value(maskTest, repcap.MaskTest) segment_cmd_val = self._cmd_group.get_repcap_cmd_value(segment, repcap.Segment) point_cmd_val = self._cmd_group.get_repcap_cmd_value(point, repcap.Point) response = self._core.io.query_str(f'POWer{power_cmd_val}:SOA:MTESt{maskTest_cmd_val}:SEGMent{segment_cmd_val}:POINt{point_cmd_val}:VALid?') return Conversions.str_to_bool(response)