If Ardupilot on a Pixhawk 2 with lidar is used, can QGroundControl support terrain following? If not, what is restricting the support? If the restriction is related to unsupported maps, what is restricting terrain following by lidar exclusively?
What can we do to make this work? Should QGC software be modified, Ardupilot, or both?
QGroundControl Stable Version 3.4 Release Notes states that Ardupilot is not supported for terrain following: https://docs.qgroundcontrol.com/en/releases/release_notes.html
TL;DR Ardupilot terrain following isn’t properly supported in QGC, but it’s actually for a different reason.
ArduPilot has supported AGL missions for quite some time, with or without lidar.
What that qgc release note refers to is a different implementation, used by qgc with px4, where qgc downloads terrain data from airmap and offsets the waypoints accordingly. This is a different approach to that used by Ardupilot, where SRTM terrain data is uploaded to the autopilot directly. QGC doesn’t support that aspect (uploading the terrain data to the autopilot).
Lidar based terrain following doesn’t rely on that, but iirc correctly you still can’t set the waypoints to the necessary format in QGC.
It’s not really a matter of “properly” with respect to sending terrain height to the vehicle using the mavlink messages it’s pretty much not supported at all.
That is correct. But if you load a mission created with say MP which using TERRAIN_FRAME altitudes the option will magically appear.