0
$\begingroup$

Rosanswers logo

I'm following this tutorial[1] and having trouble with importing.

[1] http://wiki.ros.org/tf2/Tutorials/Writing%20a%20tf2%20static%20broadcaster%20(Python)

>>> import tf2_ros
>>> tf2_ros.StaticTransformPublisher()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'module' object has no attribute 'StaticTransformPublisher'

Using up-to-date Indigo with Trusty.

$ dpkg -s ros-indigo-tf2-ros | grep Version
Version: 0.5.13-0trusty-20161025-211630-0700

Originally posted by David Lu on ROS Answers with karma: 10932 on 2017-01-09

Post score: 0


Original comments

Comment by Michael Johnson on 2017-01-09:
What is it you are trying to do? static_transform_publisher is a command line tool which can be used like this:

static_transform_publisher x y z yaw pitch roll frame_id child_frame_id period_in_ms

http://wiki.ros.org/tf#static_transform_publisher

Comment by David Lu on 2017-01-09:
I appreciate the link, but I hate that command line interface and am trying to rewrite it.

$\endgroup$

2 Answers 2

0
$\begingroup$

Rosanswers logo

It looks like StaticTransformPublisher was renamed to StaticTransformBroadcaster. The API looks the same though so you should just be able to directly replace it.

github link


Originally posted by Michael Johnson with karma: 154 on 2017-01-09

This answer was NOT ACCEPTED on the original site

Post score: 2

$\endgroup$
0
$\begingroup$

Rosanswers logo

The real problem is that the debian has not been updated. https://github.com/ros/geometry2/issues/199


Originally posted by David Lu with karma: 10932 on 2017-01-11

This answer was ACCEPTED on the original site

Post score: 0

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.