Skip to content

Implement Time Features in rclpy #186

Closed

Description

@tfoote

This ticket is to track rclpy specific time impelementation requirements

Activity

  1. added
    enhancement
    on Apr 26, 2018
  2. Nickolaim commented on May 11, 2018

    @Nickolaim
    Contributor

    I can take this item if nobody is looking at it yet.

  3. tfoote commented on May 15, 2018

    @tfoote
    ContributorAuthor

    I don't think anyone is actively working on this. If you'd like to start work on the clock, timer and rate that would be feasible. The time source is blocked on the availability of parameters. If you'd like to pick it up I'd suggest creating a separate ticket for one of the smaller parts to sketch out how you're going to approach it to get feedback before you jump in and implement it.

  4. dhood commented on Jul 16, 2018

    @dhood
    Member

    Here's some additional detail about the steps that would be required.

    • Time class wrapping rcl types (rcl_time_point, rcl_duration) and functions (rcl_difference_times, rcl_get_time_now). Conversions to/from builtin_interfaces msg type.
    • Clock class wrapping rcl's rcl_clock_t, exposing get_now; Node has a clock; demos using node.now() if appropriate.
    • TimeSource wrapping rcl; implementation of ROS time support: A node is used to create a TimeSource of "ROS time" (subscription to /clock, use_sim_time support by some means), node's clock is managed by the TimeSource.
    • Time jump types (TimeJump, JumpThreshold) and logic moved from rclcpp to rcl, wrapped in python. Jump handlers in python.
    • Timer using specific Clock (rclpy Timer currently wraps an rcl timer that rcl_wait uses) in a similar manner to what will be done for rclcpp.
    • Addition of Rate in a similar manner to what will be done for rclcpp.
  5. self-assigned this
    on Jul 18, 2018
  6. added
    in progress
    in review
    and removed
    in progress
    on Jul 18, 2018
  7. added
    in progress
    and removed
    in review
    on Aug 6, 2018
  8. added
    ready
    and removed
    in progress
    on Oct 25, 2018
  9. stonier commented on Oct 30, 2018

    @stonier
    Contributor

    Another one for the list, oneshot timers?

  10. dirk-thomas commented on Oct 30, 2018

    @dirk-thomas
    Member

    A oneshot timer should be straight forward to implement on top of regular timers by cancelling the timer in the first callback.

    Please consider to contribute a pull request for this feature.

  11. removed their assignment
    on Feb 14, 2019
  12. slessans commented on Jun 8, 2019

    @slessans

    @dirk-thomas do you know if anyone took a shot at contributing a simple one shot timer? If not I will give it a try

  13. dirk-thomas commented on Jun 8, 2019

    @dirk-thomas
    Member

    do you know if anyone took a shot at contributing a simple one shot timer?

    Not that I am aware of.

    If not I will give it a try

    That would be great.

  14. mhpanah commented on Jul 31, 2019

    @mhpanah

    I'm in need of Rate method to use sim_time. Has Rate method been implemented on rclpy yet? Thanks.

  15. jacobperron commented on Aug 21, 2019

    @jacobperron
    Member

    I'm in need of Rate method to use sim_time. Has Rate method been implemented on rclpy yet?

    Nope. PRs welcome ;)

  16. ghost removed
    ready
    on Oct 14, 2019
  17. ros-discourse commented on Jun 13, 2025

    @ros-discourse
  18. added a commit that references this issue on Nov 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions