Glossary
Here are some commonly used Malcolm terms.
Attribute
An Attribute
is the interface to an object attached to a Block that holds a
current value with alarm and timeStamp and some meta information. If writeable
it can accept Put
requests to run a remote procedure. It is a user centred
view, backed by an AttributeModel
to hold the data.
Introduced in the Counter Tutorial.
Block
A Block
is the interface to a single object with Methods and
Attributes. It is a user centred view, backed by a BlockModel
to hold the data.
Introduced in the Hello World Tutorial.
ClientComms
A ClientComms
is a special Controller that provides access to remote
Blocks hosted by another Malcolm Process with a ServerComms.
Introduced in the Hello World Tutorial.
Context
A Context
is a utility object that can make a Block View for any
Controller in the current Malcolm Process. It is also used by these Views
for calling Methods and Putting to Attributes in a synchronous and asynchronous
fashion, and managing the returns from these requests in an ordered fashion.
Introduced breifly in the Hello World Tutorial, then in more depth in the Motion Tutorial.
Controller
A Controller
is responsible for making a Block View on request, possibly
synchronizing its state with some hardware.
Introduced in the Hello World Tutorial.
Design
A JSON file that describes the settings of a Block in the Device Layer or the Scan Layer. It is generated by storing the values of all config tagged Attributes of each child Block.
Introduced in the Motion Tutorial.
Device Layer
Middle level of Block, corresponding to a simple device like a Motion Controller, exposing a few Methods, or more complex device like a Detector, exposing a configure/run interface. They manage a number of Blocks in the Hardware Layer.
Introduced in the Motion Tutorial and expanded on in the Detector Tutorial.
Exports
An Attribute of a ManagerController
, this allows promoting of child
Attributes and Methods to the parent. It can be used
to define an interface for a top level part like the PandAPcompPart
to use,
while allowing flexibility of the exact layout of the Block design.
Introduced in the PandA Master Tutorial.
Future
A Future
represents the result of an asynchronous computation. It is typically
returned by a Context or a Block View when using one of its _async
methods to call a Method or Put to an Attribute without waiting for it
to complete.
Introduced in the Scanning Tutorial.
Hardware Layer
Contains the lowest level of Block, providing an interface that directly exposes the Attributes that the hardware provides.
Introduced in the Motion Tutorial.
Hook
A Hook
is an object created by a Controller that Parts can
register with so that arbitrary logic is run concurrently during specific times
in Controller Methods.
Introduced in the Detector Tutorial.
Include
A YAML file containing a number of Part and child Block definitions that can be used in the creation of a new Block. Typically used when there is a repeated pattern of components that are used in the construction of many different Block types.
Introduced in the AreaDetector Tutorial.
Info
An Info
is an object created by a Part that is passed up to its parent
Controller in response to a Hook or asynchronously by the call of
PartRegistrar.report()
. These may they be passed back down to all the
children of the Controller via another Hook.
Introduced in the Detector Tutorial.
Initial Design
This is the Design that will be loaded to a Block in the Device Layer or Scan Layer when Malcolm starts up.
Introduced in the AreaDetector Tutorial.
Method
A Method
is the interface to an object attached to a Block that holds meta
information about what arguments it takes and receives, and can accept Post
requests to run a remote procedure. It is a user centred view, backed by a
MethodModel
to hold the data.
Introduced in the Hello World Tutorial.
mri
Malcolm Resource Identifier. A unique name for a Controller within a Process that becomes the way clients ask for a particular Block.
Introduced in the Hello World Tutorial.
Part
A Part
is attached to a Controller, and is also able to contribute
Methods and Attributes to the Controller’s Block.
It can also register to be run at specific times during Controller Methods to
contribute logic.
Introduced in the Hello World Tutorial.
Process
A Malcolm Process
hosts a number of Controller instances that can handle
requests meant for a particular Block.
Introduced in the Hello World Tutorial.
Process Definition
The top level YAML file which defines the Blocks that will be hosted by a single Malcolm Process. This will only instantiate blocks defined in other YAML files and optionally provide one or more defines. This file may not contain controllers or parts.
A process definition file is passed to imalcolm.py at startup via a command line parameter.
Introduced in the Hello World Tutorial.
Scan Layer
Top level of Block, corresponding to a combination of Devices making up a scan.
Introduced in the Scanning Tutorial.
ServerComms
A ServerComms
is a special Controller that provides access to the Blocks hosted by the current Malcolm Process.
Introduced in the Hello World Tutorial.
Template Design
A read-only Design that is provide by Malcolm itself. It always starts
with the string template_
. It can either be a sensible set of defaults for a
particular Block that can be used as is (like template_hardware_gate
for a
detector) or act as a starting point for a user design (like template_pcomp
for a PandA).
Introduced in the AreaDetector Tutorial.