Source code for RsSmw.Implementations.Source.Bb.LrWpan.Sens.Fconfig

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


# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class FconfigCls:
	"""
	| Commands in total: 18
	| Subgroups: 4
	| Direct child commands: 12
	"""

	def __init__(self, core: Core, parent):
		self._core = core
		self._cmd_group = CommandsGroup("fconfig", core, parent)

	@property
	def phro(self):
		"""
		| Commands in total: 1
		| Subgroups: 0
		| Direct child commands: 1
		"""
		if not hasattr(self, '_phro'):
			from .Phro import PhroCls
			self._phro = PhroCls(self._core, self._cmd_group)
		return self._phro

	@property
	def phrt(self):
		"""
		| Commands in total: 1
		| Subgroups: 0
		| Direct child commands: 1
		"""
		if not hasattr(self, '_phrt'):
			from .Phrt import PhrtCls
			self._phrt = PhrtCls(self._core, self._cmd_group)
		return self._phrt

	@property
	def data(self):
		"""
		| Commands in total: 3
		| Subgroups: 1
		| Direct child commands: 2
		"""
		if not hasattr(self, '_data'):
			from .Data import DataCls
			self._data = DataCls(self._core, self._cmd_group)
		return self._data

	@property
	def mcs(self):
		"""
		| Commands in total: 1
		| Subgroups: 0
		| Direct child commands: 1
		"""
		if not hasattr(self, '_mcs'):
			from .Mcs import McsCls
			self._mcs = McsCls(self._core, self._cmd_group)
		return self._mcs

	# noinspection PyTypeChecker
[docs] def get_cindex(self) -> enums.HrpUwbCodeIndex: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:CINDex`` \n Snippet: ``value: enums.HrpUwbCodeIndex = driver.source.bb.lrWpan.sens.fconfig.get_cindex()`` \n Sets the code index. :return: code_index: CI_1 | CI_2 | CI_3 | CI_4 | CI_5 | CI_6 | CI_7 | CI_8 | CI_9 | CI_10 | CI_11 | CI_12 | CI_13 | CI_14 | CI_15 | CI_16 | CI_17 | CI_18 | CI_19 | CI_20 | CI_21 | CI_22 | CI_23 | CI_24 | CI_25 | CI_26 | CI_27 | CI_28 | CI_29 | CI_30 | CI_31 | CI_32 """ response = self._core.io.query_str('SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:CINDex?') return Conversions.str_to_scalar_enum(response, enums.HrpUwbCodeIndex)
[docs] def set_cindex(self, code_index: enums.HrpUwbCodeIndex) -> None: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:CINDex`` \n Snippet: ``driver.source.bb.lrWpan.sens.fconfig.set_cindex(code_index = enums.HrpUwbCodeIndex.CI_1)`` \n Sets the code index. :param code_index: CI_1 | CI_2 | CI_3 | CI_4 | CI_5 | CI_6 | CI_7 | CI_8 | CI_9 | CI_10 | CI_11 | CI_12 | CI_13 | CI_14 | CI_15 | CI_16 | CI_17 | CI_18 | CI_19 | CI_20 | CI_21 | CI_22 | CI_23 | CI_24 | CI_25 | CI_26 | CI_27 | CI_28 | CI_29 | CI_30 | CI_31 | CI_32 """ param = Conversions.enum_scalar_to_str(code_index, enums.HrpUwbCodeIndex) self._core.io.write(f'SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:CINDex {param}')
[docs] def get_da_length(self) -> int: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:DALEngth`` \n Snippet: ``value: int = driver.source.bb.lrWpan.sens.fconfig.get_da_length()`` \n Sets the data length of the physical header data in octets. :return: dlength: integer Range: 0 to 4096 """ response = self._core.io.query_str('SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:DALEngth?') return Conversions.str_to_int(response)
[docs] def set_da_length(self, dlength: int) -> None: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:DALEngth`` \n Snippet: ``driver.source.bb.lrWpan.sens.fconfig.set_da_length(dlength = 1)`` \n Sets the data length of the physical header data in octets. :param dlength: integer Range: 0 to 4096 """ param = Conversions.decimal_value_to_str(dlength) self._core.io.write(f'SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:DALEngth {param}')
# noinspection PyTypeChecker
[docs] def get_dlength(self) -> enums.HrpUwbDeltaLength: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:DLENgth`` \n Snippet: ``value: enums.HrpUwbDeltaLength = driver.source.bb.lrWpan.sens.fconfig.get_dlength()`` \n Sets the delta length. The length depends on the HRP UWB mode and bandwidth. :return: delta_length: DL_4 | DL_16 | DL_64 """ response = self._core.io.query_str('SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:DLENgth?') return Conversions.str_to_scalar_enum(response, enums.HrpUwbDeltaLength)
[docs] def set_dlength(self, delta_length: enums.HrpUwbDeltaLength) -> None: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:DLENgth`` \n Snippet: ``driver.source.bb.lrWpan.sens.fconfig.set_dlength(delta_length = enums.HrpUwbDeltaLength.DL_16)`` \n Sets the delta length. The length depends on the HRP UWB mode and bandwidth. :param delta_length: DL_4 | DL_16 | DL_64 """ param = Conversions.enum_scalar_to_str(delta_length, enums.HrpUwbDeltaLength) self._core.io.write(f'SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:DLENgth {param}')
[docs] def get_dr(self) -> float: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:DR`` \n Snippet: ``value: float = driver.source.bb.lrWpan.sens.fconfig.get_dr()`` \n Queries the data rate. In the mode [:SOURce<hw>]:BB:HUWB:STD OQPSK the data rate is set automatically, depending on the selected operating band and SFD. """ response = self._core.io.query_str('SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:DR?') return Conversions.str_to_float(response)
[docs] def get_flength(self) -> int: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:FLENgth`` \n Snippet: ``value: int = driver.source.bb.lrWpan.sens.fconfig.get_flength()`` \n Queries the frame length. The frame length is the sum of the MAC header length, the MAC frame check sequence (FCS) field length and the data length of the physical header. :return: frame_length: integer """ response = self._core.io.query_str('SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:FLENgth?') return Conversions.str_to_int(response)
# noinspection PyTypeChecker
[docs] def get_mdl(self) -> enums.HrpUwbMaxDataLength: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:MDL`` \n Snippet: ``value: enums.HrpUwbMaxDataLength = driver.source.bb.lrWpan.sens.fconfig.get_mdl()`` \n Requires [:SOURce<hw>]:BB:LRWPan | HUWB:STD HPRF | EHPRF | SENS. Sets the maximum data length of the physical header. :return: max_data_len: MDL_1023 | MDL_2047 | MDL_4095 MDL_1023 1023 octets MDL_2047 2047 octets MDL_4095 4095 octets """ response = self._core.io.query_str('SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:MDL?') return Conversions.str_to_scalar_enum(response, enums.HrpUwbMaxDataLength)
[docs] def set_mdl(self, max_data_len: enums.HrpUwbMaxDataLength) -> None: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:MDL`` \n Snippet: ``driver.source.bb.lrWpan.sens.fconfig.set_mdl(max_data_len = enums.HrpUwbMaxDataLength.MDL_1023)`` \n Requires [:SOURce<hw>]:BB:LRWPan | HUWB:STD HPRF | EHPRF | SENS. Sets the maximum data length of the physical header. :param max_data_len: MDL_1023 | MDL_2047 | MDL_4095 MDL_1023 1023 octets MDL_2047 2047 octets MDL_4095 4095 octets """ param = Conversions.enum_scalar_to_str(max_data_len, enums.HrpUwbMaxDataLength) self._core.io.write(f'SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:MDL {param}')
# noinspection PyTypeChecker
[docs] def get_mfl(self) -> enums.HrpUwbMacFcsLength: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:MFL`` \n Snippet: ``value: enums.HrpUwbMacFcsLength = driver.source.bb.lrWpan.sens.fconfig.get_mfl()`` \n Sets the length of the frame check sequence field. :return: mac_fcs_len: MFL_2 | MFL_4 MFL_2 Two octets MFL_4 Four octets """ response = self._core.io.query_str('SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:MFL?') return Conversions.str_to_scalar_enum(response, enums.HrpUwbMacFcsLength)
[docs] def set_mfl(self, mac_fcs_len: enums.HrpUwbMacFcsLength) -> None: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:MFL`` \n Snippet: ``driver.source.bb.lrWpan.sens.fconfig.set_mfl(mac_fcs_len = enums.HrpUwbMacFcsLength.MFL_2)`` \n Sets the length of the frame check sequence field. :param mac_fcs_len: MFL_2 | MFL_4 MFL_2 Two octets MFL_4 Four octets """ param = Conversions.enum_scalar_to_str(mac_fcs_len, enums.HrpUwbMacFcsLength) self._core.io.write(f'SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:MFL {param}')
[docs] def get_mprf(self) -> float: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:MPRF`` \n Snippet: ``value: float = driver.source.bb.lrWpan.sens.fconfig.get_mprf()`` \n Queries the mean pulse repetition frequency (PRF) . :return: mean_prf: float """ response = self._core.io.query_str('SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:MPRF?') return Conversions.str_to_float(response)
[docs] def get_phrb_rate(self) -> float: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:PHRBrate`` \n Snippet: ``value: float = driver.source.bb.lrWpan.sens.fconfig.get_phrb_rate()`` \n Queries the bit rate of the physical header. """ response = self._core.io.query_str('SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:PHRBrate?') return Conversions.str_to_float(response)
# noinspection PyTypeChecker
[docs] def get_sfd_length(self) -> enums.HrpUwbSfdlEngth: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:SFDLength`` \n Snippet: ``value: enums.HrpUwbSfdlEngth = driver.source.bb.lrWpan.sens.fconfig.get_sfd_length()`` \n Queries the symbol length of the start-of-frame delimiter (SFD) . The SFD length depends on the set SFD symbol sequence, see Table 'SFD: indices and lengths'. In the mode [:SOURce<hw>]:BB:HUWB:STD OQPSK the SFD length is SFDL_2. :return: sfd_length: SFDL_8 | SFDL_64 | SFDL_2 | SFDL_4 | SFDL_16 | SFDL_32 """ response = self._core.io.query_str('SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:SFDLength?') return Conversions.str_to_scalar_enum(response, enums.HrpUwbSfdlEngth)
# noinspection PyTypeChecker
[docs] def get_syn_length(self) -> enums.HrpUwbSyncLength: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:SYNLength`` \n Snippet: ``value: enums.HrpUwbSyncLength = driver.source.bb.lrWpan.sens.fconfig.get_syn_length()`` \n Sets the sync length. In the mode [:SOURce<hw>]:BB:HUWB:STD OQPSK the sync length is set automatically, depending on the selected operating band and SFD. :return: sync_length: SL_16 | SL_24 | SL_32 | SL_48 | SL_64 | SL_96 | SL_128 | SL_256 | SL_1024 | SL_4096 """ response = self._core.io.query_str('SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:SYNLength?') return Conversions.str_to_scalar_enum(response, enums.HrpUwbSyncLength)
[docs] def set_syn_length(self, sync_length: enums.HrpUwbSyncLength) -> None: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:SYNLength`` \n Snippet: ``driver.source.bb.lrWpan.sens.fconfig.set_syn_length(sync_length = enums.HrpUwbSyncLength.SL_1024)`` \n Sets the sync length. In the mode [:SOURce<hw>]:BB:HUWB:STD OQPSK the sync length is set automatically, depending on the selected operating band and SFD. :param sync_length: SL_16 | SL_24 | SL_32 | SL_48 | SL_64 | SL_96 | SL_128 | SL_256 | SL_1024 | SL_4096 """ param = Conversions.enum_scalar_to_str(sync_length, enums.HrpUwbSyncLength) self._core.io.write(f'SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:SYNLength {param}')
# noinspection PyTypeChecker
[docs] def get_vrate(self) -> enums.HrpUwbViterbiRate: """ ``[SOURce<HW>]:BB:[LRWPan]:SENS:FCONfig:VRATe`` \n Snippet: ``value: enums.HrpUwbViterbiRate = driver.source.bb.lrWpan.sens.fconfig.get_vrate()`` \n Queries the viterbi rate for convolutional coding or the channel code type. """ response = self._core.io.query_str('SOURce<HwInstance>:BB:LRWPan:SENS:FCONfig:VRATe?') return Conversions.str_to_scalar_enum(response, enums.HrpUwbViterbiRate)
def clone(self) -> 'FconfigCls': """ 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 = FconfigCls(self._core, self._cmd_group.parent) self._cmd_group.synchronize_repcaps(new_group) return new_group