Base (Meta) Instrument

This file contains two base classes to be used as parent classes for Instrument classes and MetaInstrument classes.

class hyperion.instrument.base_instrument.BaseInstrument(settings)

Let Instrument classes inherit from this class. An instrument is a layer between the Controller (which takes care of hardware communication) and the user or Experiment. This instrument layer allows to add functionality, pint-units and may be used as an abstraction layer for similar controllers.

finalize()

This is to close connection to the device.

If you need to parse arguments to the finalize, make your own finalize method in your instrument class.

idn()

Identify command

initialize()

Starts the connection to the device.

If you need to parse arguments to the initialize, make your own initialize method in your instrument class.

load_controller(settings)

Loads controller

Parameters:settings (dict) – dictionary with the field controller
Returns:controller class
Return type:class
class hyperion.instrument.base_instrument.BaseMetaInstrument(settings, sub_instruments)

Let MetaInstrument classes inherit from this class. A MetaInstrument takes other instruments as inputs (and does not use a controller)

The finalize() method of a MetaInstrument will call the finalize() methods of the sub instruments. In the case of an Experiment class, the MetaInstruments don’t need to be finalized because the Instruments itself will be finalized.