Source code for rsrtx.Implementations.Search.Trigger.FlxRay.SyFrame

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
from ..... import enums


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

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

[docs] def set(self, search: str, sync_frame: enums.BusBitCondition) -> None: """ ``SEARch:TRIGger:FLXRay:SYFRame`` \n Snippet: ``driver.search.trigger.flxRay.syFrame.set(search = 'abc', sync_frame = enums.BusBitCondition.DC)`` \n Searches for the sync frame used for synchronization of the FlexRay system. Only sync nodes can send this frame type. :param sync_frame: Bit value: 1, 0, or X (don't care) """ param = ArgSingleList().compose_cmd_string(ArgSingle('search', search, DataType.String), ArgSingle('sync_frame', sync_frame, DataType.Enum, enums.BusBitCondition)) self._core.io.write(f'SEARch:TRIGger:FLXRay:SYFRame {param}'.rstrip())
# noinspection PyTypeChecker
[docs] def get(self, search: str) -> enums.BusBitCondition: """ ``SEARch:TRIGger:FLXRay:SYFRame`` \n Snippet: ``value: enums.BusBitCondition = driver.search.trigger.flxRay.syFrame.get(search = 'abc')`` \n Searches for the sync frame used for synchronization of the FlexRay system. Only sync nodes can send this frame type. :return: sync_frame: Bit value: 1, 0, or X (don't care) """ param = Conversions.value_to_quoted_str(search) response = self._core.io.query_str(f'SEARch:TRIGger:FLXRay:SYFRame? {param}') return Conversions.str_to_scalar_enum(response, enums.BusBitCondition)