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

Replace child_resource_location with child_location #364

Merged
merged 4 commits into from
Jan 20, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
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
2 changes: 1 addition & 1 deletion pylabrobot/incubators/cytomat/cytomat.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ async def send_command(self, command_type: str, command: str, params: str) -> st
raise Exception(f"Unknown response from cytomat: {resp}")

async def send_action(
self, command_type: str, command: str, params: str, timeout: Optional[int] = 10
self, command_type: str, command: str, params: str, timeout: Optional[int] = 60
) -> OverviewRegisterState:
"""Calls send_command, but has a timeout handler and returns the overview register state.
Args:
Expand Down
4 changes: 2 additions & 2 deletions pylabrobot/liquid_handling/liquid_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -1888,7 +1888,7 @@ async def drop_resource(
elif isinstance(destination, Coordinate):
to_location = destination
elif isinstance(destination, Tilter):
to_location = destination.get_absolute_location() + destination.child_resource_location
to_location = destination.get_absolute_location() + destination.child_location
elif isinstance(destination, PlateHolder):
if destination.resource is not None and destination.resource is not resource:
raise RuntimeError("Destination already has a plate")
Expand Down Expand Up @@ -1967,7 +1967,7 @@ async def drop_resource(
raise ValueError("Only ResourceStacks with direction 'z' are currently supported")
destination.assign_child_resource(resource)
elif isinstance(destination, Tilter):
destination.assign_child_resource(resource, location=destination.child_resource_location)
destination.assign_child_resource(resource, location=destination.child_location)
elif isinstance(destination, PlateAdapter):
if not isinstance(resource, Plate):
raise ValueError("Only plates can be moved to a PlateAdapter")
Expand Down
6 changes: 3 additions & 3 deletions pylabrobot/tilting/hamilton.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ def __init__(
self,
name: str,
com_port: str,
child_resource_location: Coordinate = Coordinate(1.0, 3.0, 83.55),
child_location: Coordinate = Coordinate(1.0, 3.0, 83.55),
pedestal_size_z: float = 3.47,
write_timeout: float = 3,
timeout: float = 3,
Expand All @@ -21,7 +21,7 @@ def __init__(

Args:
com_port: The communication port.
child_resource_location: The location of the child resource.
child_location: The location of the child resource.
pedestal_size_z: The size of the pedestal in the z dimension.
write_timeout: The write timeout. Defaults to 3.
timeout: The timeout. Defaults to 3.
Expand All @@ -38,7 +38,7 @@ def __init__(
timeout=timeout,
),
hinge_coordinate=Coordinate(6.18, 0, 72.85),
child_resource_location=child_resource_location,
child_location=child_location,
category="tilter",
model=HamiltonTiltModule.__name__,
)
Expand Down
4 changes: 2 additions & 2 deletions pylabrobot/tilting/tilter.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ def __init__(
size_z: float,
backend: TilterBackend,
hinge_coordinate: Coordinate,
child_resource_location: Coordinate,
child_location: Coordinate,
category: Optional[str] = None,
model: Optional[str] = None,
):
Expand All @@ -37,7 +37,7 @@ def __init__(
self.backend: TilterBackend = backend # fix type
self._absolute_angle: float = 0
self._hinge_coordinate = hinge_coordinate
self.child_resource_location = child_resource_location
self.child_location = child_location

@property
def absolute_angle(self) -> float:
Expand Down
Loading