Source code for RsSmw.Implementations.Source.Bb.Gnss.Stream.Output

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


# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class OutputCls:
	"""
	| Commands in total: 3
	| Subgroups: 2
	| Direct child commands: 1
	"""

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

	@property
	def bbmm(self):
		"""
		| Commands in total: 1
		| Subgroups: 1
		| Direct child commands: 0
		"""
		if not hasattr(self, '_bbmm'):
			from .Bbmm import BbmmCls
			self._bbmm = BbmmCls(self._core, self._cmd_group)
		return self._bbmm

	@property
	def rf(self):
		"""
		| Commands in total: 1
		| Subgroups: 1
		| Direct child commands: 0
		"""
		if not hasattr(self, '_rf'):
			from .Rf import RfCls
			self._rf = RfCls(self._core, self._cmd_group)
		return self._rf

[docs] def set(self, output: enums.Output, stream=repcap.Stream.Default) -> None: """ ``[SOURce<HW>]:BB:GNSS:STReam<ST>:OUTPut`` \n Snippet: ``driver.source.bb.gnss.stream.output.set(output = enums.Output.NONE, stream = repcap.Stream.Default)`` \n Sets the output connector to that the output GNSS signal is routed. :param output: RFA | RFB | NONE :param stream: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Stream') """ param = Conversions.enum_scalar_to_str(output, enums.Output) stream_cmd_val = self._cmd_group.get_repcap_cmd_value(stream, repcap.Stream) self._core.io.write(f'SOURce<HwInstance>:BB:GNSS:STReam{stream_cmd_val}:OUTPut {param}')
# noinspection PyTypeChecker
[docs] def get(self, stream=repcap.Stream.Default) -> enums.Output: """ ``[SOURce<HW>]:BB:GNSS:STReam<ST>:OUTPut`` \n Snippet: ``value: enums.Output = driver.source.bb.gnss.stream.output.get(stream = repcap.Stream.Default)`` \n Sets the output connector to that the output GNSS signal is routed. :param stream: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Stream') :return: output: RFA | RFB | NONE """ stream_cmd_val = self._cmd_group.get_repcap_cmd_value(stream, repcap.Stream) response = self._core.io.query_str(f'SOURce<HwInstance>:BB:GNSS:STReam{stream_cmd_val}:OUTPut?') return Conversions.str_to_scalar_enum(response, enums.Output)
def clone(self) -> 'OutputCls': """ Clones the group by creating new object from it and its whole existing subgroups. Also copies all the existing default Repeated Capabilities setting, which you can change independently without affecting the original group. """ new_group = OutputCls(self._core, self._cmd_group.parent) self._cmd_group.synchronize_repcaps(new_group) return new_group