Source code for RsSmw.Implementations.Source.Bb.Esequencer

from .....Internal.Core import Core
from .....Internal.CommandsGroup import CommandsGroup
from .....Internal import Conversions
from .....Internal.Utilities import trim_str_response
from ..... import enums


# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class EsequencerCls:
	"""
	| Commands in total: 147
	| Subgroups: 14
	| Direct child commands: 6
	"""

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

	@property
	def archive(self):
		"""
		| Commands in total: 3
		| Subgroups: 0
		| Direct child commands: 3
		"""
		if not hasattr(self, '_archive'):
			from .Archive import ArchiveCls
			self._archive = ArchiveCls(self._core, self._cmd_group)
		return self._archive

	@property
	def asequencing(self):
		"""
		| Commands in total: 17
		| Subgroups: 4
		| Direct child commands: 1
		"""
		if not hasattr(self, '_asequencing'):
			from .Asequencing import AsequencingCls
			self._asequencing = AsequencingCls(self._core, self._cmd_group)
		return self._asequencing

	@property
	def clock(self):
		"""
		| Commands in total: 3
		| Subgroups: 0
		| Direct child commands: 3
		"""
		if not hasattr(self, '_clock'):
			from .Clock import ClockCls
			self._clock = ClockCls(self._core, self._cmd_group)
		return self._clock

	@property
	def dfinding(self):
		"""
		| Commands in total: 9
		| Subgroups: 3
		| Direct child commands: 0
		"""
		if not hasattr(self, '_dfinding'):
			from .Dfinding import DfindingCls
			self._dfinding = DfindingCls(self._core, self._cmd_group)
		return self._dfinding

	@property
	def estreaming(self):
		"""
		| Commands in total: 19
		| Subgroups: 3
		| Direct child commands: 2
		"""
		if not hasattr(self, '_estreaming'):
			from .Estreaming import EstreamingCls
			self._estreaming = EstreamingCls(self._core, self._cmd_group)
		return self._estreaming

	@property
	def playback(self):
		"""
		| Commands in total: 9
		| Subgroups: 3
		| Direct child commands: 0
		"""
		if not hasattr(self, '_playback'):
			from .Playback import PlaybackCls
			self._playback = PlaybackCls(self._core, self._cmd_group)
		return self._playback

	@property
	def pramp(self):
		"""
		| Commands in total: 1
		| Subgroups: 0
		| Direct child commands: 1
		"""
		if not hasattr(self, '_pramp'):
			from .Pramp import PrampCls
			self._pramp = PrampCls(self._core, self._cmd_group)
		return self._pramp

	@property
	def psequencer(self):
		"""
		| Commands in total: 9
		| Subgroups: 3
		| Direct child commands: 0
		"""
		if not hasattr(self, '_psequencer'):
			from .Psequencer import PsequencerCls
			self._psequencer = PsequencerCls(self._core, self._cmd_group)
		return self._psequencer

	@property
	def rtci(self):
		"""
		| Commands in total: 26
		| Subgroups: 3
		| Direct child commands: 2
		"""
		if not hasattr(self, '_rtci'):
			from .Rtci import RtciCls
			self._rtci = RtciCls(self._core, self._cmd_group)
		return self._rtci

	@property
	def sequencer(self):
		"""
		| Commands in total: 5
		| Subgroups: 5
		| Direct child commands: 0
		"""
		if not hasattr(self, '_sequencer'):
			from .Sequencer import SequencerCls
			self._sequencer = SequencerCls(self._core, self._cmd_group)
		return self._sequencer

	@property
	def setting(self):
		"""
		| Commands in total: 4
		| Subgroups: 0
		| Direct child commands: 4
		"""
		if not hasattr(self, '_setting'):
			from .Setting import SettingCls
			self._setting = SettingCls(self._core, self._cmd_group)
		return self._setting

	@property
	def stream(self):
		"""
		| Commands in total: 4
		| Subgroups: 4
		| Direct child commands: 0
		"""
		if not hasattr(self, '_stream'):
			from .Stream import StreamCls
			self._stream = StreamCls(self._core, self._cmd_group)
		return self._stream

	@property
	def trigger(self):
		"""
		| Commands in total: 24
		| Subgroups: 7
		| Direct child commands: 3
		"""
		if not hasattr(self, '_trigger'):
			from .Trigger import TriggerCls
			self._trigger = TriggerCls(self._core, self._cmd_group)
		return self._trigger

	@property
	def user(self):
		"""
		| Commands in total: 8
		| Subgroups: 4
		| Direct child commands: 0
		"""
		if not hasattr(self, '_user'):
			from .User import UserCls
			self._user = UserCls(self._core, self._cmd_group)
		return self._user

[docs] def get_error(self) -> str: """ ``[SOURce<HW>]:BB:ESEQuencer:ERRor`` \n Snippet: ``value: str = driver.source.bb.esequencer.get_error()`` \n Queries detected xml format errors. :return: error: string """ response = self._core.io.query_str('SOURce<HwInstance>:BB:ESEQuencer:ERRor?') return trim_str_response(response)
# noinspection PyTypeChecker
[docs] def get_mode(self) -> enums.ExtSeqMode: """ ``[SOURce<HW>]:BB:ESEQuencer:MODE`` \n Snippet: ``value: enums.ExtSeqMode = driver.source.bb.esequencer.get_mode()`` \n Selects the processing mode for the extended sequencer. :return: mode: USER | PSEQuencer | DFINding | RTCI | ASEQuencing | PLAYback | ESTReaming USER Processes user defined extended sequences. PSEQuencer Processes files created with the signal generation software R&S Pulse Sequencer. DFINding Processes files containing sequences with extended direction finding of the antennas. The files are created with the signal generation software R&S Pulse Sequencer. RTCI Processes files containing sequences of precalculated waveform. ASEQuencing Processes prestored ARB segments. PLAYback Processes user written PDW files. ESTReaming Processes I/Q data streams from an external source, which can be modified via ODW. """ response = self._core.io.query_str('SOURce<HwInstance>:BB:ESEQuencer:MODE?') return Conversions.str_to_scalar_enum(response, enums.ExtSeqMode)
[docs] def set_mode(self, mode: enums.ExtSeqMode) -> None: """ ``[SOURce<HW>]:BB:ESEQuencer:MODE`` \n Snippet: ``driver.source.bb.esequencer.set_mode(mode = enums.ExtSeqMode.ASEQuencing)`` \n Selects the processing mode for the extended sequencer. :param mode: USER | PSEQuencer | DFINding | RTCI | ASEQuencing | PLAYback | ESTReaming USER Processes user defined extended sequences. PSEQuencer Processes files created with the signal generation software R&S Pulse Sequencer. DFINding Processes files containing sequences with extended direction finding of the antennas. The files are created with the signal generation software R&S Pulse Sequencer. RTCI Processes files containing sequences of precalculated waveform. ASEQuencing Processes prestored ARB segments. PLAYback Processes user written PDW files. ESTReaming Processes I/Q data streams from an external source, which can be modified via ODW. """ param = Conversions.enum_scalar_to_str(mode, enums.ExtSeqMode) self._core.io.write(f'SOURce<HwInstance>:BB:ESEQuencer:MODE {param}')
[docs] def preset(self) -> None: """ ``[SOURce<HW>]:BB:ESEQuencer:PRESet`` \n Snippet: ``driver.source.bb.esequencer.preset()`` \n Sets all the parameters of the extended sequencer to their default values (``*RST`` values specified for the commands) . Not affected is the state set with the method ``RsSmw.source.bb.esequencer.state()`` . """ self._core.io.write(f'SOURce<HwInstance>:BB:ESEQuencer:PRESet')
[docs] def preset_with_opc(self, opc_timeout_ms: int = -1) -> None: """ ``[SOURce<HW>]:BB:ESEQuencer:PRESet`` \n Snippet: ``driver.source.bb.esequencer.preset_with_opc()`` \n Sets all the parameters of the extended sequencer to their default values (``*RST`` values specified for the commands) . Not affected is the state set with the method ``RsSmw.source.bb.esequencer.state()`` . Same as preset, but waits for the operation to complete before continuing further. Use the RsSmw.utilities.opc_timeout_set() to set the timeout value. :param opc_timeout_ms: Maximum time to wait in milliseconds, valid only for this call. """ self._core.io.write_with_opc(f'SOURce<HwInstance>:BB:ESEQuencer:PRESet', opc_timeout_ms)
[docs] def get_seq_count(self) -> int: """ ``[SOURce<HW>]:BB:ESEQuencer:SEQCount`` \n Snippet: ``value: int = driver.source.bb.esequencer.get_seq_count()`` \n Queries the number of sequencers. :return: numb_of_sequencer: integer Number of available sequencers depends on the installed options. Range: 1 to 6 """ response = self._core.io.query_str('SOURce<HwInstance>:BB:ESEQuencer:SEQCount?') return Conversions.str_to_int(response)
[docs] def get_state(self) -> bool: """ ``[SOURce<HW>]:BB:ESEQuencer:STATe`` \n Snippet: ``value: bool = driver.source.bb.esequencer.get_state()`` \n Activates signal generation, and deactivates all digital standards, digital modulation modes and other sweeps in the corresponding path. :return: state: 1 | ON | 0| OFF """ response = self._core.io.query_str('SOURce<HwInstance>:BB:ESEQuencer:STATe?') return Conversions.str_to_bool(response)
[docs] def set_state(self, state: bool) -> None: """ ``[SOURce<HW>]:BB:ESEQuencer:STATe`` \n Snippet: ``driver.source.bb.esequencer.set_state(state = False)`` \n Activates signal generation, and deactivates all digital standards, digital modulation modes and other sweeps in the corresponding path. :param state: 1 | ON | 0| OFF """ param = Conversions.bool_to_str(state) self._core.io.write(f'SOURce<HwInstance>:BB:ESEQuencer:STATe {param}')
[docs] def get_str_count(self) -> int: """ ``[SOURce<HW>]:BB:ESEQuencer:STRCount`` \n Snippet: ``value: int = driver.source.bb.esequencer.get_str_count()`` \n Queries the number of streams. :return: numb_of_streams: integer Range: 2 to 2 """ response = self._core.io.query_str('SOURce<HwInstance>:BB:ESEQuencer:STRCount?') return Conversions.str_to_int(response)
[docs] def set_str_count(self, numb_of_streams: int) -> None: """ ``[SOURce<HW>]:BB:ESEQuencer:STRCount`` \n Snippet: ``driver.source.bb.esequencer.set_str_count(numb_of_streams = 1)`` \n Queries the number of streams. :param numb_of_streams: integer Range: 2 to 2 """ param = Conversions.decimal_value_to_str(numb_of_streams) self._core.io.write(f'SOURce<HwInstance>:BB:ESEQuencer:STRCount {param}')
def clone(self) -> 'EsequencerCls': """ 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 = EsequencerCls(self._core, self._cmd_group.parent) self._cmd_group.synchronize_repcaps(new_group) return new_group