from ....Internal.Core import Core
from ....Internal.CommandsGroup import CommandsGroup
from ....Internal import Conversions
from .... import enums
# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class PhaseCls:
"""
| Commands in total: 1
| Subgroups: 0
| Direct child commands: 1
"""
def __init__(self, core: Core, parent):
self._core = core
self._cmd_group = CommandsGroup("phase", core, parent)
# noinspection PyTypeChecker
[docs]
def get_unit(self) -> enums.UnitAngle:
"""
``[SOURce<HW>]:CEMulation:PHASe:UNIT`` \n
Snippet: ``value: enums.UnitAngle = driver.source.cemulation.phase.get_unit()`` \n
No help available
"""
response = self._core.io.query_str('SOURce<HwInstance>:CEMulation:PHASe:UNIT?')
return Conversions.str_to_scalar_enum(response, enums.UnitAngle)
[docs]
def set_unit(self, fad_angle_unit: enums.UnitAngle) -> None:
"""
``[SOURce<HW>]:CEMulation:PHASe:UNIT`` \n
Snippet: ``driver.source.cemulation.phase.set_unit(fad_angle_unit = enums.UnitAngle.DEGree)`` \n
No help available
"""
param = Conversions.enum_scalar_to_str(fad_angle_unit, enums.UnitAngle)
self._core.io.write(f'SOURce<HwInstance>:CEMulation:PHASe:UNIT {param}')