trouble using extern .world
Hi everyone,
I'm currently working with this great package (rrt_exploration) and i'm trying to use different map to simulate my environment on gazebo. I tested the map including in the package, and also some map from gazebo package (as willow garage).
Currently i'm trying to use these worlds on the package but it doesn't work.
My guess is that there is different type of .world : for instance here is the code of one of the working world :
<?xml version="1.0" ?>
<sdf version="1.4">
<world name="default">
<include>
<uri>model://ground_plane</uri>
</include>
<include>
<uri>model://sun</uri>
</include>
<model name="floor">
<pose>0 0 -0.110060 0 0 0</pose>
<static>false</static>
<link name="floorPlan">
<visual name="visual">
<geometry>
<mesh><uri>file://largeMap.dae</uri></mesh>
</geometry>
</visual>
<collision name="collision">
<geometry>
<mesh><uri>file://largeMap.dae</uri></mesh>
</geometry>
</collision>
</link>
</model>
</world>
</sdf>
and here is (a part of) the .world i'm trying to use :
<sdf version='1.6'>
<world name='default'>
<scene>
<shadows>0</shadows>
<ambient>0.4 0.4 0.4 1</ambient>
<background>0.7 0.7 0.7 1</background>
</scene>
<light name='sun' type='directional'>
<cast_shadows>0</cast_shadows>
<pose frame=''>0 0 5 0 -0 0</pose>
<diffuse>0.8 0.8 0.8 1</diffuse>
<specular>0.1 0.1 0.1 1</specular>
<attenuation>
<range>1000</range>
<constant>0.9</constant>
<linear>0.01</linear>
<quadratic>0.001</quadratic>
</attenuation>
<direction>-0.5 0.5 -1</direction>
</light>
<physics name='default_physics' default='0' type='ode'>
<max_step_size>0.001</max_step_size>
<real_time_factor>1</real_time_factor>
<real_time_update_rate>1000</real_time_update_rate>
</physics>
<scene>
<ambient>0.4 0.4 0.4 1</ambient>
<background>0.7 0.7 0.7 1</background>
<shadows>1</shadows>
</scene>
<spherical_coordinates>
<surface_model>EARTH_WGS84</surface_model>
<latitude_deg>0</latitude_deg>
<longitude_deg>0</longitude_deg>
<elevation>0</elevation>
<heading_deg>0</heading_deg>
</spherical_coordinates>
<model name='ground_plane'>
<static>1</static>
<link name='link'>
<collision name='collision'>
<geometry>
<plane>
<normal>0 0 1</normal>
<size>100 100</size>
</plane>
</geometry>
<surface>
<friction>
<ode>
<mu>1</mu>
<mu2>1</mu2>
</ode>
<torsional>
<ode/>
</torsional>
</friction>
<bounce/>
<contact>
<ode/>
</contact>
</surface>
<max_contacts>10</max_contacts>
</collision>
<visual name='visual'>
<cast_shadows>0</cast_shadows>
<geometry>
<plane>
<normal>0 0 1</normal>
<size>100 100</size>
</plane>
</geometry>
<material>
(not the complete code : it's about 38903 lines...
My question is : what's the difference between these two files .world, and how can i use the second one on my simulation ?
Thanks in advance !
EDIT : it seems to be a compatibility problem :
Warning [parser.cc:340] Converting a deprecated source[/home/lklk/hugo_ws/src/rrt_exploration_tutorials/launch/includes/worlds/office_earthquake.world].
Warning [Converter.cc:59] Version[1.6] to Version[1.4]
Please use the gzsdf tool to update your SDF files.
$ gzsdf convert [sdf_file]
Error [Converter.cc:127] Unable to convert from SDF version 1.6 to 1.4
Warning [parser.cc:478] XML Attribute[frame] in element[pose] not defined in SDF, ignoring.
Warning [parser.cc:478 ...
The most obvious difference is that the first file seems to be SDF
v1.4
and the second onev1.6
. SDF is the format Gazebo uses to describe simulation environments. There is a great deal of bw-compatibility in SDF, but forward compatibility might not be possible. .... you'll have to check whether the Gazebo version you're using is capable of loading
v1.6
worlds.You don't describe what "is not working", so this is the best we can do at the moment.
yes sorry, i edited my previous post. As you said, it's due to compatibilities errors.
Any reason you cannot use Gazebo 7? That is installable on Ubuntu Trusty/ROS Indigo and would get you SDF 1.6 support.
Yes, the package i want to use seems not to be compatible with gazebo 7
Then you seem to be forced to adapt the
world
file to a lower version of the format. That might mean that certain features will not be available / work.hello StanSmooth, gazebo simulation files in the "rrt_exploration_tutorials" package are for Gazebo 7. So it should work. I will try to use on te world files you are trying to launch and see what the problem is..