[docs]classUnitCls:"""Unit commands group definition. 3 total commands, 0 Subgroups, 3 group commands"""def__init__(self,core:Core,parent):self._core=coreself._cmd_group=CommandsGroup("unit",core,parent)# noinspection PyTypeChecker
[docs]defget_angle(self)->enums.UnitAngle:"""SCPI: UNIT:ANGLe \n Snippet: value: enums.UnitAngle = driver.unit.get_angle() \n Sets the default unit for phase modulation angle. The command affects no other parameters, such as RF phase, or the manual control or display. \n :return: angle: DEGree| DEGRee| RADian """response=self._core.io.query_str('UNIT:ANGLe?')returnConversions.str_to_scalar_enum(response,enums.UnitAngle)
[docs]defset_angle(self,angle:enums.UnitAngle)->None:"""SCPI: UNIT:ANGLe \n Snippet: driver.unit.set_angle(angle = enums.UnitAngle.DEGree) \n Sets the default unit for phase modulation angle. The command affects no other parameters, such as RF phase, or the manual control or display. \n :param angle: DEGree| DEGRee| RADian """param=Conversions.enum_scalar_to_str(angle,enums.UnitAngle)self._core.io.write(f'UNIT:ANGLe {param}')
# noinspection PyTypeChecker
[docs]defget_power(self)->enums.UnitPower:"""SCPI: UNIT:POWer \n Snippet: value: enums.UnitPower = driver.unit.get_power() \n Sets the default unit for all power parameters. This setting affects the GUI, as well as all remote control commands that determine power values. \n :return: power: V| DBUV| DBM """response=self._core.io.query_str('UNIT:POWer?')returnConversions.str_to_scalar_enum(response,enums.UnitPower)
[docs]defset_power(self,power:enums.UnitPower)->None:"""SCPI: UNIT:POWer \n Snippet: driver.unit.set_power(power = enums.UnitPower.DBM) \n Sets the default unit for all power parameters. This setting affects the GUI, as well as all remote control commands that determine power values. \n :param power: V| DBUV| DBM """param=Conversions.enum_scalar_to_str(power,enums.UnitPower)self._core.io.write(f'UNIT:POWer {param}')
# noinspection PyTypeChecker
[docs]defget_velocity(self)->enums.UnitSpeed:"""SCPI: UNIT:VELocity \n Snippet: value: enums.UnitSpeed = driver.unit.get_velocity() \n Sets the default unit for the velocity of the wave. \n :return: velocity: MPS| KMH| MPH| NMPH """response=self._core.io.query_str('UNIT:VELocity?')returnConversions.str_to_scalar_enum(response,enums.UnitSpeed)
[docs]defset_velocity(self,velocity:enums.UnitSpeed)->None:"""SCPI: UNIT:VELocity \n Snippet: driver.unit.set_velocity(velocity = enums.UnitSpeed.KMH) \n Sets the default unit for the velocity of the wave. \n :param velocity: MPS| KMH| MPH| NMPH """param=Conversions.enum_scalar_to_str(velocity,enums.UnitSpeed)self._core.io.write(f'UNIT:VELocity {param}')