BaseInterface Tango Device

Provides the Tango interface for a base SKA device with an Operational State.

This class only provides the Tango interface required for SKA Tango devices which support an Operational State. It is up to subclasses to override various abstract methods to provide the appropriate behaviour and set the Operational State as appropriate, except for the initial state that is set in init_device().

The Operational State of an SKA Tango device is exposed as the built-in Tango device state via set_state(). Subclasses are not expected to call set_state() themselves. Instead, the state is driven automatically by calling init_invoked(), init_completed() and software_fault() from the appropriate places in the device implementation, which will additionally ensure that change and archive events are sent.

The Operational State of the BaseInterface only supports a subset of the DevState enumeration, with the following interpretations:

  • INIT: The device is initialising. Mandatory initial state for all devices.

  • ON: The Tango device is communicating with the system under control. Mandatory default state after initialisation has finished.

  • FAULT: The Tango device encountered a software fault/exception. Optional.

BaseInterface also provides the signals _admin_mode and _health_state as well as the corresponding Tango attributes adminMode and healthState, as well as healthInfo.

The adminMode Tango attribute is writable and should not be set by subclasses of this interface.

The healthState and healthInfo read-only attributes should be set by subclasses by calling report_health(). It is intended to provide information of the overall health of the device, based on the state of the component(s) it is monitoring.

Properties

BaseInterface.LoggingLevelDefault

Default logging level at device startup.

Data type:

DevUShort

Default value:

4

BaseInterface.LoggingTargetsDefault

Default logging targets at device startup.

Data type:

DevVarStringArray

Default value:

[‘tango::logger’]

Attributes

BaseInterface.State

The operational state of the device as enumeration.

Access:

READ

Data type:

DevState

Data format:

SCALAR

BaseInterface.Status

More detailed textual information about the device’s status.

Access:

READ

Data type:

DevString

Data format:

SCALAR

BaseInterface.adminMode

The Admin Mode of the device.

Set by a client to mark the device for science or only engineering.

Access:

READ_WRITE

Data type:

DevEnum

Data format:

SCALAR

BaseInterface.buildState

Read the Build State of the device.

Access:

READ

Data type:

DevString

Data format:

SCALAR

BaseInterface.healthInfo

Read the Health Info of the device.

It provides an explanation for the currently reported Health State

Access:

READ

Data type:

DevString

Data format:

SPECTRUM

Max_dim_x:

256

BaseInterface.healthState

Read the Health State of the device.

It interprets the current device condition and condition of all managed devices to set this.

Access:

READ

Data type:

DevEnum

Data format:

SCALAR

BaseInterface.loggingLevel

Read the logging level of the device.

Initialises to LoggingLevelDefault on startup. See LoggingLevel

Access:

READ_WRITE

Data type:

DevEnum

Data format:

SCALAR

BaseInterface.loggingTargets

Read the additional logging targets of the device.

Note that this excludes the handlers provided by the ska_ser_logging library defaults - initialises to LoggingTargetsDefault on startup.

Access:

READ_WRITE

Data type:

DevString

Data format:

SPECTRUM

Max_dim_x:

4

BaseInterface.versionId

Read the Version Id of the device.

Access:

READ

Data type:

DevString

Data format:

SCALAR

Commands

BaseInterface.GetVersionInfo() DevVarStringArray

Get the version information of the device.

Returns:

The device class name and its package information.

BaseInterface.Init() DevVoid

Reinitialise the Tango device.