Source code for rsrtx.Implementations.Search.Trigger.Can.Fdata.Standard

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 StandardCls:
	"""
	| Commands in total: 1
	| Subgroups: 0
	| Direct child commands: 1
	"""

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

[docs] def set(self, search: str, std_sel: enums.BusCanStandard) -> None: """ ``SEARch:TRIGger:CAN:FDATa:STANdard`` \n Snippet: ``driver.search.trigger.can.fdata.standard.set(search = 'abc', std_sel = enums.BusCanStandard.ANY)`` \n Selects the CAN standard: CAN, CAN FD, or Any. Use Any to search on either CAN or CAN-FD frame. In this case, the search configuration provides all possible settings, for CAN as well as for CAN FD. The setting is available in CAN FD option R&S RTP-K9. :param search: ANY | CAN | CANFd :param std_sel: String with the search name """ param = ArgSingleList().compose_cmd_string(ArgSingle('search', search, DataType.String), ArgSingle('std_sel', std_sel, DataType.Enum, enums.BusCanStandard)) self._core.io.write(f'SEARch:TRIGger:CAN:FDATa:STANdard {param}'.rstrip())
# noinspection PyTypeChecker
[docs] def get(self, search: str) -> enums.BusCanStandard: """ ``SEARch:TRIGger:CAN:FDATa:STANdard`` \n Snippet: ``value: enums.BusCanStandard = driver.search.trigger.can.fdata.standard.get(search = 'abc')`` \n Selects the CAN standard: CAN, CAN FD, or Any. Use Any to search on either CAN or CAN-FD frame. In this case, the search configuration provides all possible settings, for CAN as well as for CAN FD. The setting is available in CAN FD option R&S RTP-K9. :param search: ANY | CAN | CANFd """ param = Conversions.value_to_quoted_str(search) response = self._core.io.query_str(f'SEARch:TRIGger:CAN:FDATa:STANdard? {param}') return Conversions.str_to_scalar_enum(response, enums.BusCanStandard)