pulling some changes from x10sa

- bugfix: hexiposi missing "self." for method call
- pretend dry for development
- bugfix: ensure cryojet retracted in trash sample
- typos and whitespace
This commit is contained in:
2023-04-26 09:29:10 +02:00
parent 91c9b36cfb
commit 609a87a986
5 changed files with 31 additions and 4 deletions
+1 -1
View File
@@ -120,7 +120,7 @@ class Hexiposi(DiscretePositionerBase):
def assert_in_position(self, pos):
if not is_in_position(pos):
if not self.is_in_position(pos):
raise Exception ("Hexiposi is not in position")
def assert_homed(self):
-1
View File
@@ -115,7 +115,6 @@ def is_gripper_really_empty(timeout=2.0):
timeout = timeout + time.time()
while time.time() < timeout:
if robot.eval_bool("diToolHasSample"):
print "test"
time.sleep(0.10)
else:
return True
+2 -2
View File
@@ -14,7 +14,7 @@ def release_safety():
if air_pressure_ok.take() != True:
raise Exception("Cannot release safety: air preassure not ok")
if n2_pressure_ok.take() != True:
raise Exception("Cannot release safety: n2 pressure not ok")
raise Exception("Cannot release safety: N2 pressure not ok")
auto = not is_manual_mode()
if auto:
if feedback_psys_safety.read() == False:
@@ -177,4 +177,4 @@ def is_pin_detected_in_scanner():
return False
if abs(s-av) > 0.1:
return False
return True
return True
+7
View File
@@ -21,6 +21,13 @@ def trash_sample():
enable_motion()
robot.move_gonio()
curpos = cryopos.getPosition()
speed = cryopos.getSpeed() / 1000.0
movetime = int(round(3000 + (15. - curpos) / speed))
cryopos.move(15.0, movetime)
cryopos.waitValueInRange(15.0, 1.0, movetime)
robot.get_gonio()
robot.move_heater(to_bottom = False)
robot.move_heater(to_bottom = True)
+21
View File
@@ -0,0 +1,21 @@
###
### run this file to replace the real dry() function
### with this fake version when TESTING ONLY!!!!!!
###
def dry(heat_time=None, speed=None, wait_cold = None):
"""run this file to replace the real dry() function
with this fake version when TESTING ONLY!!!!!!
"""
print "#################################"
print "## PRETENDING to DRY real fast ##"
print "#################################"
def _test_update_mount_counts(count=0):
global samples_info
for _s in samples_info:
_s["sampleMountCount"] = count
print "sample %s mounted %d times" % (_s["puckAddress"], _s["sampleMountCount"])