Skip to content

Commit 6944b89

Browse files
committed
fixes, thanks to @haslinghuis
1 parent 91925f4 commit 6944b89

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

js/flightlog_fields_presenter.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1041,7 +1041,7 @@ function FlightLogFieldPresenter() {
10411041
case 'ALTITUDE':
10421042
switch (fieldName) {
10431043
case 'debug[0]': // GPS Trust * 100
1044-
value.toFixed(0);
1044+
return value.toFixed(0);
10451045
case 'debug[1]': // GPS Altitude cm
10461046
case 'debug[2]': // OSD Altitude cm
10471047
case 'debug[3]': // Control Altitude

js/imu.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,8 +125,9 @@ function IMU(copyFrom) {
125125
heading = Math.atan2(headingY, headingX) + magneticDeclination / 10.0 * RAD; // RAD = pi/180
126126

127127
heading += 2 * Math.PI; // positive all the time, we want zero to return pi
128-
if (heading > 2* Math.PI)
128+
if (heading > 2* Math.PI) {
129129
heading -= 2* Math.PI;
130+
}
130131

131132
return heading;
132133
}

0 commit comments

Comments
 (0)