11from abc import ABCMeta , abstractmethod
22from dataclasses import dataclass
3- from typing import Optional , Union
3+ from typing import Dict , Optional , Union
44
55from pylabrobot .arms .precise_flex .coords import PreciseFlexCartesianCoords
6- from pylabrobot .arms .standard import JointCoords
76from pylabrobot .machines .backend import MachineBackend
87
98
@@ -78,20 +77,20 @@ async def move_to_safe(self) -> None:
7877 @abstractmethod
7978 async def approach (
8079 self ,
81- position : Union [PreciseFlexCartesianCoords , JointCoords ],
80+ position : Union [PreciseFlexCartesianCoords , Dict [ int , float ] ],
8281 access : Optional [AccessPattern ] = None ,
8382 ) -> None :
8483 """Move the arm to an approach position (offset from target).
8584
8685 Args:
87- position: Target position (CartesianCoords or JointCoords )
86+ position: Target position (CartesianCoords or joint position dict )
8887 access: Access pattern defining how to approach the target. Defaults to VerticalAccess() if not specified.
8988 """
9089
9190 @abstractmethod
9291 async def pick_up_resource (
9392 self ,
94- position : Union [PreciseFlexCartesianCoords , JointCoords ],
93+ position : Union [PreciseFlexCartesianCoords , Dict [ int , float ] ],
9594 plate_width : float ,
9695 access : Optional [AccessPattern ] = None ,
9796 ) -> None :
@@ -105,7 +104,7 @@ async def pick_up_resource(
105104 @abstractmethod
106105 async def drop_resource (
107106 self ,
108- position : Union [PreciseFlexCartesianCoords , JointCoords ],
107+ position : Union [PreciseFlexCartesianCoords , Dict [ int , float ] ],
109108 access : Optional [AccessPattern ] = None ,
110109 ) -> None :
111110 """Place a plate at the specified position.
@@ -116,11 +115,11 @@ async def drop_resource(
116115 """
117116
118117 @abstractmethod
119- async def move_to (self , position : Union [PreciseFlexCartesianCoords , JointCoords ]) -> None :
118+ async def move_to (self , position : Union [PreciseFlexCartesianCoords , Dict [ int , float ] ]) -> None :
120119 """Move the arm to a specified position in 3D space or in joint space."""
121120
122121 @abstractmethod
123- async def get_joint_position (self ) -> JointCoords :
122+ async def get_joint_position (self ) -> Dict [ int , float ] :
124123 """Get the current position of the arm in joint space."""
125124
126125 @abstractmethod
0 commit comments