-
Notifications
You must be signed in to change notification settings - Fork 418
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add rclcpp::Time::seconds() #526
Conversation
@@ -102,6 +102,11 @@ class Time | |||
rcl_time_point_value_t | |||
nanoseconds() const; | |||
|
|||
/// \return the seconds since epoch as a floating point number. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should the docblock contain a note/warning about potential rounding errors? I think that was one reason to omit the function until now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added warning in 7b736c9
* construct TimerBase/GenericTimer with Clock * pass rcl_time_point_value_t to rcl_clock_get_now * update docblocks
Thanks for the reviews. CI in ros2/geometry2#67 (comment) looks green, so I'll merge this. |
…est (ros2#526) Signed-off-by: Christophe Bedard <bedard.christophe@gmail.com>
(edit) #482Edit oops, this doesn't fix 482. That ticket is about duration types.This adds
seconds()
which returns the seconds since epoch as a double.Connects to ros2/geometry2#67