clover_vm
clover_vm copied to clipboard
Flying over a cube breaks PX4 terrain distance estimator
Same for spawning a cube below a flying drone or removing a cube.
Topic /mavros/altitude displays sudden change in terrain distance and then nan:
header:
seq: 616
stamp:
secs: 62
nsecs: 40000000
frame_id: "map"
monotonic: 489.8117980957031
amsl: 489.8117980957031
local: 2.0768721103668213
relative: 2.0768721103668213
terrain: nan
bottom_clearance: nan
I may confirm this bug, but it's unclear so far, why PX4 acts this way, if the rangefinder's value changes sharply.
Addressed adding a terrain_frame_mode parameter. If set to range, then estimator's altitude is ignored, and the simple rangefinder topic's value is used instead.