Source code for rsrtx.Implementations.Search.Trigger.Rffe.Interrupt

from .....Internal.Core import Core
from .....Internal.CommandsGroup import CommandsGroup
from .....Internal import Conversions
from .....Internal.Types import DataType
from .....Internal.ArgSingleList import ArgSingleList
from .....Internal.ArgSingle import ArgSingle


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

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

[docs] def set(self, search: str, interrupt: int) -> None: """ ``SEARch:TRIGger:RFFE:INTerrupt`` \n Snippet: ``driver.search.trigger.rffe.interrupt.set(search = 'abc', interrupt = 1)`` \n Defines the pattern of the interrrupt identification sequence, which consists of interrupt slots 15 to 0. :param search: String parameter :param interrupt: Numeric or string pattern, see 'Bit pattern parameter'. The string parameter accepts the bit value X (don't care) . """ param = ArgSingleList().compose_cmd_string(ArgSingle('search', search, DataType.String), ArgSingle('interrupt', interrupt, DataType.Integer)) self._core.io.write(f'SEARch:TRIGger:RFFE:INTerrupt {param}'.rstrip())
[docs] def get(self, search: str) -> int: """ ``SEARch:TRIGger:RFFE:INTerrupt`` \n Snippet: ``value: int = driver.search.trigger.rffe.interrupt.get(search = 'abc')`` \n Defines the pattern of the interrrupt identification sequence, which consists of interrupt slots 15 to 0. :param search: String parameter :return: interrupt: Numeric or string pattern, see 'Bit pattern parameter'. The string parameter accepts the bit value X (don't care) . """ param = Conversions.value_to_quoted_str(search) response = self._core.io.query_str(f'SEARch:TRIGger:RFFE:INTerrupt? {param}') return Conversions.str_to_int(response)