Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 252e0908 authored by Wyatt Riley's avatar Wyatt Riley
Browse files

Location & GNSS Measurement Documetation Fixes

Clarifying documenation of SNR, Vertical Accuracy, and
Accumulated Delta Range.

Change-Id: I2684c57e0f4aff2925549e01cbe4f546910f93e0
Fixes: 65369254
Test: Builds (comments only)
parent cc78a9b6
Loading
Loading
Loading
Loading
+11 −1
Original line number Diff line number Diff line
@@ -612,6 +612,16 @@ public final class GnssMeasurement implements Parcelable {
     *
     * <pre>
     *          accumulated delta range = -k * carrier phase    (where k is a constant)</pre>
     *
     * <p>Similar to the concept of an RTCM "Phaserange", when the accumulated delta range is
     * initially chosen, and whenever it is reset, it will retain the integer nature
     * of the relative carrier phase offset between satellites observed by this receiver, such that
     * the double difference of this value between receivers and satellites may be used, together
     * with integer ambiguity resolution, to determine highly precise relative location between
     * receivers.
     *
     * <p>This includes ensuring that all half-cycle ambiguities are resolved before this value is
     * reported as {@link #ADR_STATE_VALID}.
     */
    public double getAccumulatedDeltaRangeMeters() {
        return mAccumulatedDeltaRangeMeters;
@@ -861,7 +871,7 @@ public final class GnssMeasurement implements Parcelable {
    }

    /**
     * Gets the Signal-to-Noise ratio (SNR) in dB.
     * Gets the (post-correlation & integration) Signal-to-Noise ratio (SNR) in dB.
     *
     * <p>The value is only available if {@link #hasSnrInDb()} is {@code true}.
     */
+25 −19
Original line number Diff line number Diff line
@@ -813,15 +813,16 @@ public class Location implements Parcelable {
    /**
     * Get the estimated vertical accuracy of this location, in meters.
     *
     * <p>We define vertical accuracy as the radius of 68% confidence. In other
     * words, if you draw a circle centered at this location's altitude, and with a radius
     * equal to the vertical accuracy, then there is a 68% probability that the true altitude is
     * inside the circle.
     * <p>We define vertical accuracy at 68% confidence.  Specifically, as 1-side of the
     * 2-sided range above and below the estimated altitude reported by {@link #getAltitude()},
     * within which there is a 68% probability of finding the true altitude.
     *
     * <p>In statistical terms, it is assumed that location errors
     * are random with a normal distribution, so the 68% confidence circle
     * represents one standard deviation. Note that in practice, location
     * errors do not always follow such a simple distribution.
     * <p>In the case where the underlying distribution is assumed Gaussian normal, this would be
     * considered 1 standard deviation.
     *
     * <p>For example, if {@link #getAltitude()} returns 150, and
     * {@link #getVerticalAccuracyMeters()} ()} returns 20 then there is a 68% probability
     * of the true altitude being between 130 and 170 meters.
     *
     * <p>If this location does not have a vertical accuracy, then 0.0 is returned.
     */
@@ -866,14 +867,16 @@ public class Location implements Parcelable {
    /**
     * Get the estimated speed accuracy of this location, in meters per second.
     *
     * <p>We define speed accuracy as a 1-standard-deviation value, i.e. as 1-side of the
     * 2-sided range above and below the estimated
     * speed reported by {@link #getSpeed()}, within which there is a 68% probability of
     * finding the true speed.
     * <p>We define speed accuracy at 68% confidence.  Specifically, as 1-side of the
     * 2-sided range above and below the estimated speed reported by {@link #getSpeed()},
     * within which there is a 68% probability of finding the true speed.
     *
     * <p>In the case where the underlying
     * distribution is assumed Gaussian normal, this would be considered 1 standard deviation.
     *
     * <p>For example, if {@link #getSpeed()} returns 5.0, and
     * {@link #getSpeedAccuracyMetersPerSecond()} returns 1.0, then there is a 68% probably of the
     * true speed being between 4.0 and 6.0 meters per second.
     * <p>For example, if {@link #getSpeed()} returns 5, and
     * {@link #getSpeedAccuracyMetersPerSecond()} returns 1, then there is a 68% probability of
     * the true speed being between 4 and 6 meters per second.
     *
     * <p>Note that the speed and speed accuracy is often better than would be obtained simply from
     * differencing sequential positions, such as when the Doppler measurements from GNSS satellites
@@ -922,13 +925,16 @@ public class Location implements Parcelable {
    /**
     * Get the estimated bearing accuracy of this location, in degrees.
     *
     * <p>We define bearing accuracy as a 1-standard-deviation value, i.e. as 1-side of the
     * <p>We define bearing accuracy at 68% confidence.  Specifically, as 1-side of the
     * 2-sided range on each side of the estimated bearing reported by {@link #getBearing()},
     * within which there is a 68% probability of finding the true bearing.
     *
     * <p>For example, if {@link #getBearing()} returns 60., and
     * {@link #getBearingAccuracyDegrees()} ()} returns 10., then there is a 68% probably of the
     * true bearing being between 50. and 70. degrees.
     * <p>In the case where the underlying distribution is assumed Gaussian normal, this would be
     * considered 1 standard deviation.
     *
     * <p>For example, if {@link #getBearing()} returns 60, and
     * {@link #getBearingAccuracyDegrees()} ()} returns 10, then there is a 68% probability of the
     * true bearing being between 50 and 70 degrees.
     *
     * <p>If this location does not have a bearing accuracy, then 0.0 is returned.
     */