13def generate_move_group_test_description(*args, gtest_name: SomeSubstitutionsType):
16 .robot_description(file_path=
"config/panda.urdf.xacro")
17 .trajectory_execution(file_path=
"config/gripper_moveit_controllers.yaml")
21 moveit_config.planning_pipelines[
"ompl"][
"panda_arm"][
22 "enforce_constrained_state_space"
24 moveit_config.planning_pipelines[
"ompl"][
"panda_arm"][
25 "projection_evaluator"
26 ] =
"joints(panda_joint1,panda_joint2)"
29 run_move_group_node = Node(
30 package=
"moveit_ros_move_group",
31 executable=
"move_group",
33 parameters=[moveit_config.to_dict()],
39 executable=
"static_transform_publisher",
40 name=
"static_transform_publisher",
42 arguments=[
"0.0",
"0.0",
"0.0",
"0.0",
"0.0",
"0.0",
"world",
"panda_link0"],
46 robot_state_publisher = Node(
47 package=
"robot_state_publisher",
48 executable=
"robot_state_publisher",
49 name=
"robot_state_publisher",
51 parameters=[moveit_config.robot_description],
55 ros2_controllers_path = os.path.join(
56 get_package_share_directory(
"moveit_resources_panda_moveit_config"),
58 "ros2_controllers.yaml",
60 ros2_control_node = Node(
61 package=
"controller_manager",
62 executable=
"ros2_control_node",
63 parameters=[ros2_controllers_path],
65 (
"/controller_manager/robot_description",
"/robot_description"),
70 joint_state_broadcaster_spawner = Node(
71 package=
"controller_manager",
74 "joint_state_broadcaster",
75 "--controller-manager",
76 "/controller_manager",
80 panda_arm_controller_spawner = Node(
81 package=
"controller_manager",
83 arguments=[
"panda_arm_controller",
"-c",
"/controller_manager"],
86 panda_hand_controller_spawner = Node(
87 package=
"controller_manager",
89 arguments=[
"panda_hand_controller",
"-c",
"/controller_manager"],
93 ompl_constraint_test = launch_ros.actions.Node(
94 executable=PathJoinSubstitution(
95 [LaunchConfiguration(
"test_binary_dir"), gtest_name]
98 moveit_config.robot_description,
99 moveit_config.robot_description_semantic,
100 moveit_config.robot_description_kinematics,
105 return launch.LaunchDescription(
107 launch.actions.DeclareLaunchArgument(
108 name=
"test_binary_dir",
109 description=
"Binary directory of package "
110 "containing test executables",
114 robot_state_publisher,
116 joint_state_broadcaster_spawner,
117 panda_arm_controller_spawner,
118 panda_hand_controller_spawner,
119 TimerAction(period=2.0, actions=[ompl_constraint_test]),
120 launch_testing.actions.ReadyToTest(),
123 "run_move_group_node": run_move_group_node,
124 "static_tf": static_tf,
125 "robot_state_publisher": robot_state_publisher,
126 "ros2_control_node": ros2_control_node,
127 "ompl_constraint_test": ompl_constraint_test,