Source code for RsCMX_Signaling.Implementations.Configure.Signaling.Nradio.Cell.Bwp.Downlink.Rb

from ........Internal.Core import Core
from ........Internal.CommandsGroup import CommandsGroup
from ........Internal import Conversions
from ........Internal.Types import DataType
from ........Internal.StructBase import StructBase
from ........Internal.ArgStruct import ArgStruct
from ........Internal.ArgSingleList import ArgSingleList
from ........Internal.ArgSingle import ArgSingle
from ........ import repcap


# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
[docs] class RbCls: """Rb commands group definition. 1 total commands, 0 Subgroups, 1 group commands""" def __init__(self, core: Core, parent): self._core = core self._cmd_group = CommandsGroup("rb", core, parent)
[docs] def set(self, cell_name: str, number_rb: int, start_rb: int = None, bwParts=repcap.BwParts.Default) -> None: """SCPI: [CONFigure]:SIGNaling:NRADio:CELL:BWP<bwpid>:DL:RB \n Snippet: driver.configure.signaling.nradio.cell.bwp.downlink.rb.set(cell_name = 'abc', number_rb = 1, start_rb = 1, bwParts = repcap.BwParts.Default) \n Defines the downlink of BWP <bb> in the frequency domain as a contiguous set of RBs, within the carrier bandwidth. \n :param cell_name: No help available :param number_rb: No help available :param start_rb: No help available :param bwParts: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Bwp') """ param = ArgSingleList().compose_cmd_string(ArgSingle('cell_name', cell_name, DataType.String), ArgSingle('number_rb', number_rb, DataType.Integer), ArgSingle('start_rb', start_rb, DataType.Integer, None, is_optional=True)) bwParts_cmd_val = self._cmd_group.get_repcap_cmd_value(bwParts, repcap.BwParts) self._core.io.write(f'CONFigure:SIGNaling:NRADio:CELL:BWP{bwParts_cmd_val}:DL:RB {param}'.rstrip())
# noinspection PyTypeChecker
[docs] class GetStruct(StructBase): """Response structure. Fields: \n - Number_Rb: int: No parameter help available - Start_Rb: int: No parameter help available""" __meta_args_list = [ ArgStruct.scalar_int('Number_Rb'), ArgStruct.scalar_int('Start_Rb')] def __init__(self): StructBase.__init__(self, self) self.Number_Rb: int = None self.Start_Rb: int = None
[docs] def get(self, cell_name: str, bwParts=repcap.BwParts.Default) -> GetStruct: """SCPI: [CONFigure]:SIGNaling:NRADio:CELL:BWP<bwpid>:DL:RB \n Snippet: value: GetStruct = driver.configure.signaling.nradio.cell.bwp.downlink.rb.get(cell_name = 'abc', bwParts = repcap.BwParts.Default) \n Defines the downlink of BWP <bb> in the frequency domain as a contiguous set of RBs, within the carrier bandwidth. \n :param cell_name: No help available :param bwParts: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Bwp') :return: structure: for return value, see the help for GetStruct structure arguments.""" param = Conversions.value_to_quoted_str(cell_name) bwParts_cmd_val = self._cmd_group.get_repcap_cmd_value(bwParts, repcap.BwParts) return self._core.io.query_struct(f'CONFigure:SIGNaling:NRADio:CELL:BWP{bwParts_cmd_val}:DL:RB? {param}', self.__class__.GetStruct())