from ....Internal.Core import Core
from ....Internal.CommandsGroup import CommandsGroup
from ....Internal.Types import DataType
from ....Internal.ArgSingleList import ArgSingleList
from ....Internal.ArgSingle import ArgSingle
from .... import enums
# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class AssignCls:
"""
| Commands in total: 1
| Subgroups: 0
| Direct child commands: 1
"""
def __init__(self, core: Core, parent):
self._core = core
self._cmd_group = CommandsGroup("assign", core, parent)
[docs]
def set(self, diagram_name: str, source: enums.SignalSource) -> None:
"""
``LAYout:SIGNal:ASSign`` \n
Snippet: ``driver.layout.signal.assign.set(diagram_name = 'abc', source = enums.SignalSource.AJ1)`` \n
Shows the specified waveform in the selected diagram.
:param diagram_name: String with the diagram name
:param source: Waveform to be assigned, see 'Waveform parameter' Spectrum analysis, option R&S RTO6-K37: Spectrograms and timeline spectrums are automatically displayed in their own diagrams. Eye diagram analysis with option R&S RTO6-K91: Eye diagrams are automatically displayed in their own diagrams. TDR/TDT analysis with option R&S RTO6-K130: Measurement waveforms are automatically displayed in their own diagrams. Advanced jitter and noise analysis with option R&S RTO6-K133/K134
"""
param = ArgSingleList().compose_cmd_string(ArgSingle('diagram_name', diagram_name, DataType.String), ArgSingle('source', source, DataType.Enum, enums.SignalSource))
self._core.io.write_with_opc(f'LAYout:SIGNal:ASSign {param}'.rstrip())