Skip to content

Commit 17dd1bd

Browse files
committed
[cytation] only wait when position actually changes
1 parent 8e2f71e commit 17dd1bd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pylabrobot/plate_reading/biotek_backend.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -918,7 +918,8 @@ async def set_position(self, x: float, y: float):
918918
relative_y_str = str(round(relative_y * 100 * 0.984)).zfill(6)
919919
await self.send_command("Y", f"O01{relative_y_str}")
920920

921-
self._pos_x, self._pos_y = x, y
921+
if relative_x != 0 or relative_y != 0:
922+
await asyncio.sleep(0.1)
922923

923924
def set_auto_focus_search_range(self, min_focal_height: float, max_focal_height: float):
924925
self._auto_focus_search_range = (min_focal_height, max_focal_height)
@@ -1297,7 +1298,6 @@ def image_size(magnification: float) -> Tuple[float, float]:
12971298
images: List[Image] = []
12981299
for x_pos, y_pos in positions:
12991300
await self.set_position(x=x_pos, y=y_pos)
1300-
await asyncio.sleep(0.1)
13011301
t0 = time.time()
13021302
images.append(
13031303
await self._acquire_image(

0 commit comments

Comments
 (0)