1
0
mirror of https://codeberg.org/Freeyourgadget/Gadgetbridge synced 2024-12-27 02:55:50 +01:00

Huawei: Fix altitude in the GPS parser

This commit is contained in:
Me7c7 2024-10-04 17:50:10 +03:00 committed by José Rebelo
parent 0f65e42be4
commit 1e732efb04

View File

@ -89,9 +89,8 @@ public class HuaweiGpsParser {
point.longitude = (lon / 6383807.0d / Math.cos(lat_start) + lon_start) / 0.017453292519943d; point.longitude = (lon / 6383807.0d / Math.cos(lat_start) + lon_start) / 0.017453292519943d;
point.altitudeSupported = alt_support; point.altitudeSupported = alt_support;
if (alt_support) { if (alt_support) {
// TODO: not sure about this alt = buffer.getShort();
float alt_delta = buffer.getFloat(); buffer.getShort(); // Unknown values
alt = alt + alt_delta;
point.altitude = alt; point.altitude = alt;
} }
retv.add(point); retv.add(point);