Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def get_limits(self):
"""Dummy limits"""
limits = MicrowaveLimits()
limits.supported_modes = (MicrowaveMode.CW, MicrowaveMode.LIST, MicrowaveMode.SWEEP)
limits.min_frequency = 100e3
limits.max_frequency = 20e9
limits.min_power = -120
limits.max_power = 30
limits.list_minstep = 0.001
limits.list_maxstep = 20e9
limits.list_maxentries = 10001
limits.sweep_minstep = 0.001
limits.sweep_maxstep = 20e9
limits.sweep_maxentries = 10001
return limits
def get_limits(self):
""" Right now, this is for Anritsu MG3691C with Option 2 only."""
limits = MicrowaveLimits()
limits.supported_modes = (MicrowaveMode.CW, MicrowaveMode.LIST)
limits.min_frequency = 10e6
limits.max_frequency = 20e9
limits.min_power = -130
limits.max_power = 30
limits.list_minstep = 0.001
limits.list_maxstep = 10e9
limits.list_maxentries = 10001
limits.sweep_minstep = 0.001
limits.sweep_maxstep = 10e9
limits.sweep_maxentries = 10001
if self.model == 'MG3961C':
limits.max_frequency = 10e9
def get_limits(self):
""" Create an object containing parameter limits for this microwave source.
@return MicrowaveLimits: device-specific parameter limits
"""
limits = MicrowaveLimits()
limits.supported_modes = (MicrowaveMode.CW, MicrowaveMode.LIST, MicrowaveMode.SWEEP)
limits.min_frequency = 300e3
limits.max_frequency = 6.4e9
limits.min_power = -144
limits.max_power = 10
limits.list_minstep = 0.1
limits.list_maxstep = 6.4e9
limits.list_maxentries = 4000
limits.sweep_minstep = 0.1
limits.sweep_maxstep = 6.4e9
limits.sweep_maxentries = 10001
if self.model == 'SMIQ02B':
def get_limits(self):
""" Right now, this is for Anritsu MG37022A with Option 4 only."""
limits = MicrowaveLimits()
limits.supported_modes = (MicrowaveMode.CW, MicrowaveMode.LIST, MicrowaveMode.SWEEP)
limits.min_frequency = 10e6
limits.max_frequency = 20e9
limits.min_power = -105
limits.max_power = 30
limits.list_minstep = 0.001
limits.list_maxstep = 20e9
limits.list_maxentries = 10001
limits.sweep_minstep = 0.001
limits.sweep_maxstep = 20e9
limits.sweep_maxentries = 10001
return limits
def get_limits(self):
"""Dummy limits"""
limits = MicrowaveLimits()
limits.supported_modes = (MicrowaveMode.CW, MicrowaveMode.LIST, MicrowaveMode.SWEEP)
limits.min_frequency = 100e3
limits.max_frequency = 20e9
limits.min_power = -120
limits.max_power = 30
limits.list_minstep = 0.001
limits.list_maxstep = 20e9
limits.list_maxentries = 10001
limits.sweep_minstep = 0.001
limits.sweep_maxstep = 20e9
limits.sweep_maxentries = 10001
return limits
def __init__(self):
"""Create an instance containing all parameters with default values."""
self.supported_modes = (
MicrowaveMode.CW,
MicrowaveMode.LIST,
MicrowaveMode.SWEEP,
MicrowaveMode.ASWEEP,
)
# frequency in Hz
self.min_frequency = 1e6
self.max_frequency = 1e9
# power in dBm
self.min_power = -10
self.max_power = 0
# list limits, frequencies in Hz, entries are single steps
self.list_minstep = 1
self.list_maxstep = 1e9
def get_limits(self):
""" Right now, this is for Anritsu MG37022A with Option 4 only."""
limits = MicrowaveLimits()
limits.supported_modes = (MicrowaveMode.CW, MicrowaveMode.LIST, MicrowaveMode.SWEEP)
limits.min_frequency = 10e6
limits.max_frequency = 20e9
limits.min_power = -105
limits.max_power = 30
limits.list_minstep = 0.001
limits.list_maxstep = 20e9
limits.list_maxentries = 10001
limits.sweep_minstep = 0.001
limits.sweep_maxstep = 20e9
limits.sweep_maxentries = 10001
return limits
def __init__(self, config, **kwargs):
super().__init__(config=config, **kwargs)
self.__current_mode = MicrowaveMode.CW
self._cw_parameters = {'frequency': 2.87e9, 'power': 0}
self._sweep_parameters = {'start': 2.77e9, 'stop': 2.97e9, 'step': 1e6, 'power': 0}
self._list_parameters = {'frequency': [2.87e9], 'power': 0}
self._cw_waveforms = list()
self._list_waveforms = list()
self._list_sequence = None
return
def get_limits(self):
""" Right now, this is for Anritsu MG3696B only."""
limits = MicrowaveLimits()
limits.supported_modes = (MicrowaveMode.CW, MicrowaveMode.LIST)
limits.min_frequency = 10e6
limits.max_frequency = 70e9
limits.min_power = -20
limits.max_power = 10
limits.list_minstep = 0.001
limits.list_maxstep = 70e9
limits.list_maxentries = 2000
limits.sweep_minstep = 0.001
limits.sweep_maxstep = 70e9
limits.sweep_maxentries = 10001
return limits