Source code for RsSmbv.Implementations.Source.Iq.Output.Digital.Power

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


# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class PowerCls:
	"""
	| Commands in total: 6
	| Subgroups: 1
	| Direct child commands: 4
	"""

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

	@property
	def step(self):
		"""
		| Commands in total: 2
		| Subgroups: 0
		| Direct child commands: 2
		"""
		if not hasattr(self, '_step'):
			from .Step import StepCls
			self._step = StepCls(self._core, self._cmd_group)
		return self._step

[docs] def get_level(self) -> float: """ ``[SOURce<HW>]:IQ:OUTPut:DIGital:POWer:LEVel`` \n Snippet: ``value: float = driver.source.iq.output.digital.power.get_level()`` \n Sets the RMS level of digital I/Q output signal or of the channel of the HS digital I/Q output signal. The level is relative to full scale of 0.5 V (in terms of dB full scale) . """ response = self._core.io.query_str('SOURce<HwInstance>:IQ:OUTPut:DIGital:POWer:LEVel?') return Conversions.str_to_float(response)
[docs] def set_level(self, level: float) -> None: """ ``[SOURce<HW>]:IQ:OUTPut:DIGital:POWer:LEVel`` \n Snippet: ``driver.source.iq.output.digital.power.set_level(level = 1.0)`` \n Sets the RMS level of digital I/Q output signal or of the channel of the HS digital I/Q output signal. The level is relative to full scale of 0.5 V (in terms of dB full scale) . :param level: float Range: -60 to 0 """ param = Conversions.decimal_value_to_str(level) self._core.io.write(f'SOURce<HwInstance>:IQ:OUTPut:DIGital:POWer:LEVel {param}')
[docs] def get_pep(self) -> float: """ ``[SOURce<HW>]:IQ:OUTPut:DIGital:POWer:PEP`` \n Snippet: ``value: float = driver.source.iq.output.digital.power.get_pep()`` \n Sets the peak level of digital I/Q output signal or of the channel of the HS digital I/Q output signal. The level is relative to full scale of 0.5 V (in terms of dB full scale) . """ response = self._core.io.query_str('SOURce<HwInstance>:IQ:OUTPut:DIGital:POWer:PEP?') return Conversions.str_to_float(response)
[docs] def set_pep(self, pep: float) -> None: """ ``[SOURce<HW>]:IQ:OUTPut:DIGital:POWer:PEP`` \n Snippet: ``driver.source.iq.output.digital.power.set_pep(pep = 1.0)`` \n Sets the peak level of digital I/Q output signal or of the channel of the HS digital I/Q output signal. The level is relative to full scale of 0.5 V (in terms of dB full scale) . :param pep: float Range: -60 to 0 """ param = Conversions.decimal_value_to_str(pep) self._core.io.write(f'SOURce<HwInstance>:IQ:OUTPut:DIGital:POWer:PEP {param}')
[docs] def get_state(self) -> bool: """ ``[SOURce]:IQ:OUTPut:DIGital:POWer:STATe`` \n Snippet: ``value: bool = driver.source.iq.output.digital.power.get_state()`` \n No help available """ response = self._core.io.query_str('SOURce:IQ:OUTPut:DIGital:POWer:STATe?') return Conversions.str_to_bool(response)
[docs] def set_state(self, state: bool) -> None: """ ``[SOURce]:IQ:OUTPut:DIGital:POWer:STATe`` \n Snippet: ``driver.source.iq.output.digital.power.set_state(state = False)`` \n No help available """ param = Conversions.bool_to_str(state) self._core.io.write(f'SOURce:IQ:OUTPut:DIGital:POWer:STATe {param}')
# noinspection PyTypeChecker
[docs] def get_via(self) -> enums.IqOutDispViaType: """ ``[SOURce]:IQ:OUTPut:DIGital:POWer:VIA`` \n Snippet: ``value: enums.IqOutDispViaType = driver.source.iq.output.digital.power.get_via()`` \n Selects the respective level entry field for the I/Q output. :return: via: PEP | LEVel """ response = self._core.io.query_str('SOURce:IQ:OUTPut:DIGital:POWer:VIA?') return Conversions.str_to_scalar_enum(response, enums.IqOutDispViaType)
[docs] def set_via(self, via: enums.IqOutDispViaType) -> None: """ ``[SOURce]:IQ:OUTPut:DIGital:POWer:VIA`` \n Snippet: ``driver.source.iq.output.digital.power.set_via(via = enums.IqOutDispViaType.LEVel)`` \n Selects the respective level entry field for the I/Q output. :param via: PEP | LEVel """ param = Conversions.enum_scalar_to_str(via, enums.IqOutDispViaType) self._core.io.write(f'SOURce:IQ:OUTPut:DIGital:POWer:VIA {param}')
def clone(self) -> 'PowerCls': """ 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 = PowerCls(self._core, self._cmd_group.parent) self._cmd_group.synchronize_repcaps(new_group) return new_group