Integrating ardupilot with LiDAR sensors in gazebo

asked 2018-01-12 09:27:12 -0600

I am trying to setup a quad with LiDAR. I have successfully integrated gazebo with the SITL and can fly the iris around. I also have modified the iris to have a hokuyo lidar on it. My end goal is to model the Lightware SF40C, but an interim goal is to get any lidar working, sending distances to obsticals via mavlink DISTANCE_SENSOR messages. The Lightware does this in real life.

The default iris sends a DISTANCE_SENSOR message for the distance to the ground, with only an IMU and a odometry sensor. However, when I put a lidar in the model, this doesn't report any distances. My hunch is the code is somewhere in the ardupilot plugin, but I have searched that rather thoroughly and can't find anything. So, on to my questions:

  • Does Gazebo send DISTANCE_SENSOR mavlink messages on its own for lidar?
  • Does gazebo speak mavlink at all or is it just the ardupilot plugin?
  • Any idea on how that down message is making its way across, so I can modify the plugin if necessary?
edit retag flag offensive close merge delete