Package SpecClient :: Module SpecMotor :: Class SpecMotor
[hide private]
[frames] | no frames]

Class SpecMotor

source code

Spec Motor

Instance Methods [hide private]
 
__init__(self, specName=None, specVersion=None, timeout=None)
Constructor
source code
 
connectToSpec(self, specName, specVersion, timeout=None)
Connect to a remote Spec
source code
 
unusable(self)
Return whether the motor is unusable or not.
source code
 
lowLimitHit(self)
Return if low limit has been hit.
source code
 
highLimitHit(self)
Return if high limit has been hit.
source code
 
move(self, absolutePosition)
Move the motor
source code
 
moveRelative(self, relativePosition) source code
 
moveToLimit(self, limit) source code
 
stop(self)
Stop the current motor
source code
 
stopMoveToLimit(self) source code
 
getPosition(self)
Return the current absolute position for the motor.
source code
 
setOffset(self, offset)
Set the motor offset value
source code
 
getOffset(self) source code
 
getSign(self) source code
 
getDialPosition(self) source code
 
getLimits(self) source code
Method Details [hide private]

__init__(self, specName=None, specVersion=None, timeout=None)
(Constructor)

source code 

Constructor

Keyword arguments: specName -- name of the motor in Spec (defaults to None) specVersion -- 'host:port' string representing a Spec server to connect to (defaults to None) timeout -- optional timeout for the connection (defaults to None)

connectToSpec(self, specName, specVersion, timeout=None)

source code 

Connect to a remote Spec

Block until Spec is connected or timeout occurs

Arguments: specName -- name of the motor in Spec specVersion -- 'host:port' string representing a Spec server to connect to timeout -- optional timeout for the connection (defaults to None)

move(self, absolutePosition)

source code 

Move the motor

Block until the move is finished

Arguments: absolutePosition -- position where to move the motor to

stop(self)

source code 

Stop the current motor

Send an 'abort' message to the remote Spec