ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
1

Ros 2 import tf2 Python

asked 2019-03-25 10:32:56 -0500

.zero gravatar image

Hello,

I started having a look at Ros 2 (crystal) two weeks ago and really had a hard time creating a package that produces some executables. As I managed to do that I tried to migrate some old code to Ros 2 code. It was just a tiny project which moved a frame in a circel around the world-frame's center in rviz. To do that I used the TransformBroadcaster imported from tf. I saw that there is now tf2 in my rosdistro/share, so I tried to import that with import tf2, but this threw a

ModuleNotFoundError: No module named 'tf2'

The weird thing is, I can import TFMessage from tf2_msgs and publish TFMessages to tf 'by hand'. This really feels like I overlooked something trivial but as I didn't find anything so far I wanted to ask here.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2019-03-27 12:39:37 -0500

marguedas gravatar image

It appears that the package tf2_py is not ported to ROS 2 yet (it doesn't appear here).

There seem to be ongoing work for porting it https://github.com/ros2/geometry2/pul...

HTH,

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2019-03-25 10:32:56 -0500

Seen: 1,770 times

Last updated: Mar 27 '19