Source code for RsFsw.Implementations.Applications.K70_Vsa.Sense.SwapIq

from .....Internal.Core import Core
from .....Internal.CommandsGroup import CommandsGroup
from .....Internal import Conversions


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

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

[docs] def set(self, state: bool) -> None: """ ``[SENSe]:SWAPiq`` \n Snippet: ``driver.applications.k70Vsa.sense.swapIq.set(state = False)`` \n Defines whether or not the recorded I/Q pairs should be swapped (I<->Q) before being processed. Swapping I and Q inverts the sideband. This is useful if the DUT interchanged the I and Q parts of the signal; then the FSW can do the same to compensate for it. For GSM measurements: Try this function if the TSC can not be found. :param state: ON | 1 I and Q signals are interchanged Inverted sideband, Q+j``*I`` OFF | 0 I and Q signals are not interchanged Normal sideband, I+j``*Q`` """ param = Conversions.bool_to_str(state) self._core.io.write(f'SENSe:SWAPiq {param}')
[docs] def get(self) -> bool: """ ``[SENSe]:SWAPiq`` \n Snippet: ``value: bool = driver.applications.k70Vsa.sense.swapIq.get()`` \n Defines whether or not the recorded I/Q pairs should be swapped (I<->Q) before being processed. Swapping I and Q inverts the sideband. This is useful if the DUT interchanged the I and Q parts of the signal; then the FSW can do the same to compensate for it. For GSM measurements: Try this function if the TSC can not be found. :return: state: ON | 1 I and Q signals are interchanged Inverted sideband, Q+j``*I`` OFF | 0 I and Q signals are not interchanged Normal sideband, I+j``*Q`` """ response = self._core.io.query_str(f'SENSe:SWAPiq?') return Conversions.str_to_bool(response)