genericroboticarm.robo_APIs package¶
Subpackages¶
- genericroboticarm.robo_APIs.dorna package
- genericroboticarm.robo_APIs.joyit package
- genericroboticarm.robo_APIs.precise_flex package
- Submodules
- genericroboticarm.robo_APIs.precise_flex.errors module
- genericroboticarm.robo_APIs.precise_flex.imager_pf module
- genericroboticarm.robo_APIs.precise_flex.movement_profiles module
- genericroboticarm.robo_APIs.precise_flex.pf_implementation module
- genericroboticarm.robo_APIs.precise_flex.pf_on_rail module
- genericroboticarm.robo_APIs.precise_flex.pf_simulation module
- genericroboticarm.robo_APIs.precise_flex.uppsala_pf_on_rail module
- Module contents
PFImplementationPFImplementation.GRIPPER_CLOSEDPFImplementation.GRIPPER_OPENPFImplementation.MAX_Z_COORDINATEPFImplementation._abc_implPFImplementation.cancel_transfer()PFImplementation.current_coordinatesPFImplementation.currently_gripping_platePFImplementation.finish_movement()PFImplementation.get_labware()PFImplementation.get_name()PFImplementation.get_used_cli_args()PFImplementation.grip_close()PFImplementation.grip_open()PFImplementation.init_connection()PFImplementation.joint_namesPFImplementation.last_gripper_destinationPFImplementation.move_joint()PFImplementation.move_relative()PFImplementation.move_to_coordinates()PFImplementation.move_to_position()PFImplementation.namePFImplementation.number_internal_positionsPFImplementation.prepare_for_input()PFImplementation.prepare_for_output()PFImplementation.put_labware()PFImplementation.run_custom_command()PFImplementation.send_command()PFImplementation.set_acceleration()PFImplementation.set_speed()PFImplementation.socketPFImplementation.stop_moving()PFImplementation.use_move_profile()
PFonRail
- Submodules
- genericroboticarm.robo_APIs.xfactory package
Submodules¶
- genericroboticarm.robo_APIs.dummy_robot module
- genericroboticarm.robo_APIs.dynamic_loader module
- genericroboticarm.robo_APIs.interactive_transfer module
InteractiveTransferInteractiveTransfer._abc_implInteractiveTransfer._announced_intermediate_actionsInteractiveTransfer.announce_intermediate_actions()InteractiveTransfer.announced_intermediate_actionsInteractiveTransfer.available_handover_positionsInteractiveTransfer.available_intermediate_actionsInteractiveTransfer.cancel_transfer()InteractiveTransfer.get_labware()InteractiveTransfer.number_internal_positionsInteractiveTransfer.preparable_intermediate_actionsInteractiveTransfer.prepare_for_input()InteractiveTransfer.prepare_for_output()InteractiveTransfer.put_labware()
- genericroboticarm.robo_APIs.robo_interface module
RoboInterfaceRoboInterface._abc_implRoboInterface._deferred_failureRoboInterface._deferred_tailRoboInterface.current_coordinatesRoboInterface.current_positionRoboInterface.currently_gripping_plateRoboInterface.defer()RoboInterface.end_connection()RoboInterface.get_name()RoboInterface.get_used_cli_args()RoboInterface.graph_dirRoboInterface.grip_close()RoboInterface.grip_open()RoboInterface.init_connection()RoboInterface.joint_namesRoboInterface.move_relative()RoboInterface.move_straight_to_position()RoboInterface.move_to_coordinates()RoboInterface.move_to_nearest_known_position()RoboInterface.move_to_position()RoboInterface.nameRoboInterface.next_positionsRoboInterface.pick_at_position()RoboInterface.pick_from_device()RoboInterface.place_at_device()RoboInterface.place_at_position()RoboInterface.pop_deferred()RoboInterface.report_deferred_failure()RoboInterface.run_custom_command()RoboInterface.set_acceleration()RoboInterface.set_metrik()RoboInterface.set_speed()RoboInterface.site_to_position_identifier()RoboInterface.stop_moving()RoboInterface.take_deferred_failure()
finish_successfully()
Module contents¶
- class genericroboticarm.robo_APIs.InteractiveRobot(start_simulating: bool = True, **kwargs)[source]¶
Bases:
RoboInterface,InteractiveTransfer,ABC- _abc_impl = <_abc._abc_data object>¶
- class genericroboticarm.robo_APIs.InteractiveTransfer[source]¶
Bases:
ABC- _abc_impl = <_abc._abc_data object>¶
- _announced_intermediate_actions: List[str] = []¶
- announce_intermediate_actions(intermediate_actions: List[str])[source]¶
Tells the arm which intermediate actions the upcoming transfer command will request, so that prepare_for_input() can already do the part of them that concerns only the arm. Announcing is optional and non-binding: the actions are passed to get_labware() as usual, which has to work whether they were announced or not. :param intermediate_actions: :return:
- property announced_intermediate_actions: List[str]¶
The intermediate actions announced for the upcoming transfer command. :return:
- property available_handover_positions: List[Tuple[str, int]]¶
return:
- property available_intermediate_actions: List[str]¶
- List of functionalities the arm can do together with put/get labware commands,
like (un-)lidding, shaking reading barcode, etc.
- Returns:
- abstractmethod get_labware(intermediate_actions: List[str], device: str, position: int)[source]¶
- Parameters:
position
device
intermediate_actions
- Returns:
- abstract property number_internal_positions: int¶
return:
- property preparable_intermediate_actions: List[str]¶
The subset of the available intermediate actions the arm can already work on during prepare_for_input(), provided they were announced beforehand. Fetching a lid is such an action: it concerns only the arm and can be done while the other device prepares itself. Arms that ignore announcements return nothing here. :return:
- abstractmethod prepare_for_input(internal_pos: int, device: str, position: int, plate_type: str) bool[source]¶
- Parameters:
plate_type
plate_type
position
device
internal_pos
- Returns:
- class genericroboticarm.robo_APIs.RoboInterface(start_simulating: bool = True, **kwargs)[source]¶
Bases:
ABC- _abc_impl = <_abc._abc_data object>¶
- _deferred_failure: BaseException | None¶
- _deferred_tail: Callable[[], None] | None¶
- abstract property current_coordinates: Dict[str, float]¶
return:
- current_position: str | None = None¶
- property currently_gripping_plate: bool¶
Whether the gripper currently holds a plate. Robots that cannot sense their gripper report False, so the guards against picking with an occupied gripper do not fire for them. Subclasses that can tell override this. :return:
- defer(tail_task: Callable[[], None]) None[source]¶
Registers work that may be executed after the running command has reported success, e.g. storing a lid away once the robot is clear of the device it just served. The robot stays reserved until the tail task is done, so the next command has to wait for it, but the client and the served device are released early. Only one tail task can be pending at a time. :param tail_task: the work to be done once the current command returned :return:
- abstractmethod classmethod get_name() str[source]¶
The name will be used as parameter in command line startup (-r), as sila server name and to save the position graph. :return: the name
- abstractmethod classmethod get_used_cli_args() dict[str, str][source]¶
Defines the arguments that are forwarded from the command line to the robots constructor. :return: a dictionary of type [constructor parameter name, command line argument name]
- graph_dir: Path | None = None¶
- abstract property joint_names: list[str]¶
Returns a list of names of the individual coordinates used by the robot. For example [x, y, z, roll, pitch, grip] or [j1, j2, j3, j4, j5] :return:
- abstractmethod move_relative(movements: List[Tuple[str, float]], **kwargs)[source]¶
- Parameters:
movements
- Returns:
- move_straight_to_position(identifier: str, offset: Dict[str, float] | None = None)[source]¶
Moves the robot straight to the specified position, i.e. queries its coordinates, adds the offset and call move_to_coordinates() on the result. :param offset: :param identifier: :return:
- abstractmethod move_to_coordinates(coords: Dict[str, float], **kwargs) None[source]¶
- Parameters:
coords
- Returns:
- move_to_position(target_position: str, offset: Dict[str, float] | None = None)[source]¶
- Parameters:
offset
target_position
- Returns:
- property name: str¶
- next_positions: List[str]¶
- pick_at_position(identifier: str, offset: Dict[str, float] | None = None)[source]¶
Opens the gripper, moves to a specified location and closes the gripper there :param identifier: Position identifier :param offset: :return:
- pick_from_device(device: str, pos: int, offset: Dict[str, float] | None = None)[source]¶
- Parameters:
device
pos
offset
- Returns:
- place_at_device(device: str, pos: int, offset: Dict[str, float] | None = None, plate_type: str = 'plate_type')[source]¶
- Parameters:
plate_type
device
pos
offset
- Returns:
- place_at_position(identifier: str, offset: Dict[str, float] | None = None)[source]¶
Opens the gripper, moves to a specified location and opens the gripper there :param identifier: Position identifier :param offset: :return:
- pop_deferred() Callable[[], None] | None[source]¶
Returns the registered tail task, if any, and forgets about it. :return: the tail task or None
- report_deferred_failure(error: BaseException)[source]¶
Remembers that a tail task failed. Since its command has already reported success, the failure can only be handed to the next command touching the robot. :param error: :return:
- run_custom_command(cmd: str) str[source]¶
Runs a custom command on the hardware. The implementation for a specific hardware might look very different and the response must be a string. Be default returns ‘Not Implemented’. Use on your own risk. :param cmd: :return:
- genericroboticarm.robo_APIs.collect_robo_implementations(package: str = 'genericroboticarm.robo_APIs') set[type[RoboInterface]][source]¶
Recursively find all subclasses of RoboInterface in a package.
- Parameters:
package – Dotted path of the package
- Returns:
list of RoboInterface subclasses
- genericroboticarm.robo_APIs.get_arm_impl(impl_str: str) RoboInterface | None[source]¶
Dynamically imports the specified robotic arm implementation class.
- Parameters:
impl_str (str) – The robotic arm implementation class to use, formatted as <module>:<class>