diff --git a/src/pycram/process_modules/__init__.py b/src/pycram/process_modules/__init__.py index 30f5906a3..31d37839a 100644 --- a/src/pycram/process_modules/__init__.py +++ b/src/pycram/process_modules/__init__.py @@ -1,7 +1,7 @@ from .pr2_process_modules import Pr2Manager from .boxy_process_modules import BoxyManager from .donbot_process_modules import DonbotManager -from .hsr_process_modules import HSRBManager +from .hsrb_process_modules import HSRBManager from .default_process_modules import DefaultManager from .stretch_process_modules import StretchManager diff --git a/src/pycram/process_modules/hsr_process_modules.py b/src/pycram/process_modules/hsrb_process_modules.py similarity index 100% rename from src/pycram/process_modules/hsr_process_modules.py rename to src/pycram/process_modules/hsrb_process_modules.py diff --git a/src/pycram/robot_descriptions/__init__.py b/src/pycram/robot_descriptions/__init__.py index 3385fab74..7a40acb8b 100644 --- a/src/pycram/robot_descriptions/__init__.py +++ b/src/pycram/robot_descriptions/__init__.py @@ -5,7 +5,7 @@ from .boxy_description import BoxyDescription from .donbot_description import DonbotDescription -from .hsr_description import HSRDescription +from .hsrb_description import HSRBDescription from .pr2_description import PR2Description from .ur5_description import UR5Description from .tiago_description import TiagoDescription @@ -56,8 +56,8 @@ def update_robot_description(robot_name=None, from_ros=None): description = PR2Description elif 'boxy' in robot: description = BoxyDescription - elif 'hsr' in robot: - description = HSRDescription + elif 'hsrb' in robot: + description = HSRBDescription elif "ur5_robotiq" in robot: description = UR5Description elif "tiago_dual" in robot: diff --git a/src/pycram/robot_descriptions/hsr_description.py b/src/pycram/robot_descriptions/hsrb_description.py similarity index 83% rename from src/pycram/robot_descriptions/hsr_description.py rename to src/pycram/robot_descriptions/hsrb_description.py index 053a58b13..197d64e4c 100644 --- a/src/pycram/robot_descriptions/hsr_description.py +++ b/src/pycram/robot_descriptions/hsrb_description.py @@ -1,10 +1,9 @@ from ..robot_description import * -class HSRDescription(RobotDescription): +class HSRBDescription(RobotDescription): def __init__(self): - super().__init__("hsrb", "base_footprint", "base_link", "arm_lift_link", "arm_lift_joint") # Camera head_center_camera = CameraDescription("head_center_camera_frame", @@ -25,7 +24,7 @@ def __init__(self): # Neck neck_links = ["head_pan_link", "head_tilt_link"] neck_joints = ["head_pan_joint", "head_tilt_joint"] - neck_forward = {"forward": [0.0, 0.0], "down": [0.0, -0.7]} + neck_forward = {"forward": [0.0, 0.0], "down": [0.0, 0, -0.7]} neck_chain = ChainDescription("neck", neck_joints, neck_links, static_joint_states=neck_forward) self.add_chain("neck", neck_chain) # Arm @@ -33,17 +32,21 @@ def __init__(self): arm_links = ["arm_flex_link", "arm_roll_link", "wrist_flex_link", "wrist_roll_link"] arm_carry = {"park": [0, 1.5, -1.85, 0]} gripper_links = ["hand_l_distal_link", "hand_l_spring_proximal_link", "hand_palm_link", - "hand_r_distal_link", "hand_r_spring_proximal_link"] - gripper_joints = ["hand_motor_joint"] + "hand_r_distal_link", "hand_r_spring_proximal_link", "hand_gripper_tool_frame"] + gripper_joints = ["hand_l_proximal_joint", "hand_r_proximal_joint", "hand_motor_joint"] gripper = GripperDescription("gripper", gripper_links=gripper_links, gripper_joints=gripper_joints, gripper_meter_to_jnt_multiplier=1.0, gripper_minimal_position=0.0, gripper_convergence_delta=0.001) arm_chain = ChainDescription("left", arm_joints, arm_links, static_joint_states=arm_carry) arm_inter = InteractionDescription(arm_chain, "wrist_roll_link") - arm_manip = ManipulatorDescription(arm_inter, tool_frame="gripper_tool_frame", gripper_description=gripper) + arm_manip = ManipulatorDescription(arm_inter, tool_frame="hand_gripper_tool_frame", gripper_description=gripper) self.add_chain("left", arm_manip) self.add_static_gripper_chains("left", {"open": [0.3], "close": [0.0]}) + self.grasps = GraspingDescription( + {"front": [-1, 0, -1, 0], + "left": [0, -1, 1, 0], + "right": [0, -1, -1, 0.0], + "top": [-1, 0, 0, 0]}) - def get_camera_frame(self, name="head_center_camera"): - # TODO: Hacky since only one optical camera frame from pr2 is used + def get_camera_frame(self, name="head_center_camera_frame"): return super().get_camera_frame(name) \ No newline at end of file