Пример #1
0
    def __init__(self, config, plotter):
        """Initialize the instrument, without configuring.

        Typically, PLACE instruments should be configured only when the
        config() method is called. However, we pass the JSON config data into
        the object at this stage and save it. This is handled by the Instrument
        init method. Class variables should be set to trivial values in this
        method as a form of documentation. Additionally, minimal resource
        gathering is appropriate here, if needed. For example, this
        initialization method creates the XPS object needed to access the
        controller.

        By following this design pattern, it creates a contrast between
        instruments which have been initialized vs. instruments which have been
        configured, which is a subtle but important difference.

        :param config: configuration data (from JSON)
        :type config: dict

        :param plotter: a plotting object to return plots to the web interface
        :type plotter: plots.PlacePlotter
        """
        Instrument.__init__(self, config, plotter)

        self._controller = XPS_C8_drivers.XPS()
        self._socket = None
        self._position = None
        self._group = None
        self._positioner = None
Пример #2
0
 def __init__(self, config, plotter):
     """Constructor"""
     Instrument.__init__(self, config, plotter)
     self._serial = None
     self._signal = None
     self.min_used = None
     self.max_used = None
Пример #3
0
 def __init__(self, config):
     """Constructor"""
     Instrument.__init__(self, config)
     self._serial = None
     self._signal = None
     self.min_used = None
     self.max_used = None
Пример #4
0
    def __init__(self, config):
        """Initialize the instrument, without configuring.

        Typically, PLACE instruments should be configured only when the
        config() method is called. However, we pass the JSON config data into
        the object at this stage and save it. This is handled by the Instrument
        init method. Class variables should be set to trivial values in this
        method as a form of documentation. Additionally, minimal resource
        gathering is appropriate here, if needed. For example, this
        initialization method creates the XPS object needed to access the
        controller.

        By following this design pattern, it creates a contrast between
        instruments which have been initialized vs. instruments which have been
        configured, which is a subtle but important difference.

        :param config: configuration data (from JSON)
        :type config: dict
        """
        Instrument.__init__(self, config)

        self._controller = XPS_C8_drivers.XPS()
        self._socket = None
        self._position = None
        self._group = None
Пример #5
0
 def __init__(self, config, plotter):
     Instrument.__init__(self, config, plotter)
     self._updates = None
     self._ip_address = None
     self._scope = None
     self._channels = None
     self._samples = None
     self._record_length = None
     self._x_zero = None
     self._x_increment = None
Пример #6
0
    def __init__(self, config):
        """Initialize the custom script, without configuring.

        :param config: configuration data (as a parsed JSON object)
        :type config: dict
        """
        Instrument.__init__(self, config)
        self.config_filepath = None
        self.update_filepath = None
        self.cleanup_filepath = None
Пример #7
0
    def __init__(self, config):
        """Initialize the counter, without configuring.

        :param config: configuration data (as a parsed JSON object)
        :type config: dict
        """
        Instrument.__init__(self, config)
        self._count = None
        self._number = None
        self._samples = None
        self._updates = None
Пример #8
0
    def __init__(self, config):
        """Initialize the controller, without configuring.

        :param config: configuration data (from JSON)
        :type config: dict
        """
        Instrument.__init__(self, config)
        self._controller = None
        self._position = None
        self.last_x = None
        self.last_y = None
Пример #9
0
 def __init__(self, config):
     """
     Initialize the MokuLab, without configuring.
     :param config: configuration data (as a parsed JSON object)
     :type config: dict
     """
     Instrument.__init__(self, config)
     self.total_updates = None
     self.sweeps = None
     self.moku = None
     self.bode = None
     self.time_safety_net = None
Пример #10
0
    def __init__(self, config):
        """Constructor

        :param config: configuration data (from JSON)
        :type config: dict
        """
        Instrument.__init__(self, config)
        ats.Board.__init__(self)
        self._updates = None
        self._analog_inputs = None
        self._data = None
        self._samples = None
        self._sample_rate = None
Пример #11
0
    def __init__(self, config, plotter):
        """Initialize the custom script, without configuring.

        :param config: configuration data (as a parsed JSON object)
        :type config: dict

        :param plotter: a plotting object to return plots to the web interface
        :type plotter: plots.PlacePlotter
        """
        Instrument.__init__(self, config, plotter)
        self.config_filepath = None
        self.update_filepath = None
        self.cleanup_filepath = None
Пример #12
0
    def __init__(self, config, plotter):
        """Initialize the custom script, without configuring.

        :param config: configuration data (as a parsed JSON object)
        :type config: dict

        :param plotter: a plotting object to return plots to the web interface
        :type plotter: plots.PlacePlotter
        """
        Instrument.__init__(self, config, plotter)
        self.config_filepath = None
        self.update_filepath = None
        self.cleanup_filepath = None
Пример #13
0
    def __init__(self, config, plotter):
        """Initialize the counter, without configuring.

        :param config: configuration data (as a parsed JSON object)
        :type config: dict

        :param plotter: a plotting object to return plots to the web interface
        :type plotter: plots.PlacePlotter
        """
        Instrument.__init__(self, config, plotter)
        self._count = None
        self._number = None
        self._samples = None
        self._updates = None
Пример #14
0
    def __init__(self, config, plotter):
        """Initialize the counter, without configuring.

        :param config: configuration data (as a parsed JSON object)
        :type config: dict

        :param plotter: a plotting object to return plots to the web interface
        :type plotter: plots.PlacePlotter
        """
        Instrument.__init__(self, config, plotter)
        self._count = None
        self._number = None
        self._samples = None
        self._updates = None
Пример #15
0
    def __init__(self, config, plotter):
        """Initialize the MokuLab, without configuring.

        :param config: configuration data (as a parsed JSON object)
        :type config: dict

        :param plotter: a plotting object to return plots to the web interface
        :type plotter: plots.PlacePlotter
        """
        Instrument.__init__(self, config, plotter)
        self.total_updates = None
        self.sweeps = None
        self.moku = None
        self.bode = None
        self.time_safety_net = None
Пример #16
0
    def __init__(self, config, plotter):
        """Initialize the MokuLab, without configuring.

        :param config: configuration data (as a parsed JSON object)
        :type config: dict

        :param plotter: a plotting object to return plots to the web interface
        :type plotter: plots.PlacePlotter
        """
        Instrument.__init__(self, config, plotter)
        self.total_updates = None
        self.sweeps = None
        self.moku = None
        self.bode = None
        self.time_safety_net = None
Пример #17
0
    def __init__(self, config, plotter):
        """Initialize the controller, without configuring.

        :param config: configuration data (from JSON)
        :type config: dict

        :param plotter: a plotting object to return plots to the web interface
        :type plotter: plots.PlacePlotter
        """
        Instrument.__init__(self, config, plotter)
        self._controller = None
        self._position = None
        self.last_x = None
        self.last_y = None
        self.fig = None
        self.ax = None
Пример #18
0
    def __init__(self, config, plotter):
        """Constructor

        :param config: configuration data (from JSON)
        :type config: dict

        :param plotter: a plotting object to return plots to the web interface
        :type plotter: plots.PlacePlotter
        """
        Instrument.__init__(self, config, plotter)
        ats.Board.__init__(self)
        self._updates = None
        self._analog_inputs = None
        self._data = None
        self._samples = None
        self._sample_rate = None
        self._wiggle_figs = None
        self._wiggle_axes = None
Пример #19
0
    def __init__(self, config, plotter):
        """Constructor

        :param config: configuration data (from JSON)
        :type config: dict

        :param plotter: a plotting object to return plots to the web interface
        :type plotter: plots.PlacePlotter
        """
        Instrument.__init__(self, config, plotter)
        ats.Board.__init__(self)
        self._updates = None
        self._analog_inputs = None
        self._data = None
        self._samples = None
        self._sample_rate = None
        self._wiggle_figs = None
        self._wiggle_axes = None
Пример #20
0
    def __init__(self, config, plotter):

        Instrument.__init__(self, config, plotter)
        self._position = None
Пример #21
0
    def __init__(self, config, plotter):
        """Constructor"""

        Instrument.__init__(self, config, plotter)
        self.mfli = None
        self.actual_sampling_rate = None
Пример #22
0
 def __init__(self, config, plotter):
     """Constructor"""
     Instrument.__init__(self, config, plotter)
     self.vary_amplitude = False
     self.current_amplitude = 5.0
     self.amplitude_increment = 0.0
Пример #23
0
    def __init__(self, config, plotter):

        Instrument.__init__(self, config, plotter)
        self._position = None
Пример #24
0
 def __init__(self, config):
     """Constructor"""
     Instrument.__init__(self, config)
     self._serial = None
     self._last_y = None
Пример #25
0
 def __init__(self, config, plotter):
     """Constructor"""
     Instrument.__init__(self, config, plotter)
     self.power_increment = 0
Пример #26
0
 def __init__(self, config, plotter):
     Instrument.__init__(self, config, plotter)
Пример #27
0
    def __init__(self, config):

        Instrument.__init__(self, config)
        self._position = None