Skip to content

Commit c6a0389

Browse files
authored
Merge branch 'moveit:main' into feature/free-path-generator
2 parents 440a77d + 0dd551d commit c6a0389

File tree

51 files changed

+527
-67
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+527
-67
lines changed

moveit_kinematics/test/test_kinematics_plugin.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
#include <memory>
4040
#include <functional>
4141
#include <pluginlib/class_loader.hpp>
42+
#include <rclcpp/executors/single_threaded_executor.hpp>
4243
#include <rclcpp/rclcpp.hpp>
4344
#include <tf2_eigen/tf2_eigen.hpp>
4445

@@ -403,7 +404,9 @@ TEST_F(KinematicsTest, randomWalkIK)
403404
auto pub = node_->create_publisher<moveit_msgs::msg::DisplayTrajectory>("display_random_walk", 1);
404405
traj.getRobotTrajectoryMsg(msg.trajectory[0]);
405406
pub->publish(msg);
406-
rclcpp::spin_some(node_);
407+
rclcpp::executors::SingleThreadedExecutor executor;
408+
executor.add_node(node_);
409+
executor.spin_some();
407410
}
408411
}
409412

moveit_planners/ompl/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ if(CMAKE_CXX_COMPILER_ID MATCHES "(GNU|Clang)")
2727
endif()
2828

2929
include_directories(ompl_interface/include)
30-
include_directories(SYSTEM ${Boost_INCLUDE_DIRS} ${OMPL_INCLUDE_DIRS})
30+
include_directories(SYSTEM ${Boost_INCLUDE_DIRS})
3131

3232
add_subdirectory(ompl_interface)
3333

moveit_planners/ompl/ompl_interface/CMakeLists.txt

Lines changed: 16 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -24,28 +24,23 @@ set_target_properties(moveit_ompl_interface
2424

2525
find_package(OpenMP REQUIRED)
2626

27-
# Used to link in ODE, an OMPL dependency, on macOS
28-
if(APPLE)
29-
target_link_directories(moveit_ompl_interface PUBLIC ${OMPL_LIBRARY_DIRS})
30-
endif()
31-
3227
ament_target_dependencies(
3328
moveit_ompl_interface
29+
PUBLIC
3430
moveit_core
3531
moveit_msgs
3632
moveit_ros_planning
3733
rclcpp
3834
pluginlib
3935
tf2_eigen
4036
tf2_ros
41-
OMPL
4237
Boost)
4338
set_target_properties(
4439
moveit_ompl_interface PROPERTIES COMPILE_FLAGS
4540
"${CMAKE_CXX_FLAGS} ${OpenMP_CXX_FLAGS}")
4641
set_target_properties(moveit_ompl_interface PROPERTIES LINK_FLAGS
4742
"${OpenMP_CXX_FLAGS}")
48-
43+
target_link_libraries(moveit_ompl_interface PUBLIC ompl::ompl)
4944
add_executable(moveit_generate_state_database
5045
scripts/generate_state_database.cpp)
5146
target_link_libraries(moveit_generate_state_database moveit_ompl_interface)
@@ -64,9 +59,9 @@ ament_target_dependencies(
6459
rclcpp
6560
pluginlib
6661
tf2_ros
67-
OMPL
6862
Boost)
69-
target_link_libraries(moveit_ompl_planner_plugin moveit_ompl_interface)
63+
target_link_libraries(moveit_ompl_planner_plugin moveit_ompl_interface
64+
ompl::ompl)
7065

7166
install(TARGETS moveit_generate_state_database
7267
RUNTIME DESTINATION lib/${PROJECT_NAME})
@@ -77,23 +72,24 @@ if(BUILD_TESTING)
7772
find_package(Eigen3 REQUIRED)
7873

7974
ament_add_gtest(test_state_space test/test_state_space.cpp)
80-
ament_target_dependencies(test_state_space moveit_core OMPL Boost Eigen3)
81-
target_link_libraries(test_state_space moveit_ompl_interface)
75+
ament_target_dependencies(test_state_space moveit_core Boost Eigen3)
76+
target_link_libraries(test_state_space moveit_ompl_interface ompl::ompl)
8277
set_target_properties(test_state_space PROPERTIES LINK_FLAGS
8378
"${OpenMP_CXX_FLAGS}")
8479

8580
ament_add_gtest(test_state_validity_checker
8681
test/test_state_validity_checker.cpp)
87-
ament_target_dependencies(test_state_validity_checker moveit_core OMPL Boost
82+
ament_target_dependencies(test_state_validity_checker moveit_core Boost
8883
Eigen3)
89-
target_link_libraries(test_state_validity_checker moveit_ompl_interface)
84+
target_link_libraries(test_state_validity_checker moveit_ompl_interface
85+
ompl::ompl)
9086
set_target_properties(test_state_validity_checker
9187
PROPERTIES LINK_FLAGS "${OpenMP_CXX_FLAGS}")
9288

9389
ament_add_gtest(test_planning_context_manager
9490
test/test_planning_context_manager.cpp)
9591
ament_target_dependencies(test_planning_context_manager moveit_core tf2_eigen
96-
OMPL Boost Eigen3)
92+
Boost Eigen3)
9793
target_link_libraries(test_planning_context_manager moveit_ompl_interface)
9894

9995
# Disabling flaky test TODO (vatanaksoytezer): Uncomment once this is fixed
@@ -104,25 +100,25 @@ if(BUILD_TESTING)
104100
ament_add_gtest(test_constrained_planning_state_space
105101
test/test_constrained_planning_state_space.cpp)
106102
ament_target_dependencies(test_constrained_planning_state_space moveit_core
107-
OMPL Boost Eigen3)
103+
Boost Eigen3)
108104
target_link_libraries(test_constrained_planning_state_space
109-
moveit_ompl_interface)
105+
moveit_ompl_interface ompl::ompl)
110106
set_target_properties(test_constrained_planning_state_space
111107
PROPERTIES LINK_FLAGS "${OpenMP_CXX_FLAGS}")
112108

113109
ament_add_gtest(test_constrained_state_validity_checker
114110
test/test_constrained_state_validity_checker.cpp)
115111
ament_target_dependencies(test_constrained_state_validity_checker moveit_core
116-
OMPL Boost Eigen3)
112+
Boost Eigen3)
117113
target_link_libraries(test_constrained_state_validity_checker
118-
moveit_ompl_interface)
114+
moveit_ompl_interface ompl::ompl)
119115
set_target_properties(test_constrained_state_validity_checker
120116
PROPERTIES LINK_FLAGS "${OpenMP_CXX_FLAGS}")
121117

122118
ament_add_gtest(test_threadsafe_state_storage
123119
test/test_threadsafe_state_storage.cpp)
124-
ament_target_dependencies(test_threadsafe_state_storage moveit_core OMPL
125-
Boost Eigen3)
120+
ament_target_dependencies(test_threadsafe_state_storage moveit_core Boost
121+
Eigen3)
126122
target_link_libraries(test_threadsafe_state_storage moveit_ompl_interface)
127123
set_target_properties(test_threadsafe_state_storage
128124
PROPERTIES LINK_FLAGS "${OpenMP_CXX_FLAGS}")

moveit_ros/benchmarks/src/BenchmarkExecutor.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@
4343
#include <tf2_eigen/tf2_eigen.hpp>
4444
#include <moveit/utils/logger.hpp>
4545

46+
#include <regex>
4647
#include <boost/regex.hpp>
4748

4849
#if __has_include(<boost/timer/progress_display.hpp>)

moveit_ros/hybrid_planning/local_planner/local_planner_component/include/moveit/local_planner/local_planner_component.hpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@
4040
#pragma once
4141

4242
#include <rclcpp/rclcpp.hpp>
43+
#include <rclcpp/version.h>
4344
#include <rclcpp_action/rclcpp_action.hpp>
4445

4546
#include <pluginlib/class_loader.hpp>
@@ -58,8 +59,15 @@
5859
#include <moveit/local_planner/local_constraint_solver_interface.hpp>
5960
#include <moveit/local_planner/trajectory_operator_interface.hpp>
6061

62+
// For Rolling, Kilted, and newer
63+
#if RCLCPP_VERSION_GTE(29, 6, 0)
64+
#include <tf2_ros/buffer.hpp>
65+
#include <tf2_ros/transform_listener.hpp>
66+
// For Jazzy and older
67+
#else
6168
#include <tf2_ros/buffer.h>
6269
#include <tf2_ros/transform_listener.h>
70+
#endif
6371

6472
// Forward declaration of parameter class allows users to implement custom parameters
6573
namespace local_planner_parameters

moveit_ros/hybrid_planning/test/test_basic_integration.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,16 @@
4141
#include <moveit/planning_scene_monitor/planning_scene_monitor.hpp>
4242
#include <moveit/robot_state/conversions.hpp>
4343
#include <rclcpp/rclcpp.hpp>
44+
#include <rclcpp/version.h>
4445
#include <rclcpp_action/rclcpp_action.hpp>
46+
47+
// For Rolling, Kilted, and newer
48+
#if RCLCPP_VERSION_GTE(29, 6, 0)
4549
#include <tf2_ros/buffer.hpp>
50+
// For Jazzy and older
51+
#else
52+
#include <tf2_ros/buffer.h>
53+
#endif
4654

4755
#include <moveit_msgs/action/hybrid_planner.hpp>
4856
#include <moveit_msgs/msg/display_robot_state.hpp>

moveit_ros/move_group/src/default_capabilities/tf_publisher_capability.cpp

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,19 @@
3535
/* Author: Jonas Tietz */
3636

3737
#include "tf_publisher_capability.hpp"
38+
39+
#include <rclcpp/version.h>
40+
3841
#include <moveit/moveit_cpp/moveit_cpp.hpp>
3942
#include <moveit/utils/message_checks.hpp>
4043
#include <moveit/move_group/capability_names.hpp>
44+
// For Rolling, Kilted, and newer
45+
#if RCLCPP_VERSION_GTE(29, 6, 0)
46+
#include <tf2_ros/transform_broadcaster.hpp>
47+
// For Jazzy and older
48+
#else
4149
#include <tf2_ros/transform_broadcaster.h>
50+
#endif
4251
#include <tf2_eigen/tf2_eigen.hpp>
4352
#include <moveit/robot_state/robot_state.hpp>
4453
#include <moveit/robot_state/attached_body.hpp>
@@ -76,7 +85,14 @@ void publishSubframes(tf2_ros::TransformBroadcaster& broadcaster, const moveit::
7685

7786
void TfPublisher::publishPlanningSceneFrames()
7887
{
88+
// For Rolling, L-turtle, and newer
89+
#if RCLCPP_VERSION_GTE(30, 0, 0)
90+
tf2_ros::TransformBroadcaster broadcaster(tf2_ros::TransformBroadcaster::RequiredInterfaces{
91+
context_->moveit_cpp_->getNode()->get_node_parameters_interface(),
92+
context_->moveit_cpp_->getNode()->get_node_topics_interface() });
93+
#else
7994
tf2_ros::TransformBroadcaster broadcaster(context_->moveit_cpp_->getNode());
95+
#endif
8096
geometry_msgs::msg::TransformStamped transform;
8197
rclcpp::Rate rate(rate_);
8298

moveit_ros/move_group/src/move_group.cpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,19 @@
3434

3535
/* Author: Ioan Sucan */
3636

37+
#include <rclcpp/version.h>
38+
3739
#include <moveit/moveit_cpp/moveit_cpp.hpp>
3840
#include <moveit/planning_scene_monitor/planning_scene_monitor.hpp>
41+
// For Rolling, L-turtle, and newer
42+
43+
// For Rolling, Kilted, and newer
44+
#if RCLCPP_VERSION_GTE(29, 6, 0)
45+
#include <tf2_ros/transform_listener.hpp>
46+
// For Jazzy and older
47+
#else
3948
#include <tf2_ros/transform_listener.h>
49+
#endif
4050
#include <moveit/move_group/move_group_capability.hpp>
4151
#include <moveit/trajectory_execution_manager/trajectory_execution_manager.hpp>
4252
#include <boost/tokenizer.hpp>

moveit_ros/moveit_servo/demos/cpp_interface/demo_pose.cpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,15 @@
4444
#include <moveit_servo/utils/common.hpp>
4545
#include <mutex>
4646
#include <rclcpp/rclcpp.hpp>
47+
#include <rclcpp/version.h>
4748
#include <tf2_geometry_msgs/tf2_geometry_msgs.hpp>
49+
// For Rolling, Kilted, and newer
50+
#if RCLCPP_VERSION_GTE(29, 6, 0)
51+
#include <tf2_ros/transform_listener.hpp>
52+
// For Jazzy and older
53+
#else
4854
#include <tf2_ros/transform_listener.h>
55+
#endif
4956
#include <moveit/utils/logger.hpp>
5057

5158
using namespace moveit_servo;

moveit_ros/moveit_servo/demos/cpp_interface/demo_twist.cpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,15 @@
4343
#include <moveit_servo/servo.hpp>
4444
#include <moveit_servo/utils/common.hpp>
4545
#include <rclcpp/rclcpp.hpp>
46+
#include <rclcpp/version.h>
4647
#include <tf2_geometry_msgs/tf2_geometry_msgs.hpp>
48+
// For Rolling, Kilted, and newer
49+
#if RCLCPP_VERSION_GTE(29, 6, 0)
50+
#include <tf2_ros/transform_listener.hpp>
51+
// For Jazzy and older
52+
#else
4753
#include <tf2_ros/transform_listener.h>
54+
#endif
4855
#include <moveit/utils/logger.hpp>
4956

5057
using namespace moveit_servo;

0 commit comments

Comments
 (0)