MAVLINKHUD

Overview

The SURFACE parameter group (specifically SURFACE_DEPTH or BARO_SURFACE_DEPTH) calibrates the depth reference for ArduSub.

Key Concepts

1. Water Surface Reference

Submarines use pressure to calculate depth. However, atmospheric pressure changes.

  • SURFACE_DEPTH: The reading the pressure sensor gives when the ROV is at the water's surface.
  • Calibration: Usually set automatically by the GCS during the "Calibrate Pressure" step.

Developer Notes

  • Library: libraries/AP_Baro.

SURFACE_DEPTH

cm
Default -10
Range -100 0

Depth reading at surface (SURFACE_DEPTH)

Description

This parameter calibrates the external pressure sensor for the ROV. It represents the depth reading (in cm) that the sensor outputs when the vehicle is actually at the surface. This accounts for atmospheric pressure variations and sensor offset drift.

The Mathematics

$$ \text{Depth}{\text{displayed}} = \text{Depth}{\text{raw}} - \text{SURFACE\_DEPTH} $$

The Engineer's View

Defined in ArduSub/Parameters.cpp.

  • Calibration: Usually set automatically when you click "Calibrate Pressure" in QGroundControl while the ROV is on the surface.

Tuning & Behavior

  • Default Value: -10 cm (Assumes sensor is slightly submerged or offset)