altoslib: Correctly parse IMU cal data
authorKeith Packard <keithp@keithp.com>
Tue, 12 Sep 2017 20:33:13 +0000 (13:33 -0700)
committerKeith Packard <keithp@keithp.com>
Tue, 12 Sep 2017 20:33:13 +0000 (13:33 -0700)
Was trying to match 'IMU call along' instead of 'IMU cal along',
causing the line to not match and losing the IMU accel cal values.

Signed-off-by: Keith Packard <keithp@keithp.com>
altoslib/AltosConfigData.java

index d85f735b19d71ea2afb0d442d8343773718c707b..dc036867047cf278432aa99b7b35be0ccb244d6f 100644 (file)
@@ -405,7 +405,7 @@ public class AltosConfigData {
 
                /* HAS_GYRO */
                try {
-                       if (line.startsWith("IMU call along")) {
+                       if (line.startsWith("IMU cal along")) {
                                String[] bits = line.split("\\s+");
                                if (bits.length >= 8) {
                                        accel_zero_along = Integer.parseInt(bits[3]);