from ......Internal.Core import Core
from ......Internal.CommandsGroup import CommandsGroup
from ......Internal import Conversions
from ...... import enums
from ...... import repcap
# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class SymbolCls:
"""
| Commands in total: 1
| Subgroups: 0
| Direct child commands: 1
"""
def __init__(self, core: Core, parent):
self._core = core
self._cmd_group = CommandsGroup("symbol", core, parent)
[docs]
def set(self, style: enums.TraceStyleSymbol, window=repcap.Window.Default, subWindow=repcap.SubWindow.Default, trace=repcap.Trace.Default) -> None:
"""
``DISPlay[:WINDow<n>][:SUBWindow<w>]:TRACe<t>:SYMBol`` \n
Snippet: ``driver.display.window.subwindow.trace.symbol.set(style = enums.TraceStyleSymbol.DOTS, window = repcap.Window.Default, subWindow = repcap.SubWindow.Default, trace = repcap.Trace.Default)`` \n
Sets the display style of the persistence spectrum.
:param style: DOTS Displays the data as dots. The result is a persistence spectrum made up out of dots. VECTor Interpolates the measurement points. The result is an uninterrupted persistence spectrum.
:param window: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Window')
:param subWindow: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Subwindow')
:param trace: optional repeated capability selector. Default value: Tr1 (settable in the interface 'Trace')
"""
param = Conversions.enum_scalar_to_str(style, enums.TraceStyleSymbol)
window_cmd_val = self._cmd_group.get_repcap_cmd_value(window, repcap.Window)
subWindow_cmd_val = self._cmd_group.get_repcap_cmd_value(subWindow, repcap.SubWindow)
trace_cmd_val = self._cmd_group.get_repcap_cmd_value(trace, repcap.Trace)
self._core.io.write(f'DISPlay:WINDow{window_cmd_val}:SUBWindow{subWindow_cmd_val}:TRACe{trace_cmd_val}:SYMBol {param}')
# noinspection PyTypeChecker
[docs]
def get(self, window=repcap.Window.Default, subWindow=repcap.SubWindow.Default, trace=repcap.Trace.Default) -> enums.TraceStyleSymbol:
"""
``DISPlay[:WINDow<n>][:SUBWindow<w>]:TRACe<t>:SYMBol`` \n
Snippet: ``value: enums.TraceStyleSymbol = driver.display.window.subwindow.trace.symbol.get(window = repcap.Window.Default, subWindow = repcap.SubWindow.Default, trace = repcap.Trace.Default)`` \n
Sets the display style of the persistence spectrum.
:param window: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Window')
:param subWindow: optional repeated capability selector. Default value: Nr1 (settable in the interface 'Subwindow')
:param trace: optional repeated capability selector. Default value: Tr1 (settable in the interface 'Trace')
:return: style: DOTS Displays the data as dots. The result is a persistence spectrum made up out of dots. VECTor Interpolates the measurement points. The result is an uninterrupted persistence spectrum.
"""
window_cmd_val = self._cmd_group.get_repcap_cmd_value(window, repcap.Window)
subWindow_cmd_val = self._cmd_group.get_repcap_cmd_value(subWindow, repcap.SubWindow)
trace_cmd_val = self._cmd_group.get_repcap_cmd_value(trace, repcap.Trace)
response = self._core.io.query_str(f'DISPlay:WINDow{window_cmd_val}:SUBWindow{subWindow_cmd_val}:TRACe{trace_cmd_val}:SYMBol?')
return Conversions.str_to_scalar_enum(response, enums.TraceStyleSymbol)