Skip to content

Commit 2ea7fe2

Browse files
committed
webots_ros2_control: remove usage of deprecated activate_all_components for humble
ros-controls/ros2_control#1064
1 parent 929c45c commit 2ea7fe2

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

webots_ros2_control/src/Ros2Control.cpp

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -90,16 +90,10 @@ namespace webots_ros2_control {
9090
webotsSystem->init(mNode, controlHardware[i]);
9191
resourceManager->import_component(std::move(webotsSystem), controlHardware[i]);
9292

93-
// Configure and activate all components
94-
// Necessary hotfix for deprecation of component activation present in "hardware_interface" package for versions above 3.15
95-
// (#793)
96-
#if HARDWARE_INTERFACE_VERSION_MAJOR >= 4 || HARDWARE_INTERFACE_VERSION_MAJOR >= 3 && HARDWARE_INTERFACE_VERSION_MINOR >= 15
93+
// Configure and activate all components
9794
using lifecycle_msgs::msg::State;
9895
rclcpp_lifecycle::State active_state(State::PRIMARY_STATE_ACTIVE, hardware_interface::lifecycle_state_names::ACTIVE);
9996
resourceManager->set_component_state(controlHardware[i].name, active_state);
100-
#else
101-
resourceManager->activate_all_components();
102-
#endif
10397
resourceManager->load_urdf(urdfString, false, false);
10498
}
10599

0 commit comments

Comments
 (0)