Skip to content
Snippets Groups Projects
Commit a14390c0 authored by Generic Bliss account for Control Software's avatar Generic Bliss account for Control Software
Browse files

Cache attr_RobotSpeed_read

parent 8611f68b
Branches continue_spectrum_refactoring
No related tags found
No related merge requests found
......@@ -260,7 +260,7 @@ class TomoSampleChanger(Device):
self.robot_status_time = now
self.info_stream ("robot_status() at %d" % int(now))
self.status_lock = False
self.status_lock = False
# catch all exceptions, convert to Tango exception and rethrow
except:
......@@ -402,7 +402,7 @@ class TomoSampleChanger(Device):
self.attr_RemoteMode_read = False
self.attr_ParkingPosition_read = False
self.attr_SafetyChainOK_read = False
self.attr_RobotSpeed_read = "None"
# init flags for state and status
self.init_done = False
self.init_error = None
......@@ -567,8 +567,9 @@ class TomoSampleChanger(Device):
def get_speed(self):
# PROTECTED REGION ID(TomoSampleChanger.get_speed) ENABLED START #
speed = self.robot.accelForLargeMovesMultiplicator
return speed
if self.is_moving == False:
self.attr_RobotSpeed_read = self.robot.accelForLargeMovesMultiplicator
return self.attr_RobotSpeed_read
# PROTECTED REGION END # // TomoSampleChanger.get_speed
def set_speed(self, speed):
......@@ -793,6 +794,9 @@ class TomoSampleChanger(Device):
self.robot.emmergencyStopBlockingPrograms()
self.robot.powerOFF()
self.is_moving = False
self.is_error = True
# PROTECTED REGION END # // TomoSampleChanger.Abort
@command(
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment