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

How can I get the current pose of the turtlebot within a rosjava node?

asked 2012-06-07 08:39:50 -0600

updated 2012-06-07 11:01:36 -0600

Hello,

I have a behavior that I am writing as a RosJava node. I am able to send the robot to goals using the navigation stack, but I need to get the current pose. Please advise on how this can be done. I will be running the base C++ navigation stack, and my custom node package is written in rosJava.

Should I subscribe to an /amcl_pose message and cache the most recent one? Or, should I create a TF listener object, similar to this related post? http://answers.ros.org/question/31815/getting-coordinates-of-turtlebot/

I am referring to the global, /map coordinates.

I have not been able to find anything on this in the rosjava tutorials but it does seem like basic functionality.

Thanks in advance.

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
0

answered 2012-06-17 16:55:49 -0600

Here is an update: I subscribed to the amcl_pose topic from within my own behavior, and cache the latest values for use within my behavior logic. These values are of course, updated frequently whenever the robot is moving.

There may be a more elegant way of doing this, but this basic approach seems to work fine.

edit flag offensive delete link more
0

answered 2016-11-16 05:16:08 -0600

hello,I want to know the localization accuracy of the robot,so I want to read out the position estimation of the robot,but you know that /amcl_pose is a fixed number,how should Iget the position estimation?3q

edit flag offensive delete link more

Question Tools

Stats

Asked: 2012-06-07 08:39:50 -0600

Seen: 1,125 times

Last updated: Jun 17 '12