mxcubecore.HardwareObjects.SardanaMotor

Classes

SardanaMotor(name)

SardanaMotorState(value[, names, module, ...])

class mxcubecore.HardwareObjects.SardanaMotor.SardanaMotor(name)[source]

Bases: AbstractMotor

get_limits()[source]
Descript.returns motor limits. If no limits channel defined then

static_limits is returned

get_state() → HardwareObjectState[source]

Get the motor state

Returns:

Motor state

Return type:

HardwareObjectState

get_value()[source]

Descript. : returns the current position

get_velocity()[source]

Read motor velocity. :returns: velocity [unit/s] :rtype: (float)

init()[source]

Initialise tolerance property

is_moving() → bool[source]
Returns:

True if the motor is currently moving

Return type:

bool

is_ready() → bool[source]
Returns:

True if the motor is ready

Return type:

bool

set_velocity(value)[source]

Set the motor velocity :param velocity: target velocity :type velocity: float

stop()[source]

Descript. : stops the motor immediately

wait_end_of_move(timeout: float = None) → None[source]

Wait till the motor stops

Parameters:

timeout (float)

Return type:

None

wait_ready(timeout=None)[source]

Wait timeout seconds till object is ready.

If timeout is None: wait forever.

Parameters:

timeout (Optional[float], optional) – Timeout (seconds). Defaults to None.

class mxcubecore.HardwareObjects.SardanaMotor.SardanaMotorState(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]

Bases: Enum