Gazebo | Ignition | Community
Ask Your Question

Error: lidar is not defined in SDF, ignoring lidar

asked 2020-09-14 03:09:36 -0500

this post is marked as community wiki

This post is a wiki. Anyone with karma >75 is welcome to improve it.

Hello. I'm new to Gazebo and I'm trying to create a 2D-lidar sensor and connect in later on with ROS. Following the tutorial [] I created the following world file, but instead of ray element I use lidar. image description

When I run the world file I get the error:

Warning [] XML Element[lidar], child of element[sensor] not defined in SDF. Ignoring[lidar]. You may have an incorrect SDF file, or an sdformat version that doesn't support this element.

When I change the above file to use ray element it runs smoothly. I follow the SDF format from here: link text so I don't know where the problem might be. Can anyone tell me what I'm missing here?

I use Ubuntu 16.04 and the pre-installed Gazebo 7 and i would prefer to stay with this version. Thanks in advance.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2020-09-16 12:12:16 -0500

ahcorde gravatar image


This error means that your SDF is not well formed.

You can find some test worlds in the gazebo_ros_pkgs repository that can help to build your own model/world. For example to include a lidar you can review this file.


edit flag offensive delete link more


Thanks! That helps

Meanmachine gravatar imageMeanmachine ( 2020-09-19 03:29:36 -0500 )edit

Question Tools

1 follower


Asked: 2020-09-14 03:09:36 -0500

Seen: 458 times

Last updated: Sep 16 '20