mxcubecore.HardwareObjects.abstract.AbstractShutter#

AbstractShutter class - interface for shutter type devices. Define open/close methods and is_open property. Overload BaseValueEnum

Classes

AbstractShutter(name)

Abstract base class for shutter type objects.

BaseValueEnum(value)

Defines only the compulsory values.

class mxcubecore.HardwareObjects.abstract.AbstractShutter.AbstractShutter(name: str)[source]#

Bases: AbstractNState

Abstract base class for shutter type objects.

Parameters:

name (str) –

VALUES#

alias of BaseValueEnum

close(timeout=None)[source]#

Close the shutter. :param timeout: optional - timeout [s],

If timeout == 0: return at once and do not wait if timeout is None: wait forever.

property is_closed: bool#

Check if the shutter is closed.

Note that it is not always true that is_closed != is_open, it takes time to open and close the shutter.

Many shutters can be in “moving” state. When in that state the shutter is both “not open” and “not closed”.

Returns:

True if closed, False otherwise.

property is_open: bool#

Check if the shutter is open. :returns: True if open, False otherwise. :rtype: (bool)

open(timeout=None)[source]#

Open the shutter. :param timeout: optional - timeout [s],

If timeout == 0: return at once and do not wait if timeout is None: wait forever.

class mxcubecore.HardwareObjects.abstract.AbstractShutter.BaseValueEnum(value)[source]#

Bases: Enum

Defines only the compulsory values.