Skip to content

Commit 41ca9c5

Browse files
committed
add offset to LH.return_tips96
1 parent 372b76a commit 41ca9c5

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

pylabrobot/liquid_handling/backends/hamilton/STAR_backend.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2228,7 +2228,10 @@ async def drop_tips96(
22282228
if isinstance(drop.resource, TipRack):
22292229
tip_spot_a1 = drop.resource.get_item("A1")
22302230
position = tip_spot_a1.get_absolute_location() + tip_spot_a1.center() + drop.offset
2231-
position.z += 52.0
2231+
position.z = tip_spot_a1.parent.get_absolute_location().z + 1.45
2232+
# This should be the case for all normal hamilton tip carriers + racks
2233+
# In the future, we might want to make this more flexible
2234+
assert abs(position.z - 216.4) < 1e-6, f"z position must be 216.4, got {position.z}"
22322235
else:
22332236
position = self._position_96_head_in_resource(drop.resource) + drop.offset
22342237

pylabrobot/liquid_handling/liquid_handler.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1515,7 +1515,7 @@ def _get_96_head_origin_tip_rack(self) -> Optional[TipRack]:
15151515
raise RuntimeError("All tips must be from the same tip rack")
15161516
return tip_rack
15171517

1518-
async def return_tips96(self, allow_nonzero_volume: bool = False, **backend_kwargs):
1518+
async def return_tips96(self, allow_nonzero_volume: bool = False, offset: Coordinate = Coordinate.zero(), **backend_kwargs):
15191519
"""Return the tips on the 96 head to the tip rack where they were picked up.
15201520
15211521
Examples:
@@ -1539,6 +1539,7 @@ async def return_tips96(self, allow_nonzero_volume: bool = False, **backend_kwar
15391539
return await self.drop_tips96(
15401540
tip_rack,
15411541
allow_nonzero_volume=allow_nonzero_volume,
1542+
offset=offset,
15421543
**backend_kwargs,
15431544
)
15441545

0 commit comments

Comments
 (0)