2 from launch
import LaunchDescription
3 from launch.actions
import ExecuteProcess
4 from launch_ros.actions
import Node
5 from ament_index_python.packages
import get_package_share_directory
6 from moveit_configs_utils
import MoveItConfigsBuilder
7 from launch_param_builder
import ParameterBuilder
13 .robot_description(file_path=
"config/panda.urdf.xacro")
19 "moveit_servo": ParameterBuilder(
"moveit_servo")
20 .yaml(
"config/pose_tracking_settings.yaml")
21 .yaml(
"config/panda_simulated_config_pose_tracking.yaml")
28 +
"/config/demo_rviz_pose_tracking.rviz"
36 arguments=[
"-d", rviz_config_file],
37 parameters=[moveit_config.to_dict()],
41 robot_state_publisher = Node(
42 package=
"robot_state_publisher",
43 executable=
"robot_state_publisher",
45 parameters=[moveit_config.robot_description],
51 executable=
"static_transform_publisher",
52 name=
"static_transform_publisher",
54 arguments=[
"0.0",
"0.0",
"0.0",
"0.0",
"0.0",
"0.0",
"world",
"panda_link0"],
57 pose_tracking_node = Node(
58 package=
"moveit_servo",
59 executable=
"servo_pose_tracking_demo",
63 moveit_config.to_dict(),
69 ros2_controllers_path = os.path.join(
72 "ros2_controllers.yaml",
74 ros2_control_node = Node(
75 package=
"controller_manager",
76 executable=
"ros2_control_node",
77 parameters=[moveit_config.robot_description, ros2_controllers_path],
81 joint_state_broadcaster_spawner = Node(
82 package=
"controller_manager",
85 "joint_state_broadcaster",
86 "--controller-manager-timeout",
88 "--controller-manager",
89 "/controller_manager",
93 panda_arm_controller_spawner = Node(
94 package=
"controller_manager",
96 arguments=[
"panda_arm_controller",
"-c",
"/controller_manager"],
99 return LaunchDescription(
105 joint_state_broadcaster_spawner,
106 panda_arm_controller_spawner,
107 robot_state_publisher,
def get_package_share_directory(pkg_name)
def generate_launch_description()