from ......Internal.Core import Core
from ......Internal.CommandsGroup import CommandsGroup
from ......Internal import Conversions
# noinspection PyPep8Naming,PyAttributeOutsideInit,SpellCheckingInspection
class MactiveCls:
"""
| Commands in total: 1
| Subgroups: 0
| Direct child commands: 1
"""
def __init__(self, core: Core, parent):
self._core = core
self._cmd_group = CommandsGroup("mactive", core, parent)
[docs]
def get_state(self) -> bool:
"""
``[SOURce<HW>]:BB:DVB:DVBS:MACTive:STATe`` \n
Snippet: ``value: bool = driver.source.bb.dvb.dvbs.mactive.get_state()`` \n
Enables a counter in the MA-type2 byte in the baseband header to count the TSL repetitions.
:return: mactive: 1 | ON | 0| OFF
"""
response = self._core.io.query_str('SOURce<HwInstance>:BB:DVB:DVBS:MACTive:STATe?')
return Conversions.str_to_bool(response)
[docs]
def set_state(self, mactive: bool) -> None:
"""
``[SOURce<HW>]:BB:DVB:DVBS:MACTive:STATe`` \n
Snippet: ``driver.source.bb.dvb.dvbs.mactive.set_state(mactive = False)`` \n
Enables a counter in the MA-type2 byte in the baseband header to count the TSL repetitions.
:param mactive: 1 | ON | 0| OFF
"""
param = Conversions.bool_to_str(mactive)
self._core.io.write(f'SOURce<HwInstance>:BB:DVB:DVBS:MACTive:STATe {param}')