diff --git a/controller_manager/src/controller_manager.cpp b/controller_manager/src/controller_manager.cpp index 69d920f352..bd89445aa5 100644 --- a/controller_manager/src/controller_manager.cpp +++ b/controller_manager/src/controller_manager.cpp @@ -518,6 +518,7 @@ void ControllerManager::init_distributed_sub_controller_manager() { // create node for publishing/subscribing rclcpp::NodeOptions node_options; + node_options.clock_type(rcl_clock_type_t::RCL_STEADY_TIME); distributed_pub_sub_node_ = std::make_shared( std::string(get_name()) + "_pub_sub_node", get_namespace(), node_options, false); //try to add to executor @@ -567,6 +568,7 @@ void ControllerManager::init_distributed_central_controller_manager() if (!use_multiple_nodes()) { rclcpp::NodeOptions node_options; + node_options.clock_type(rcl_clock_type_t::RCL_STEADY_TIME); distributed_pub_sub_node_ = std::make_shared( std::string(get_name()) + "_pub_sub_node", get_namespace(), node_options, false); //try to add to executor diff --git a/hardware_interface/include/hardware_interface/handle.hpp b/hardware_interface/include/hardware_interface/handle.hpp index 55678b1bb5..0b4aaba12d 100644 --- a/hardware_interface/include/hardware_interface/handle.hpp +++ b/hardware_interface/include/hardware_interface/handle.hpp @@ -203,6 +203,7 @@ class DistributedReadOnlyHandle : public ReadOnlyHandle if (!node_.get()) { rclcpp::NodeOptions node_options; + node_options.clock_type(rcl_clock_type_t::RCL_STEADY_TIME); node_ = std::make_shared( get_underscore_separated_name() + "_state_interface_subscriber", namespace_, node_options, false); @@ -354,6 +355,7 @@ class DistributedReadWriteHandle : public ReadWriteHandle if (!node_.get()) { rclcpp::NodeOptions node_options; + node_options.clock_type(rcl_clock_type_t::RCL_STEADY_TIME); node_ = std::make_shared( get_underscore_separated_name() + "_distributed_command_interface", namespace_, node_options, false); diff --git a/hardware_interface/src/hardware_interface/distributed_control_interface/command_forwarder.cpp b/hardware_interface/src/hardware_interface/distributed_control_interface/command_forwarder.cpp index 0ee7be9ad8..203be40c00 100644 --- a/hardware_interface/src/hardware_interface/distributed_control_interface/command_forwarder.cpp +++ b/hardware_interface/src/hardware_interface/distributed_control_interface/command_forwarder.cpp @@ -27,6 +27,7 @@ CommandForwarder::CommandForwarder( if (!node_.get()) { rclcpp::NodeOptions node_options; + node_options.clock_type(rcl_clock_type_t::RCL_STEADY_TIME); node_ = std::make_shared( loaned_command_interface_ptr_->get_underscore_separated_name() + "_command_forwarder", namespace_, node_options, false); diff --git a/hardware_interface/src/hardware_interface/distributed_control_interface/state_publisher.cpp b/hardware_interface/src/hardware_interface/distributed_control_interface/state_publisher.cpp index 0ceaee8b6c..bec3564d89 100644 --- a/hardware_interface/src/hardware_interface/distributed_control_interface/state_publisher.cpp +++ b/hardware_interface/src/hardware_interface/distributed_control_interface/state_publisher.cpp @@ -27,6 +27,7 @@ StatePublisher::StatePublisher( if (!node_.get()) { rclcpp::NodeOptions node_options; + node_options.clock_type(rcl_clock_type_t::RCL_STEADY_TIME); node_ = std::make_shared( loaned_state_interface_ptr_->get_underscore_separated_name() + "_state_publisher", namespace_, node_options, false);