Skip to content

Commit c9bdf2f

Browse files
committed
[cytation] timeout based on exposure time
1 parent 17dd1bd commit c9bdf2f

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

pylabrobot/plate_reading/biotek_backend.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1191,10 +1191,8 @@ async def _acquire_image(
11911191
raise RuntimeError(f"Failed to execute software trigger after {num_trigger_tries} attempts")
11921192

11931193
try:
1194-
t0 = time.time()
1195-
image_result = self.cam.GetNextImage(1000)
1196-
t1 = time.time()
1197-
logger.debug("[cytation5] GetNextImage took %.2f seconds", t1 - t0)
1194+
timeout = int(self.cam.ExposureTime.GetValue() / 1000 + 1000) # from example
1195+
image_result = self.cam.GetNextImage(timeout)
11981196
if not image_result.IsIncomplete():
11991197
t0 = time.time()
12001198
processor = PySpin.ImageProcessor()

0 commit comments

Comments
 (0)