TF_OLD_DATA error when using gmapping with V-REP
Hi,
I'm new to ROS (Kinetic) and dealing with a simulated robot (robotino) and SLAM. The problem is that when i try to launch gmapping by the command:
rosrun gmapping slam_gmapping scan:=/base_scan
I get the following error:
Warning: TF_OLD_DATA ignoring data from the past for frame odom at time 1.53886e+09 according to authority unknown_publisher
Possible reasons are listed at http://wiki.ros.org/tf/Errors%20explained
at line 277 in /tmp/binarydeb/ros-kinetic-tf2-0.5.16/src/buffer_core.cp
I've already tried to send a empty message to the topic /reset_time
but it didn't work.
I'm in a Ubuntu 16.04 and using the SICK_TIM310_fast laser in V-REP and I publish it's data using the following piece of Lua script:
laserInfo = {}
intensities = {}
data=sim.getStringSignal("measuredDataAtThisTime")
if data then
measuredData=sim.unpackFloatTable(data)
laserInfo['header'] = {seq=0,stamp=simROS.getTime(), frame_id="laser_lixo"}
laserInfo['angle_min'] = -1.54
laserInfo['angle_max'] = 1.54
laserInfo['angle_increment'] = 0.017444444444444
laserInfo['time_increment'] = 0.0666666667
laserInfo['scan_time'] = 1.0
laserInfo['range_max'] = 4.0
laserInfo['range_min'] = 0.05
laserInfo['ranges'] = measuredData
for k=0,table.getn(measuredData) do table.insert(intensities, 0) end
laserInfo['intensities'] = intensities
simROS.publish(laserPub, laserInfo)
end
This is what i current get from the topic /tf: https://drive.google.com/file/d/1HTH1...
After i run gmapping a new /tf_static topic is created but i get nothing from it.
This is my current tf tree: https://drive.google.com/file/d/1vrI6...
Thanks for your help and if i'm missing some information that could be useful please tell me.
Is
use_sim_time
set on the machine? If not,gmapping
will try to use normal wall clock time but V-REP might be publishing simulation time (ie: starts from 0). That is not going to work.You'll have to add more information about your setup to your question for others to be able to help you.
Yes, it's set, if i don't do it i just get a seg fault error. I will try to add some more information but i don't exactly know what is important in this case, could you tell me? Thanks for your help.
This looks possibly related to: #q304824.
Could you make a minimal example of how to reproduce this error? I've seen several related reports recently but cannot reproduce it. Others have reported that the published tf timestamps are always at the same value.
I can't be sure this is related, but I recently (ie: yesterday) ran into a similar persistent
TF_OLD_DATA
situation which turned out to be an ABI break. I had a workspace compiled from before the recent ABI breakage (withrostime
) and tried to use it on an updated system. All my Gazebo .... plugins broke and I was confronted with a wall of
TF_OLD_DATA
errors. Nothing worked until I rebuilt my workspace.To reproduce this i just ran roscore, vrep and then tried to run gmapping, nothing else. I added an image of what i get from the /tf topic and an image of my current tf tree. I also rebuilt my workspace but it keeps getting the same error. Thanks again for the answers.