rclcpp
rclcpp copied to clipboard
Add create_timer interface to Node
Feature request
Feature description
Add an rclcpp::Node interface for the creation of ROS time timers.
This would allow easier creation of timers that can use sim time when possible, and not be strictly held to wall time.
This is already possible with rclcpp::create_timer
and passing in the right arguments, but having it as a function of rclcpp::Node
will make it more convenient to use.
Implementation considerations
Add a Node::create_timer
declaration into the node.hpp
file, but since it will take a callback the definition will most likely need to be added to the node_impl.hpp
template file.
The implementation will most likely just be a wrapper around one of the rclcpp::create_timer
calls and passing the correct arguments as needed. I don't know which of the create_timer
functions will be better to use.