Source code for RsCMPX_Gprf.Implementations.Gprf.Measurement.Power.StandardDev

from typing import List

from ......Internal.Core import Core
from ......Internal.CommandsGroup import CommandsGroup
from ......Internal import Conversions
from ......Internal.ArgSingleSuppressed import ArgSingleSuppressed
from ......Internal.Types import DataType
from ...... import enums


# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
[docs] class StandardDevCls: """StandardDev commands group definition. 5 total commands, 1 Subgroups, 3 group commands""" def __init__(self, core: Core, parent): self._core = core self._cmd_group = CommandsGroup("standardDev", core, parent) @property def current(self): """current commands group. 0 Sub-classes, 2 commands.""" if not hasattr(self, '_current'): from .Current import CurrentCls self._current = CurrentCls(self._core, self._cmd_group) return self._current # noinspection PyTypeChecker
[docs] def calculate(self) -> List[enums.ResultStatus2]: """SCPI: CALCulate:GPRF:MEASurement<Instance>:POWer:SDEViation \n Snippet: value: List[enums.ResultStatus2] = driver.gprf.measurement.power.standardDev.calculate() \n Returns power results for all segments, see 'Results in list mode'. INTRO_CMD_HELP: The following results can be retrieved: \n - Current RMS (...:POWer:CURRent?) - Current Min. (...:MINimum:CURRent?) - Current Max. (...:MAXimum:CURRent?) - Average RMS (...:AVERage?) - Minimum (...:PEAK:MINimum?) - Maximum (...:PEAK:MAXimum?) - Standard Deviation (...:SDEViation?) The values described below are returned by FETCh and READ commands. CALCulate commands return error codes instead, one value for each result listed below. \n Suppressed linked return values: reliability \n :return: power_std_dev_cur: Comma-separated list of power values, one value per measured segment""" suppressed = ArgSingleSuppressed(0, DataType.Integer, False, 1, 'Reliability') response = self._core.io.query_str_suppressed(f'CALCulate:GPRF:MEASurement<Instance>:POWer:SDEViation?', suppressed) return Conversions.str_to_list_enum(response, enums.ResultStatus2)
[docs] def fetch(self) -> List[float]: """SCPI: FETCh:GPRF:MEASurement<Instance>:POWer:SDEViation \n Snippet: value: List[float] = driver.gprf.measurement.power.standardDev.fetch() \n Returns power results for all segments, see 'Results in list mode'. INTRO_CMD_HELP: The following results can be retrieved: \n - Current RMS (...:POWer:CURRent?) - Current Min. (...:MINimum:CURRent?) - Current Max. (...:MAXimum:CURRent?) - Average RMS (...:AVERage?) - Minimum (...:PEAK:MINimum?) - Maximum (...:PEAK:MAXimum?) - Standard Deviation (...:SDEViation?) The values described below are returned by FETCh and READ commands. CALCulate commands return error codes instead, one value for each result listed below. \n Suppressed linked return values: reliability \n :return: power_std_dev_cur: Comma-separated list of power values, one value per measured segment""" suppressed = ArgSingleSuppressed(0, DataType.Integer, False, 1, 'Reliability') response = self._core.io.query_bin_or_ascii_float_list_suppressed(f'FETCh:GPRF:MEASurement<Instance>:POWer:SDEViation?', suppressed) return response
[docs] def read(self) -> List[float]: """SCPI: READ:GPRF:MEASurement<Instance>:POWer:SDEViation \n Snippet: value: List[float] = driver.gprf.measurement.power.standardDev.read() \n Returns power results for all segments, see 'Results in list mode'. INTRO_CMD_HELP: The following results can be retrieved: \n - Current RMS (...:POWer:CURRent?) - Current Min. (...:MINimum:CURRent?) - Current Max. (...:MAXimum:CURRent?) - Average RMS (...:AVERage?) - Minimum (...:PEAK:MINimum?) - Maximum (...:PEAK:MAXimum?) - Standard Deviation (...:SDEViation?) The values described below are returned by FETCh and READ commands. CALCulate commands return error codes instead, one value for each result listed below. \n Suppressed linked return values: reliability \n :return: power_std_dev_cur: Comma-separated list of power values, one value per measured segment""" suppressed = ArgSingleSuppressed(0, DataType.Integer, False, 1, 'Reliability') response = self._core.io.query_bin_or_ascii_float_list_suppressed(f'READ:GPRF:MEASurement<Instance>:POWer:SDEViation?', suppressed) return response
def clone(self) -> 'StandardDevCls': """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 = StandardDevCls(self._core, self._cmd_group.parent) self._cmd_group.synchronize_repcaps(new_group) return new_group