Skip to content

Commit 35e9fe7

Browse files
refactor(api): only ignore stalls for downward portion of force pickup routine (#14725)
1 parent 4abe652 commit 35e9fe7

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

api/src/opentrons/hardware_control/ot3api.py

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2093,14 +2093,17 @@ async def _force_pick_up_tip(
20932093
) -> None:
20942094
for press in pipette_spec.tip_action_moves:
20952095
async with self._backend.motor_current(run_currents=press.currents):
2096-
target_down = target_position_from_relative(
2096+
target = target_position_from_relative(
20972097
mount, top_types.Point(z=press.distance), self._current_position
20982098
)
2099-
await self._move(target_down, speed=press.speed, expect_stalls=True)
2100-
if press.distance < 0:
2101-
# we expect a stall has happened during a downward movement into the tiprack, so
2102-
# we want to update the motor estimation
2103-
await self._update_position_estimation([Axis.by_mount(mount)])
2099+
if press.distance < 0:
2100+
# we expect a stall has happened during a downward movement into the tiprack, so
2101+
# we want to update the motor estimation
2102+
await self._move(target, speed=press.speed, expect_stalls=True)
2103+
await self._update_position_estimation([Axis.by_mount(mount)])
2104+
else:
2105+
# we should not ignore stalls that happen during the retract part of the routine
2106+
await self._move(target, speed=press.speed, expect_stalls=False)
21042107

21052108
async def _tip_motor_action(
21062109
self, mount: OT3Mount, pipette_spec: List[TipActionMoveSpec]

0 commit comments

Comments
 (0)