from ...Internal.Core import Core
from ...Internal.CommandsGroup import CommandsGroup
from ...Internal import Conversions
from ... import enums
# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class OutputCls:
"""
| Commands in total: 1
| Subgroups: 0
| Direct child commands: 1
"""
def __init__(self, core: Core, parent):
self._core = core
self._cmd_group = CommandsGroup("output", core, parent)
# noinspection PyTypeChecker
[docs]
def get_source(self) -> enums.AnalogChannels:
"""
``FRANalysis:OUTPut[:SOURce]`` \n
Snippet: ``value: enums.AnalogChannels = driver.franalysis.output.get_source()`` \n
Sets the channel for the output signal of the DUT.
:return: output_channel: C1 | C2 | ... | C8
"""
response = self._core.io.query_str('FRANalysis:OUTPut:SOURce?')
return Conversions.str_to_scalar_enum(response, enums.AnalogChannels)
[docs]
def set_source(self, output_channel: enums.AnalogChannels) -> None:
"""
``FRANalysis:OUTPut[:SOURce]`` \n
Snippet: ``driver.franalysis.output.set_source(output_channel = enums.AnalogChannels.C1)`` \n
Sets the channel for the output signal of the DUT.
:param output_channel: C1 | C2 | ... | C8
"""
param = Conversions.enum_scalar_to_str(output_channel, enums.AnalogChannels)
self._core.io.write(f'FRANalysis:OUTPut:SOURce {param}')