Adding custom model to .world 2023

asked 2023-07-26 19:16:50 -0500

mjohannessen gravatar image

updated 2023-07-26 19:18:24 -0500

What is the procedure to add a custom model to a .world file (using Gazebo Fortress)? I installed Gazebo Fortress on Ubuntu 22.04 using the Fortress binary at https://gazebosim.org/docs. I also have ROS2 Humble installed. I've tried this for example:

 <include>
 <uri>model://fire_truck</uri>
 </include>

..using a model downloaded from https://github.com/osrf/gazebo_models.... But, I get an error that the file cannot be found.

After installation, neither GZ_SIM_RESOURCE_PATH or IGN_GAZEBO_RESOURCE_PATH are set. I tried setting those to [my package path]/models, but that's a no go. The docs seem to be all over the place on this issue and none of the demos have a local file for a uri as an example. I also tried using the same format to include a vehicle model in /opt/ros/humble/share/ros_gz_sim_demos/models/ which contains the vehicle model.sdf and model.config files. Also, if it matters, I not only had to install Fortress (binary) but the Garden binary because without Garden, the gz command could not be found.

edit retag flag offensive close merge delete