Source code for RsSmw.Implementations.Source.Bb.Nr5G.Node.Cc

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


# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class CcCls:
	"""
	| Commands in total: 7
	| Subgroups: 1
	| Direct child commands: 6
	"""

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

	@property
	def add(self):
		"""
		| Commands in total: 1
		| Subgroups: 0
		| Direct child commands: 1
		"""
		if not hasattr(self, '_add'):
			from .Add import AddCls
			self._add = AddCls(self._core, self._cmd_group)
		return self._add

[docs] def get_cinfo(self) -> str: """ ``[SOURce<HW>]:BB:NR5G:NODE:CC:CINFo`` \n Snippet: ``value: str = driver.source.bb.nr5G.node.cc.get_cinfo()`` \n Queries basic information about the carrier you want to duplicate. Prerequisites for this command \n - Select a file as the source of the new carrier (method ``RsSmw.source.bb.nr5G.node.cc.cpy_sel()`` ) . :return: sel_carrier_info: string String containing the information about the carrier. """ response = self._core.io.query_str('SOURce<HwInstance>:BB:NR5G:NODE:CC:CINFo?') return trim_str_response(response)
[docs] def get_cpy_from(self) -> int: """ ``[SOURce<HW>]:BB:NR5G:NODE:CC:CPYFrom`` \n Snippet: ``value: int = driver.source.bb.nr5G.node.cc.get_cpy_from()`` \n Selects the carrier you want to duplicate. Prerequisites for this command \n - Selecting a carrier is only possible if there are more than one carrier in the table or in the configuration file. """ response = self._core.io.query_str('SOURce<HwInstance>:BB:NR5G:NODE:CC:CPYFrom?') return Conversions.str_to_int(response)
# noinspection PyTypeChecker
[docs] def get_cpy_sel(self) -> enums.CopySelection: """ ``[SOURce<HW>]:BB:NR5G:NODE:CC:CPYSel`` \n Snippet: ``value: enums.CopySelection = driver.source.bb.nr5G.node.cc.get_cpy_sel()`` \n Selects the source of a carrier that you want to create based on an existing carrier. """ response = self._core.io.query_str('SOURce<HwInstance>:BB:NR5G:NODE:CC:CPYSel?') return Conversions.str_to_scalar_enum(response, enums.CopySelection)
[docs] def get_cpy_to(self) -> str: """ ``[SOURce<HW>]:BB:NR5G:NODE:CC:CPYTo`` \n Snippet: ``value: str = driver.source.bb.nr5G.node.cc.get_cpy_to()`` \n Queries the index number the new carriers are created with. :return: copy_from: string String containing the number of the new carriers. """ response = self._core.io.query_str('SOURce<HwInstance>:BB:NR5G:NODE:CC:CPYTo?') return trim_str_response(response)
[docs] def get_load(self) -> str: """ ``[SOURce<HW>]:BB:NR5G:NODE:CC:LOAD`` \n Snippet: ``value: str = driver.source.bb.nr5G.node.cc.get_load()`` \n Selects a file containing an existing carrier you want to duplicate. Prerequisites for this command \n - Select a file as the source of the new carrier (method ``RsSmw.source.bb.nr5G.node.cc.cpy_sel()`` ) . :return: filename: string String containing the file name. """ response = self._core.io.query_str('SOURce<HwInstance>:BB:NR5G:NODE:CC:LOAD?') return trim_str_response(response)
[docs] def get_new_carriers(self) -> int: """ ``[SOURce<HW>]:BB:NR5G:NODE:CC:NEWCarriers`` \n Snippet: ``value: int = driver.source.bb.nr5G.node.cc.get_new_carriers()`` \n Defines the number of carriers you want to create based on an existing carrier. """ response = self._core.io.query_str('SOURce<HwInstance>:BB:NR5G:NODE:CC:NEWCarriers?') return Conversions.str_to_int(response)
def clone(self) -> 'CcCls': """ 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 = CcCls(self._core, self._cmd_group.parent) self._cmd_group.synchronize_repcaps(new_group) return new_group