These device classes do not represent actual hardware devices, but they use the same configuration and parameter API as devices and are therefore Device subclasses.
The experiment device collects all configuration pertaining to the current experiment – i.e. proposal information, sample, current configuration of detectors and sample environment.
The experiment device is selected in setups using The sysconfig dictionary.
Bases: Device
A special singleton device to represent the experiment.
This class is normally subclassed for specific instruments to e.g. select the data paths according to instrument standards.
Several parameters configure special behavior:
The experiment singleton is available at runtime as nicos.session.experiment.
User methods
Called by FinishExperiment. Does nothing by default.
Called by NewExperiment.
Attached devices
Parameters
List of paths where data files should be stored. Default value: [''].
Root data path under which all proposal specific paths are created.
List of default detector device names. Default value: [].
True if the electronig logbook should be enabled. Default value: True.
List of default environment device names to read at every scan point. Default value: [].
Local contact for current experiment. Default value: ''.
Current proposal number or proposal string. Default value: ''.
Directory for proposal specific files. Default value: ''.
Current remark about experiment configuration. Default value: ''.
List of messages to remember for next experiment start. Default value: [].
Standard script directory. Default value: ''.
Currently executed scripts. Default value: [].
Experiment title. Default value: ''.
User names and affiliations for the proposal. Default value: [].
Parameters inherited from the base classes: description, loglevel, lowlevel
Bases: Device
A special device to represent a sample.
An instance of this class is used as the sample attached device of the Experiment object. It can be subclassed to add special sample properties, such as lattice and orientation calculations, or more parameters describing the sample.
Parameters
Sample name. Default value: ''.
Parameters inherited from the base classes: description, loglevel, lowlevel
Each setup requires an instrument device, giving basic information and functionality of the specific instrument. It is selected in setups using The sysconfig dictionary.
Bases: Device
A special singleton device to represent the instrument.
This class can be subclassed for specific instruments to e.g. provide the notion of moving “the instrument” in HKL space, such as in TAS.
The instrument singleton is available at runtime as nicos.session.instrument.
Parameters
Loop delay in checking for counting finished. Default value: 0.025000000000000001.
Instrument name. Default value: ''.
Instrument responsible name and email. Default value: ''.
Parameters inherited from the base classes: description, loglevel, lowlevel
These data sinks provide different ways of processing scan data. They can be configured in setups like normal devices and selected in The sysconfig dictionary.
Bases: Device
Base class for all data sinks.
A DataSink is a configurable object that receives scan data. All data handling is done by sinks; e.g. displaying it on the console or saving to a data file.
Parameters
Scan types for which the sink is active. Default value: [].
Parameters inherited from the base classes: description, loglevel, lowlevel
Bases: DataSink
A DataSink that prints scan data onto the console.
Parameters inherited from the base classes: description, loglevel, lowlevel, scantypes
Bases: DatafileSink
A data sink that writes to a plain ASCII data file.
The lastfilenumber and lastpoint parameters are managed automatically.
The current file counter is normally stored in a file called “counter” in the data directory. If the globalcounter parameter is nonempty, it gives the name of a global counter file instead, which is always used regardless of data path.
Parameters
Comment character. Default value: '#'.
File name for a global file counter instead of one per datapath. Default value: ''.
The number of the last written data file. Default value: 0.
The number of the last point in the data file. Default value: 0.
Whether to add a semicolon between X and Y values. Default value: True.
Parameters inherited from the base classes: datapath, description, loglevel, lowlevel, scantypes
Bases: DataSink
A DataSink that plots datasets in the Grace plotting program.
Needs the GracePlot module. Only active for console sessions.
Parameters
Name of active counter to plot. Default value: None.
Parameters inherited from the base classes: description, loglevel, lowlevel, scantypes
Bases: DataSink
A DataSink that plots datasets in the Gnuplot plotting program.
Needs the Gnuplot module. Only active for console sessions.
Parameters
Name of active counter to plot. Default value: None.
Parameters inherited from the base classes: description, loglevel, lowlevel, scantypes
These devices provide a way to notify user or instrument responsible. For example, in case of unhandled exceptions a notification is always sent if the script has run for more than a few seconds.
Notifiers can be configured in setups like normal devices and are selected in The sysconfig dictionary.
Bases: Device
Base class for all notification systems.
User methods
Send a notification.
Send a notification if the given runtime is large enough.
Parameters
Minimum runtime of a command before a failure is sent over the notifier. Default value: 300. Unit: s.
Parameters inherited from the base classes: description, loglevel, lowlevel
Bases: Notifier
E-Mail notification handling.
If a Mailer is configured as a notifier, the receiver addresses (not copies) can be set by SetMailReceivers.
Parameters
Mail copy addresses. Default value: [].
Mail receiver addresses. Default value: [].
Mail sender address.
Subject prefix. Default value: 'NICOS'.
Parameters inherited from the base classes: description, loglevel, lowlevel, minruntime
Bases: Notifier
SMS notifications via smslink client program.
If a SMSer is configured as a notifier, the receiver addresses (not copies) can be set by SetSMSReceivers.
Parameters
SMS receiver phone numbers. Default value: [].
Name of SMS server.
Body prefix. Default value: 'NICOS'.
Parameters inherited from the base classes: description, loglevel, lowlevel, minruntime
Bases: Notifier
Notifier to send Jabber notifications.
Needs the xmpp module.
Parameters
Jabber JID of the notifier.
Password for the given JID.
List of receiver JIDs. Default value: [].
Parameters inherited from the base classes: description, loglevel, lowlevel, minruntime