nicos Package

nicos Package

The nicos package contains all standard NICOS commands and devices.

class nicos.__init__.Session

Bases: object

data Module

Data handling classes for NICOS.

class nicos.data.AsciiDatafileSink(name, **config)

Bases: nicos.data.DatafileSink

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

commentchar (str, settable at runtime)

Comment character. Default value: '#'.

globalcounter (str)

File name for a global file counter instead of one per datapath. Default value: ''.

lastfilenumber (int)

The number of the last written data file. Default value: 0.

lastpoint (int)

The number of the last point in the data file. Default value: 0.

semicolon (bool)

Whether to add a semicolon between X and Y values. Default value: True.

Parameters inherited from the base classes: datapath, description, loglevel, lowlevel, scantypes

class nicos.data.ConsoleSink(name, **config)

Bases: nicos.data.DataSink

Bases: DataSink

A DataSink that prints scan data onto the console.

Parameters inherited from the base classes: description, loglevel, lowlevel, scantypes

class nicos.data.DaemonSink(name, **config)

Bases: nicos.data.DataSink

Bases: DataSink

A DataSink that sends datasets to connected GUI clients for live plotting. Only active for daemon sessions.

Parameters inherited from the base classes: description, loglevel, lowlevel, scantypes

class nicos.data.DataSink(name, **config)

Bases: nicos.core.device.Device

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

scantypes (a list of str)

Scan types for which the sink is active. Default value: [].

Parameters inherited from the base classes: description, loglevel, lowlevel

class nicos.data.DatafileSink(name, **config)

Bases: nicos.data.DataSink, nicos.data.NeedsDatapath

Bases: DataSink, NeedsDatapath

Parameters inherited from the base classes: datapath, description, loglevel, lowlevel, scantypes

class nicos.data.Dataset

Bases: object

class nicos.data.GnuplotSink(name, **config)

Bases: nicos.data.DataSink

Bases: DataSink

A DataSink that plots datasets in the Gnuplot plotting program.

Needs the Gnuplot module. Only active for console sessions.

Parameters

activecounter (None or str, settable at runtime)

Name of active counter to plot. Default value: None.

Parameters inherited from the base classes: description, loglevel, lowlevel, scantypes

class nicos.data.GraceSink(name, **config)

Bases: nicos.data.DataSink

Bases: DataSink

A DataSink that plots datasets in the Grace plotting program.

Needs the GracePlot module. Only active for console sessions.

Parameters

activecounter (None or str, settable at runtime)

Name of active counter to plot. Default value: None.

Parameters inherited from the base classes: description, loglevel, lowlevel, scantypes

class nicos.data.NeedsDatapath

Bases: object

A mixin interface that specifies that a device needs the current datapath.

Parameters

datapath (a non-empty list of str, settable at runtime)

Do not set this, set the datapath on the experiment device. Default value: ['.'].

nicos.data.safe_format(fmtstr, value)

experiment Module

NICOS Experiment devices.

class nicos.experiment.Experiment(name, **config)

Bases: nicos.core.device.Device

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:

  • datapath (usually set proposal-specific by the new method) is a list of paths where raw data files are stored. If there is more than one entry in the list, the data files are created in the first path and hardlinked in the others.
  • detlist and envlist are lists of names of the currently selected standard detector and sample environment devices, respectively. The Experiment object has detectors and sampleenv properties that return lists of the actual devices.
  • scripts is managed by the session and should contain a stack of code of user scripts currently executed.

The experiment singleton is available at runtime as nicos.session.experiment.

User methods

addUser(name, email=None, affiliation=None)

Called by AddUser.

finish(*args, **kwargs)

Called by FinishExperiment. Does nothing by default.

new(proposal, title=None, localcontact=None, **kwds)

Called by NewExperiment.

Attached devices

sample

The device object representing the sample. Type: Sample.

Parameters

datapath (a non-empty list of str, settable at runtime)

List of paths where data files should be stored. Default value: [''].

dataroot (?, mandatory in setup)

Root data path under which all proposal specific paths are created.

detlist (a list of str, settable at runtime)

List of default detector device names. Default value: [].

elog (bool)

True if the electronig logbook should be enabled. Default value: True.

envlist (a list of str, settable at runtime)

List of default environment device names to read at every scan point. Default value: [].

localcontact (str, settable at runtime)

Local contact for current experiment. Default value: ''.

propdb (str, not shown to user)

user@host:dbname credentials for proposal DB. Default value: ''.

proposal (str, settable at runtime)

Current proposal number or proposal string. Default value: ''.

proposaldir (str, settable at runtime)

Directory for proposal specific files. Default value: ''.

remark (str, settable at runtime)

Current remark about experiment configuration. Default value: ''.

remember (a list of str, settable at runtime)

List of messages to remember for next experiment start. Default value: [].

scriptdir (str, settable at runtime)

Standard script directory. Default value: ''.

scripts (a list of str, settable at runtime)

Currently executed scripts. Default value: [].

title (str, settable at runtime)

Experiment title. Default value: ''.

users (a list of str, settable at runtime)

User names and affiliations for the proposal. Default value: [].

Parameters inherited from the base classes: description, loglevel, lowlevel

class nicos.experiment.Sample(name, **config)

Bases: nicos.core.device.Device

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

samplename (str, settable at runtime)

Sample name. Default value: ''.

Parameters inherited from the base classes: description, loglevel, lowlevel

instrument Module

NICOS Instrument device.

class nicos.instrument.Instrument(name, **config)

Bases: nicos.core.device.Device

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

countloopdelay (float)

Loop delay in checking for counting finished. Default value: 0.025000000000000001.

instrument (str)

Instrument name. Default value: ''.

responsible (str)

Instrument responsible name and email. Default value: ''.

Parameters inherited from the base classes: description, loglevel, lowlevel

ipc Module

IPC (Institut für Physikalische Chemie, Göttingen) hardware classes.

class nicos.ipc.Coder(name, **config)

Bases: nicos.abstract.Coder

Bases: Coder

This class supports both IPC absolute and incremental coder cards.

It can be used with the nicos.generic.Axis class.

Attached devices

bus

The communication bus. Type: IPCModBus.

Parameters

addr (int, mandatory in setup)

Bus address of the coder.

circular (None or float, settable at runtime)

Wrap-around value for circular coders, if negative use it as +/-, else as 0..value, None disables this. Default value: None.

confbyte (an integer in the range [0, 256), settable at runtime)

Configuration byte of the coder. Default value: 0.

firmware (int)

Firmware version. Default value: 0.

slope (float, settable at runtime)

Coder slope. Default value: 1.0. Unit: steps/main.

steps (int)

Current coder position in steps. Default value: 0.

zerosteps (float, settable at runtime)

Coder steps for physical zero. Default value: 0.0. Unit: steps.

Parameters inherited from the base classes: description, fmtstr, loglevel, lowlevel, maxage, pollinterval, precision, unit

class nicos.ipc.IPCInhibit(name, **config)

Bases: nicos.core.device.Readable

Bases: Readable

Makes the inhibit of an IPC single stepper card available as an input.

Returns ‘on’ if inhibit is active, ‘off’ otherwise.

Attached devices

stepper

The stepper card whose inhibit is read out. Type: Motor.

Parameters inherited from the base classes: description, fmtstr, loglevel, lowlevel, maxage, pollinterval, unit

class nicos.ipc.IPCModBus(name, **config)

Bases: nicos.core.device.Device

Bases: Device

Abstract class for IPC protocol communication over RS-485.

A device of this type is needed as the bus parameter of the other IPC devices.

Concrete implementations are IPCModBusTaco, IPCModBusTCP, IPCModBusSerial.

Parameters inherited from the base classes: description, loglevel, lowlevel

class nicos.ipc.IPCModBusSerial(name, **config)

Bases: nicos.ipc.IPCModBusTacoless

Bases: IPCModBusTacoless

IPC protocol communication directly over serial line.

Parameters

port (str, settable at runtime, mandatory in setup)

Device file name of the serial port to use.

Parameters inherited from the base classes: commtries, description, loglevel, lowlevel, roundtime

class nicos.ipc.IPCModBusTCP(name, **config)

Bases: nicos.ipc.IPCModBusTacoless

Bases: IPCModBusTacoless

IPC protocol communication bus over network to serial adapter using TCP connection.

Parameters

host (str, settable at runtime, mandatory in setup)

Hostname (or IP) of network2serial converter.

port (int)

TCP Port on network2serial converter. Default value: 4001.

Parameters inherited from the base classes: commtries, description, loglevel, lowlevel, roundtime

class nicos.ipc.IPCModBusTaco(name, **config)

Bases: nicos.taco.core.TacoDevice, nicos.ipc.IPCModBus

Bases: TacoDevice, IPCModBus

IPC protocol communication over TACO RS-485 server.

Parameters

maxtries (int, settable at runtime)

Number of tries for sending and receiving. Default value: 3.

Parameters inherited from the base classes: description, loglevel, lowlevel, tacodelay, tacodevice, tacotimeout, tacotries

class nicos.ipc.IPCModBusTacoless(name, **config)

Bases: nicos.ipc.IPCModBus

Bases: IPCModBus

Base class for IPC connections not using the RS485 TACO server.

This is an abstract class; use one of IPCModBusTCP or IPCModBusSerial.

Parameters

commtries (int, settable at runtime)

Number of tries for sending and receiving. Default value: 5.

roundtime (float, settable at runtime)

Maximum time to wait for an answer, set this high to slow down everything. Default value: 0.10000000000000001. Unit: s.

Parameters inherited from the base classes: description, loglevel, lowlevel

class nicos.ipc.IPCRelay(name, **config)

Bases: nicos.core.device.Moveable

Bases: Moveable

Makes the relay of an IPC single stepper card available as switch.

Attached devices

stepper

The stepper card whose relay is controlled. Type: Motor.

Parameters inherited from the base classes: description, fixed, fmtstr, loglevel, lowlevel, maxage, pollinterval, target, unit

class nicos.ipc.Input(name, **config)

Bases: nicos.core.device.Readable

Bases: Readable

IPC I/O card digital input class.

Attached devices

bus

The communication bus. Type: IPCModBus.

Parameters

addr (int, mandatory in setup)

Bus address of the card.

first (an integer in the range [0, 16), mandatory in setup)

First bit to read.

last (an integer in the range [0, 16), mandatory in setup)

Last bit to read.

Parameters inherited from the base classes: description, fmtstr, loglevel, lowlevel, maxage, pollinterval, unit

class nicos.ipc.InvalidCommandError(*args, **kwds)

Bases: nicos.core.errors.ProgrammingError

Bases: ProgrammingError

Error raised for “invalid command” response of IPC cards.

class nicos.ipc.Motor(name, **config)

Bases: nicos.abstract.Motor

Bases: Motor

This class supports IPC 6-fold, 3-fold and single motor cards.

It can be used with the nicos.generic.Axis class.

Attached devices

bus

The communication bus. Type: IPCModBus.

Parameters

accel (an integer in the range [0, 256), settable at runtime)

Motor acceleration (0..255). Default value: 0.

addr (int, mandatory in setup)

Bus address of the motor.

confbyte (an integer in the range [0, 256), settable at runtime)

Configuration byte. Default value: 0.

divider (an integer in the range [0, 8), settable at runtime)

Speed divider. Default value: 0.

firmware (int)

Firmware version. Default value: 0.

inhibit (one of 'off', 'on', volatile)

Inhibit input. Default value: 'off'.

max (an integer in the range [0, 1000000), settable at runtime)

Upper motorlimit. Default value: 0. Unit: steps.

microstep (one of 1, 2, 4, 8, 16, settable at runtime)

Microstepping mode. Default value: 1. Unit: steps.

min (an integer in the range [0, 1000000), settable at runtime)

Lower motorlimit. Default value: 0. Unit: steps.

power (one of 'off', 'on', settable at runtime, volatile)

Internal power stage switch. Default value: 'on'.

ramptype (an integer in the range [1, 5), settable at runtime)

Ramp type. Default value: 1.

relay (one of 'off', 'on', settable at runtime, volatile)

Relay switch. Default value: 'off'.

slope (float, settable at runtime)

Motor slope. Default value: 1.0. Unit: steps/main.

speed (an integer in the range [0, 256), settable at runtime)

Motor speed (0..255). Default value: 0.

startdelay (a float in the range [0.000000, 25.000000], settable at runtime)

Start delay. Default value: 0.0. Unit: s.

steps (an integer in the range [0, 1000000), settable at runtime)

Last position in steps. Default value: 0.

stopdelay (a float in the range [0.000000, 25.000000], settable at runtime)

Stop delay. Default value: 0.0. Unit: s.

timeout (int)

Waiting timeout. Default value: 360. Unit: s.

unit (str)

Motor unit. Default value: 'steps'.

zerosteps (float, settable at runtime)

Motor steps for physical zero. Default value: 0.0. Unit: steps.

Parameters inherited from the base classes: abslimits, description, fixed, fmtstr, loglevel, lowlevel, maxage, pollinterval, precision, target, userlimits

class nicos.ipc.Output(name, **config)

Bases: nicos.ipc.Input, nicos.core.device.Moveable

Bases: Input, Moveable

IPC I/O card digital output class.

Shares parameters and doInit with Input.

Attached devices

bus

The communication bus. Type: IPCModBus.

Parameters inherited from the base classes: addr, description, first, fixed, fmtstr, last, loglevel, lowlevel, maxage, pollinterval, target, unit

class nicos.ipc.SlitMotor(name, **config)

Bases: nicos.abstract.Motor

Bases: Motor

Class for one axis of a IPC 4-wing slit.

Use this together with nicos.generic.Axis and nicos.generic.Slit to create a 4-wing slit device.

Attached devices

bus

The communication bus. Type: IPCModBus.

Parameters

addr (int, mandatory in setup)

Bus address of the slit.

resetpos (float, mandatory in setup)

Value to move to for reset. Unit: same as device value.

side (int, mandatory in setup)

Side of axis.

slope (float, settable at runtime)

Motor slope. Default value: 1.0. Unit: steps/mm.

timeout (int)

Waiting timeout. Default value: 40. Unit: s.

unit (str)

Axis unit. Default value: 'mm'.

zerosteps (int, settable at runtime)

Motor steps for physical zero. Default value: 0. Unit: steps.

Parameters inherited from the base classes: abslimits, description, fixed, fmtstr, loglevel, lowlevel, maxage, pollinterval, precision, speed, target, userlimits

nicos.ipc.convert(string)
nicos.ipc.crc_ipc(string)

iseg Module

Iseg high voltage power supply device classes.

class nicos.iseg.IsegHV(name, **config)

Bases: nicos.taco.core.TacoDevice, nicos.core.device.HasLimits, nicos.core.device.Moveable

Bases: TacoDevice, HasLimits, Moveable

Device object for an iseg HVPS. The channel parameter must be 1 for a HVS with only one output.

Parameters

channel (an integer in the range [1, 3), mandatory in setup)

Channel of the Iseg HV (1 = A, 2 = B).

ramp (an integer in the range [1, 256), settable at runtime)

Voltage ramp. Default value: 1. Unit: main/s.

Parameters inherited from the base classes: abslimits, description, fixed, fmtstr, loglevel, lowlevel, maxage, pollinterval, tacodelay, tacodevice, tacotimeout, tacotries, target, unit, userlimits

notify Module

NICOS notification classes.

class nicos.notify.Jabberer(name, **config)

Bases: nicos.notify.Notifier

Bases: Notifier

Notifier to send Jabber notifications.

Needs the xmpp module.

Parameters

jid (str, mandatory in setup)

Jabber JID of the notifier.

password (str, mandatory in setup)

Password for the given JID.

receivers (a list of str, settable at runtime)

List of receiver JIDs. Default value: [].

Parameters inherited from the base classes: description, loglevel, lowlevel, minruntime

class nicos.notify.Mailer(name, **config)

Bases: nicos.notify.Notifier

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

copies (a list of str, settable at runtime)

Mail copy addresses. Default value: [].

receivers (a list of str, settable at runtime)

Mail receiver addresses. Default value: [].

sender (str, mandatory in setup)

Mail sender address.

subject (str)

Subject prefix. Default value: 'NICOS'.

Parameters inherited from the base classes: description, loglevel, lowlevel, minruntime

class nicos.notify.Notifier(name, **config)

Bases: nicos.core.device.Device

Bases: Device

Base class for all notification systems.

User methods

send(subject, body, what=None, short=None, important=True)

Send a notification.

sendConditionally(runtime, subject, body, what=None, short=None, important=True)

Send a notification if the given runtime is large enough.

Parameters

minruntime (float, settable at runtime)

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

class nicos.notify.SMSer(name, **config)

Bases: nicos.notify.Notifier

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

receivers (a list of str, settable at runtime)

SMS receiver phone numbers. Default value: [].

server (str, mandatory in setup)

Name of SMS server.

subject (str)

Body prefix. Default value: 'NICOS'.

Parameters inherited from the base classes: description, loglevel, lowlevel, minruntime

poller Module

Contains a process that polls devices automatically.

class nicos.poller.Poller(name, **config)

Bases: nicos.core.device.Device

Bases: Device

Parameters

alwayspoll (a list of str, mandatory in setup)

Setups whose devices should always be polled.

autosetup (bool)

True if all master setups should always be polled. Default value: True.

blacklist (a list of str)

Devices that should never be polled. Default value: [].

neverpoll (a list of str)

Setups that should never be polled, even if in master setup. Default value: [].

poll (a list of str)

Setups that should be polled if in master setup (only used if autosetup is false). Default value: [].

Parameters inherited from the base classes: description, loglevel, lowlevel

scan Module

Scan classes for NICOS.

class nicos.scan.ContinuousScan(device, start, end, speed, firstmoves=None, detlist=None, scaninfo=None)

Bases: nicos.scan.Scan

Bases: Scan

Special scan class for scans with one axis moving continuously (used for peak search).

run()
shortDesc()
class nicos.scan.ElapsedTime(name, **config)

Bases: nicos.core.device.Readable

Bases: Readable

Parameters inherited from the base classes: description, fmtstr, loglevel, lowlevel, maxage, pollinterval, unit

class nicos.scan.ManualScan(firstmoves=None, multistep=None, detlist=None, envlist=None, preset=None, scaninfo=None, scantype=None)

Bases: nicos.scan.Scan

Bases: Scan

Special scan class for “manual” scans.

manualBegin()
manualEnd()
step(**preset)
class nicos.scan.QScan(positions, firstmoves=None, multistep=None, detlist=None, envlist=None, preset=None, scaninfo=None, scantype=None)

Bases: nicos.scan.Scan

Bases: Scan

Special scan class for scans with a triple axis instrument in Q/E space.

beginScan()
shortDesc()
class nicos.scan.Scan(devices, positions, firstmoves=None, multistep=None, detlist=None, envlist=None, preset=None, scaninfo=None, scantype=None)

Bases: object

Represents a general scan over some devices with a specified detector.

addPoint(xvalues, yvalues)
beginScan()
endScan()
finishPoint()
handleError(what, dev, val, err)

Handle an error occurring during positioning or readout for a point.

This method can do several things:

  • re-raise the current exception to abort everything
  • raise StopScan to end the current scan with an error, but not raise an exception in the script
  • raise SkipPoint to skip current point and continue with next point
  • return: to ignore error and continue with current point
moveDevices(where)

Move to where, which is a list of (dev, position) tuples. On errors, call handleError, which decides when the scan may continue.

moveTo(position)

Move scan devices to position, a list of positions.

preparePoint(num, xvalues)
prepareScan(positions)
readEnvironment(start, finished)
readPosition()
run()
shortDesc()
class nicos.scan.SkipPoint

Bases: exceptions.Exception

Bases: Exception

Custom exception class to skip a scan point.

class nicos.scan.StopScan

Bases: exceptions.Exception

Bases: Exception

Custom exception class to stop the rest of the scan.

class nicos.scan.TimeScan(numsteps, firstmoves=None, multistep=None, detlist=None, envlist=None, preset=None, scaninfo=None, scantype=None)

Bases: nicos.scan.Scan

Bases: Scan

Special scan class for time scans with elapsed time counter.

endScan()
readEnvironment(started, finished)
shortDesc()
class nicos.scan.TwoDimScan(dev1, start1, step1, numsteps1, dev2, start2, step2, numsteps2, firstmoves=None, multistep=None, detlist=None, envlist=None, preset=None, scaninfo=None)

Bases: nicos.scan.Scan

Bases: Scan

Special scan class for two-dimensional scans.

preparePoint(num, xvalues)

taco_stubs Module

NICOS TACO stub implementation, to support running on systems without installed TACO libraries.

If this module is imported, it is assumed that the TACO client libraries already haven’t been found.

class nicos.taco_stubs.NICOSTACOStub(devname)

Bases: object

nicos.taco_stubs.generate()

toni Module

Toni-protocol device classes.

class nicos.toni.DelayBox(name, **config)

Bases: nicos.core.device.Moveable

Bases: Moveable

Toni TOFTOF-type programmable delay box.

Attached devices

bus

Toni communication bus. Type: ModBus.

Parameters

addr (an integer in the range [240, 256), mandatory in setup)

Bus address of the supply controller.

Parameters inherited from the base classes: description, fixed, fmtstr, loglevel, lowlevel, maxage, pollinterval, target, unit

class nicos.toni.LVPower(name, **config)

Bases: nicos.core.device.Moveable

Bases: Moveable

Toni TOFTOF-type low-voltage power supplies.

Attached devices

bus

Toni communication bus. Type: ModBus.

Parameters

addr (an integer in the range [240, 256), mandatory in setup)

Bus address of the supply controller.

Parameters inherited from the base classes: description, fixed, fmtstr, loglevel, lowlevel, maxage, pollinterval, target, unit

class nicos.toni.Leckmon(name, **config)

Bases: nicos.core.device.Readable

Bases: Readable

Attached devices

bus

Toni communication bus. Type: ModBus.

Parameters

addr (int, mandatory in setup)

Bus address of monitor.

Parameters inherited from the base classes: description, fmtstr, loglevel, lowlevel, maxage, pollinterval, unit

class nicos.toni.ModBus(name, **config)

Bases: nicos.taco.core.TacoDevice, nicos.core.device.Device

Bases: TacoDevice, Device

Parameters

maxtries (int)

Maximum tries before raising. Default value: 5.

source (int)

Source address of host. Default value: 0.

Parameters inherited from the base classes: description, loglevel, lowlevel, tacodelay, tacodevice, tacotimeout, tacotries

class nicos.toni.Ratemeter(name, **config)

Bases: nicos.core.device.Readable

Bases: Readable

Toni ratemeter inside a “crate”.

Attached devices

bus

Toni communication bus. Type: ModBus.

Parameters

addr (an integer in the range [240, 256), mandatory in setup)

Bus address of crate.

Parameters inherited from the base classes: description, fmtstr, loglevel, lowlevel, maxage, pollinterval, unit

class nicos.toni.Vacuum(name, **config)

Bases: nicos.core.device.Readable

Bases: Readable

Toni vacuum gauge ITR90 read out system.

Attached devices

bus

Toni communication bus. Type: ModBus.

Parameters

addr (an integer in the range [240, 256), mandatory in setup)

Bus address of the valve control.

channel (an integer in the range [0, 4), mandatory in setup)

Channel of the vacuum gauge.

power (an integer in the range [0, 2), settable at runtime)

True if the readout is switched on. Default value: 0.

Parameters inherited from the base classes: description, fmtstr, loglevel, lowlevel, maxage, pollinterval, unit

class nicos.toni.Valve(name, **config)

Bases: nicos.core.device.Moveable

Bases: Moveable

Attached devices

bus

Toni communication bus. Type: ModBus.

Parameters

addr (int, mandatory in setup)

Bus address of the valve control.

channel (an integer in the range [0, 8), mandatory in setup)

Channel of the valve.

states (a list of str)

Names for the closed/open states. Default value: ['off', 'on'].

waittime (float)

Time to wait after switching. Default value: 4. Unit: s.

Parameters inherited from the base classes: description, fixed, fmtstr, loglevel, lowlevel, maxage, pollinterval, target, unit

Subpackages