from ......Internal.Core import Core
from ......Internal.CommandsGroup import CommandsGroup
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
# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class PvalueCls:
"""
| Commands in total: 1
| Subgroups: 0
| Direct child commands: 1
"""
def __init__(self, core: Core, parent):
self._core = core
self._cmd_group = CommandsGroup("pvalue", core, parent)
[docs]
def set(self, pattern: str, bitcount: int) -> None:
"""
``[SOURce<HW>]:BB:DVB:DVBS:PVALue`` \n
Snippet: ``driver.source.bb.dvb.dvbs.pvalue.set(pattern = rawAbc, bitcount = 1)`` \n
Option: R&S SMW-K116: requires [:SOURce<hw>]:BB:DVB:DVBS | DVBX:STYPe GP | GC and [:SOURce<hw>]:BB:DVB:DVBS | DVBX:DATA
DLISt | PATTern Option: R&S SMW-K183 : requires [:SOURce<hw>]:BB:DVB:DVBS | DVBX:AM 1 and [:SOURce<hw>]:BB:DVB:DVBS |
DVBX:STYPe GP | GC and [:SOURce<hw>]:BB:DVB:DVBS | DVBX:DATA DLISt | PATTern. Sets the 8-bit sized padding value to fill
the baseband frame for transmission in hexadecimal representation in case of padding. Syntax to enter the hexadecimal
value of the padding value: #H<value>,8
:param pattern: numeric
:param bitcount: integer Range: 8 to 8
"""
param = ArgSingleList().compose_cmd_string(ArgSingle('pattern', pattern, DataType.RawString), ArgSingle('bitcount', bitcount, DataType.Integer))
self._core.io.write(f'SOURce<HwInstance>:BB:DVB:DVBS:PVALue {param}'.rstrip())
# noinspection PyTypeChecker
[docs]
class PvalueStruct(StructBase):
"""
Response structure. Fields: \n
- 1 Pattern: str: numeric
- 2 Bitcount: int: integer Range: 8 to 8
"""
__meta_args_list = [
ArgStruct.scalar_raw_str('Pattern'),
ArgStruct.scalar_int('Bitcount')]
def __init__(self):
StructBase.__init__(self, self)
self.Pattern: str = None
self.Bitcount: int = None
[docs]
def get(self) -> PvalueStruct:
"""
``[SOURce<HW>]:BB:DVB:DVBS:PVALue`` \n
Snippet: ``value: PvalueStruct = driver.source.bb.dvb.dvbs.pvalue.get()`` \n
Option: R&S SMW-K116: requires [:SOURce<hw>]:BB:DVB:DVBS | DVBX:STYPe GP | GC and [:SOURce<hw>]:BB:DVB:DVBS | DVBX:DATA
DLISt | PATTern Option: R&S SMW-K183 : requires [:SOURce<hw>]:BB:DVB:DVBS | DVBX:AM 1 and [:SOURce<hw>]:BB:DVB:DVBS |
DVBX:STYPe GP | GC and [:SOURce<hw>]:BB:DVB:DVBS | DVBX:DATA DLISt | PATTern. Sets the 8-bit sized padding value to fill
the baseband frame for transmission in hexadecimal representation in case of padding. Syntax to enter the hexadecimal
value of the padding value: #H<value>,8
:return: structure: for return value, see the help for PvalueStruct structure arguments.
"""
return self._core.io.query_struct(f'SOURce<HwInstance>:BB:DVB:DVBS:PVALue?', self.__class__.PvalueStruct())