Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(api): allow custom user offsets for deck configured trash bins and waste chute #14560

Merged
merged 16 commits into from
Mar 1, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
docstrings for top() methods
  • Loading branch information
ecormany committed Feb 29, 2024
commit 76c80dc48e4c739906eff19fbdcf317b8a1bd660
22 changes: 19 additions & 3 deletions api/src/opentrons/protocol_api/_disposal_locations.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,14 @@ def __init__(
self._cutout_fixture_name = _TRASH_BIN_CUTOUT_FIXTURE

def top(self, x: float = 0, y: float = 0, z: float = 0) -> TrashBin:
"""Returns a trash bin with a user set offset."""
"""Add a location offset to a trash bin.

The default location (``x``, ``y``, and ``z`` all set to ``0``) is the center of
the bin on the x- and y-axes, and slightly below its physical top on the z-axis.

Offsets can be positive or negative and are measured in mm.
See :ref:`protocol-api-deck-coords`.
"""
return TrashBin(
location=self._location,
addressable_area_name=self._addressable_area_name,
Expand All @@ -110,7 +117,7 @@ def top(self, x: float = 0, y: float = 0, z: float = 0) -> TrashBin:

@property
def offset(self) -> DisposalOffset:
"""Current offset of the trash bin..
"""Current offset of the trash bin.

:meta private:

Expand Down Expand Up @@ -168,7 +175,16 @@ def __init__(
self._offset = offset

def top(self, x: float = 0, y: float = 0, z: float = 0) -> WasteChute:
"""Returns a waste chute with a user set offset."""
"""Add a location offset to a waste chute.

The default location (``x``, ``y``, and ``z`` all set to ``0``) is the center of
the chute's opening on the x- and y-axes, and slightly below its physical top
on the z-axis. See :ref:`configure-waste-chute` for more information on possible
configurations of the chute.

Offsets can be positive or negative and are measured in mm.
See :ref:`protocol-api-deck-coords`.
"""
return WasteChute(
engine_client=self._engine_client,
api_version=self._api_version,
Expand Down
Loading