ros / geometry2

A set of ROS packages for keeping track of coordinate transforms.
189 stars 273 forks source link

Error in tf2 tutorial #552

Open xaxam2001 opened 1 year ago

xaxam2001 commented 1 year ago

In the section "using time (Python)" we can read "Edit turtle_tf2_listener.py and remove the timeout=Duration(seconds=1.0) parameter that is passed to the lookup_transform() call on line 76." but if we read the turtle_tf2_listener.py given in the Writing a listener (Python) section we can read the following code:

t = self.tf_buffer.lookup_transform(
      to_frame_rel,
      from_frame_rel,
      rclpy.time.Time())

So it is a bit confusing.

Using time (Python) section: https://docs.ros.org/en/humble/Tutorials/Intermediate/Tf2/Learning-About-Tf2-And-Time-Py.html Writing a listener (Python) section: https://docs.ros.org/en/humble/Tutorials/Intermediate/Tf2/Writing-A-Tf2-Listener-Py.html