GSAltimeter

@objc
public protocol GSAltimeter : Instrument

Instrument that informs about altitude.

This instrument can be retrieved by:

drone.getInstrument(Instruments.altimeter)

Note

This protocol is for Objective-C only. Swift must use the protocol Altimeter.
  • Gets the altitude of the drone relative to take off altitude (in meters).

    Note

    this method is for Objective-C only. Swift must use the property takeoffRelativeAltitude.

    Declaration

    Swift

    func getTakeoffRelativeAltitude() -> NSNumber?

    Return Value

    the altitude relative to take off point. nil if not available. This can happen if the drone does not know or provide this information.

  • Gets the altitude of the drone relative to the ground (in meters).

    This is the fusion of barometer and ultrasounds, may be wrong at high altitude and jump brutally when getting closer to the ground.

    Note

    This method is for Objective-C only. Swift must use the property groundRelativeAltitude.

    Declaration

    Swift

    func getGroundRelativeAltitude() -> NSNumber?

    Return Value

    the altitude of the drone relative to the ground. nil if not available. This can happen if the drone does not know or provide this information.

  • Gets the absolute altitude of the drone, i.e. relative to sea-level (in meters).

    Note

    This method is for Objective-C only. Swift must use the property absoluteAltitude.

    Declaration

    Swift

    func getAbsoluteAltitude() -> NSNumber?

    Return Value

    the altitude relative to sea level nil if not available. This can happen if the drone does not know or provide this information, or if its gps is not fixed.

  • Gets the vertical speed of the drone (in m/s).

    Positive when the drone is going up, negative when the drone is going down.

    Note

    This method is for Objective-C only. Swift must use the property verticalSpeed.

    Declaration

    Swift

    func getVerticalSpeed() -> NSNumber?

    Return Value

    the vertical speed of the drone. nil if not available. This can happen if the drone does not know or provide this information.