From: Walter Fetter Lages Date: Mon, 20 Mar 2023 01:17:36 +0000 (-0300) Subject: Port to Humble. X-Git-Url: http://git.ece.ufrgs.br/?a=commitdiff_plain;h=5b8e833b4bdb1a1a45a556bb9b69c16879066b0a;p=trajectory_conversions.git Port to Humble. --- diff --git a/CMakeLists.txt b/CMakeLists.txt index d3e7f35..0722782 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -12,8 +12,8 @@ find_package(std_msgs REQUIRED) find_package(geometry_msgs REQUIRED) find_package(tf2_msgs REQUIRED) find_package(trajectory_msgs REQUIRED) -find_package(tf2_kdl REQUIRED) find_package(urdf REQUIRED) +find_package(tf2_kdl REQUIRED) find_package(kdl_parser REQUIRED) find_package(orocos_kdl REQUIRED) @@ -27,9 +27,10 @@ ament_target_dependencies( "rclcpp" "std_msgs" "geometry_msgs" + "tf2_msgs" "trajectory_msgs" - "tf2_kdl" "urdf" + "tf2_kdl" "kdl_parser" "orocos_kdl" ) @@ -53,10 +54,11 @@ install(TARGETS pose_stamped2joint pose_stamped2tf if(BUILD_TESTING) find_package(ament_lint_auto REQUIRED) # the following line skips the linter which checks for copyrights - # uncomment the line when a copyright and license is not present in all source files + # comment the line when a copyright and license is added to all source files #set(ament_cmake_copyright_FOUND TRUE) # the following line skips cpplint (only works in a git repo) - # uncomment the line when this package is not in a git repo + # comment the line when this package is in a git repo and when + # a copyright and license is added to all source files #set(ament_cmake_cpplint_FOUND TRUE) ament_lint_auto_find_test_dependencies() endif() diff --git a/package.xml b/package.xml index 431ef94..6b59087 100644 --- a/package.xml +++ b/package.xml @@ -2,10 +2,10 @@ trajectory_conversions - 2.0.0 - Trajectory Conversions + 2.1.0 + Trajectory conversions Walter Fetter Lages - GPLv3 + GPL-3.0-only ament_cmake diff --git a/src/pose_stamped2joint.cpp b/src/pose_stamped2joint.cpp index 4cc6f0b..ae6d1f3 100644 --- a/src/pose_stamped2joint.cpp +++ b/src/pose_stamped2joint.cpp @@ -27,7 +27,7 @@ #include #include #include -#include +#include #include class Pose2Joint: public rclcpp::Node @@ -51,10 +51,9 @@ class Pose2Joint: public rclcpp::Node Pose2Joint::Pose2Joint(const std::string &name,const std::string &root,const std::string &tip,const Eigen::Matrix &L): Node(name), q_(0) { - using std::placeholders::_1; rclcpp::QoS qos(rclcpp::KeepLast(1)); qos.transient_local(); - auto robotDescriptionSubscriber_=create_subscription("robot_description",qos,std::bind(&Pose2Joint::robotDescriptionCB,this,_1)); + auto robotDescriptionSubscriber_=create_subscription("robot_description",qos,std::bind(&Pose2Joint::robotDescriptionCB,this,std::placeholders::_1)); while(robotDescription_.empty()) { RCLCPP_WARN_STREAM_SKIPFIRST_THROTTLE(get_logger(),*get_clock(),1000,"Waiting for robot model on /robot_description."); @@ -69,7 +68,7 @@ Pose2Joint::Pose2Joint(const std::string &name,const std::string &root,const std q_.resize(chain_.getNrOfJoints()); jointTrajPointPub_=create_publisher("joint_trajectory_point",10); - poseSub_=create_subscription("/pose",10,std::bind(&Pose2Joint::poseCB,this,_1)); + poseSub_=create_subscription("/pose",10,std::bind(&Pose2Joint::poseCB,this,std::placeholders::_1)); } void Pose2Joint::poseCB(const geometry_msgs::msg::PoseStamped::SharedPtr poseStamped) diff --git a/src/pose_stamped2tf.cpp b/src/pose_stamped2tf.cpp index 03d4c5f..0834e7f 100644 --- a/src/pose_stamped2tf.cpp +++ b/src/pose_stamped2tf.cpp @@ -38,8 +38,7 @@ class PoseStampedToTf: public rclcpp::Node PoseStampedToTf::PoseStampedToTf(const char *node_name,const char *child_frame_id): Node(node_name) { child_frame_id_=child_frame_id; - using std::placeholders::_1; - poseSubscriber_=create_subscription("pose",10,std::bind(&PoseStampedToTf::poseStampedCB,this,_1)); + poseSubscriber_=create_subscription("pose",10,std::bind(&PoseStampedToTf::poseStampedCB,this,std::placeholders::_1)); tfPublisher_=create_publisher("/tf",10); }