Source code for RsFsw.Implementations.Applications.K14x_Nr5G.Sense.Espectrum.Range.Limit.Relative.Stop.Function

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


# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
[docs]class FunctionCls: """Function commands group definition. 1 total commands, 0 Subgroups, 1 group commands""" def __init__(self, core: Core, parent): self._core = core self._cmd_group = CommandsGroup("function", core, parent)
[docs] def set(self, function: enums.FunctionA, subBlock=repcap.SubBlock.Default, rangePy=repcap.RangePy.Default, limitIx=repcap.LimitIx.Default) -> None: """SCPI: [SENSe]:ESPectrum<sb>:RANGe<range>:LIMit<li>:RELative:STOP:FUNCtion \n Snippet: driver.applications.k14Xnr5G.sense.espectrum.range.limit.relative.stop.function.set(function = enums.FunctionA.MAX, subBlock = repcap.SubBlock.Default, rangePy = repcap.RangePy.Default, limitIx = repcap.LimitIx.Default) \n Enables the use of a function when defining the relative limit for a SEM range. \n :param function: OFF | MAX Defines the function to be used to determine the relative limit line stop value MAX The maximum of the relative and the absolute level is used as the limit stop value. Use the [SENSe:]ESPectrumsb:RANGeri:LIMitli:RELative:STOP and [SENSe:]ESPectrumsb:RANGeri:LIMitli:RELative:STOP:ABS commands to define these values. OFF No function is used, the relative limit line is defined by a fixed relative stop value. Use the [SENSe:]ESPectrumsb:RANGeri:LIMitli:RELative:STOP command to define this value. :param subBlock: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Espectrum') :param rangePy: optional repeated capability selector. Default value: Ix1 (settable in the interface 'Range') :param limitIx: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Limit') """ param = Conversions.enum_scalar_to_str(function, enums.FunctionA) subBlock_cmd_val = self._cmd_group.get_repcap_cmd_value(subBlock, repcap.SubBlock) rangePy_cmd_val = self._cmd_group.get_repcap_cmd_value(rangePy, repcap.RangePy) limitIx_cmd_val = self._cmd_group.get_repcap_cmd_value(limitIx, repcap.LimitIx) self._core.io.write(f'SENSe:ESPectrum{subBlock_cmd_val}:RANGe{rangePy_cmd_val}:LIMit{limitIx_cmd_val}:RELative:STOP:FUNCtion {param}')
# noinspection PyTypeChecker
[docs] def get(self, subBlock=repcap.SubBlock.Default, rangePy=repcap.RangePy.Default, limitIx=repcap.LimitIx.Default) -> enums.FunctionA: """SCPI: [SENSe]:ESPectrum<sb>:RANGe<range>:LIMit<li>:RELative:STOP:FUNCtion \n Snippet: value: enums.FunctionA = driver.applications.k14Xnr5G.sense.espectrum.range.limit.relative.stop.function.get(subBlock = repcap.SubBlock.Default, rangePy = repcap.RangePy.Default, limitIx = repcap.LimitIx.Default) \n Enables the use of a function when defining the relative limit for a SEM range. \n :param subBlock: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Espectrum') :param rangePy: optional repeated capability selector. Default value: Ix1 (settable in the interface 'Range') :param limitIx: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Limit') :return: function: OFF | MAX Defines the function to be used to determine the relative limit line stop value MAX The maximum of the relative and the absolute level is used as the limit stop value. Use the [SENSe:]ESPectrumsb:RANGeri:LIMitli:RELative:STOP and [SENSe:]ESPectrumsb:RANGeri:LIMitli:RELative:STOP:ABS commands to define these values. OFF No function is used, the relative limit line is defined by a fixed relative stop value. Use the [SENSe:]ESPectrumsb:RANGeri:LIMitli:RELative:STOP command to define this value.""" subBlock_cmd_val = self._cmd_group.get_repcap_cmd_value(subBlock, repcap.SubBlock) rangePy_cmd_val = self._cmd_group.get_repcap_cmd_value(rangePy, repcap.RangePy) limitIx_cmd_val = self._cmd_group.get_repcap_cmd_value(limitIx, repcap.LimitIx) response = self._core.io.query_str(f'SENSe:ESPectrum{subBlock_cmd_val}:RANGe{rangePy_cmd_val}:LIMit{limitIx_cmd_val}:RELative:STOP:FUNCtion?') return Conversions.str_to_scalar_enum(response, enums.FunctionA)