Ask Your Question
1

Set the initial pose with rviz

asked 2011-04-14 20:05:03 -0500

Charles gravatar image

updated 2011-04-15 06:44:14 -0500

Eric Perko gravatar image

Hi everyone! I got a problem when I run the navigation stack with rviz. When setting the initial pose with rivz I got a warning :

[ WARN] [1302846487.971832409]: Failed to transform initial pose in time (You requested a transform that is 0.054 miliseconds in the past, 
but the most recent transform in the tf buffer is 21.216 miliseconds old.
 When trying to transform between /map and /base_link.)

[ INFO] [1302846487.971997932]: Setting pose (1302846487.971978): 1.194 6.348 -1.571

Here is the results of the run tf tf_monitor command:


RESULTS: for all Frames

Frames: Frame: /base_link published by /we_base_odom Average Delay: 0.00026288 Max Delay: 0.000908351 Frame: /laser_link published by /base_laser_tf Average Delay: -0.024749 Max Delay: 0 Frame: /odom published by /amcl Average Delay: -0.175799 Max Delay: 0

All Broadcasters: Node: /amcl 13.3557 Hz, Average Delay: -0.175799 Max Delay: 0 Node: /base_laser_tf 39.866 Hz, Average Delay: -0.024749 Max Delay: 0 Node: /we_base_odom 49.9598 Hz, Average Delay: 0.00026288 Max Delay: 0.000908351

I run the rostopic echo /initialpose command, and I got the following outputs when I set the initial pose:

header: 
  seq: 2
  stamp: 
    secs: 0
    nsecs: 0
  frame_id: /map
pose: 
  pose: 
    position: 
      x: 1.19398033619
      y: 6.34785318375
      z: 0.0
    orientation: 
      x: 0.0
      y: 0.0
      z: -0.707106781187
      w: 0.707106781187
  covariance: [0.25, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.25, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.06853891945200942, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0]
  
my tf tree is like: this /map->/odom->/base_link->/laser_link.

Here is the frame.pdf:

image description

How can I fix this problem? Thank you !

edit retag flag offensive close merge delete

Comments

I'm guessing you're running rviz on a separate machine from your robot and their clocks are out of sync with each other. To solve this you need to run ntpdate on your robot and desktop machine so that they are synced
mmwise gravatar imagemmwise ( 2011-06-09 10:44:18 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
1

answered 2011-06-09 10:45:47 -0500

mmwise gravatar image

Below are some quick instructions fro clock synchronization. chrony has been found to be the best ntp client over lossy wireless.

  1. manually sync NTP

    sudo ntpdate ntp.ubuntu.com

  2. Install Chrony

    sudo apt-get install chrony

edit flag offensive delete link more

Comments

did syncing work for you?
mmwise gravatar imagemmwise ( 2011-06-16 10:16:08 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2011-04-14 20:05:03 -0500

Seen: 2,857 times

Last updated: Jun 09 '11