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: 3
| Subgroups: 0
| Direct child commands: 3
"""
def __init__(self, core: Core, parent):
self._core = core
self._cmd_group = CommandsGroup("fconfig", core, parent)
# noinspection PyTypeChecker
[docs]
def get_dlength(self) -> enums.HrpUwbDeltaLength:
"""
``[SOURce<HW>]:BB:[LRWPan]:MMS:FCONfig:DLENgth`` \n
Snippet: ``value: enums.HrpUwbDeltaLength = driver.source.bb.lrWpan.mms.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:MMS: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]:MMS:FCONfig:DLENgth`` \n
Snippet: ``driver.source.bb.lrWpan.mms.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:MMS:FCONfig:DLENgth {param}')
# noinspection PyTypeChecker
[docs]
def get_sfd_length(self) -> enums.HrpUwbSfdlEngth:
"""
``[SOURce<HW>]:BB:[LRWPan]:MMS:FCONfig:SFDLength`` \n
Snippet: ``value: enums.HrpUwbSfdlEngth = driver.source.bb.lrWpan.mms.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:MMS: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]:MMS:FCONfig:SYNLength`` \n
Snippet: ``value: enums.HrpUwbSyncLength = driver.source.bb.lrWpan.mms.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:MMS: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]:MMS:FCONfig:SYNLength`` \n
Snippet: ``driver.source.bb.lrWpan.mms.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:MMS:FCONfig:SYNLength {param}')