projects
/
fw
/
altos
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
altosuilib: Add GPS DOP values to info table
[fw/altos]
/
altoslib
/
AltosEepromMetrum2.java
diff --git
a/altoslib/AltosEepromMetrum2.java
b/altoslib/AltosEepromMetrum2.java
index ea38edf2c2cef76b034eaa0a51ed3247b9c60b95..2f43879ec978a902a6adaf82f4ce42210a38c32f 100644
(file)
--- a/
altoslib/AltosEepromMetrum2.java
+++ b/
altoslib/AltosEepromMetrum2.java
@@
-15,7
+15,7
@@
* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
*/
* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
*/
-package org.altusmetrum.altoslib_
1
;
+package org.altusmetrum.altoslib_
5
;
import java.io.*;
import java.util.*;
import java.io.*;
import java.util.*;
@@
-59,7
+59,8
@@
public class AltosEepromMetrum2 extends AltosEeprom {
public int year() { return data8(4); }
public int month() { return data8(5); }
public int day() { return data8(6); }
public int year() { return data8(4); }
public int month() { return data8(5); }
public int day() { return data8(6); }
-
+ public int pdop() { return data8(7); }
+
/* AO_LOG_GPS_SAT elements */
public int nsat() { return data8(0); }
public int more() { return data8(1); }
/* AO_LOG_GPS_SAT elements */
public int nsat() { return data8(0); }
public int more() { return data8(1); }
@@
-136,6
+137,7
@@
public class AltosEepromMetrum2 extends AltosEeprom {
gps.year = 2000 + year();
gps.month = month();
gps.day = day();
gps.year = 2000 + year();
gps.month = month();
gps.day = day();
+ gps.pdop = pdop() / 10.0;
break;
case AltosLib.AO_LOG_GPS_SAT:
gps = state.make_temp_gps(true);
break;
case AltosLib.AO_LOG_GPS_SAT:
gps = state.make_temp_gps(true);
@@
-161,7
+163,7
@@
public class AltosEepromMetrum2 extends AltosEeprom {
break;
try {
AltosEepromMetrum2 metrum = new AltosEepromMetrum2(line);
break;
try {
AltosEepromMetrum2 metrum = new AltosEepromMetrum2(line);
-
+
if (metrum.cmd != AltosLib.AO_LOG_INVALID)
metrums.add(metrum);
} catch (Exception e) {
if (metrum.cmd != AltosLib.AO_LOG_INVALID)
metrums.add(metrum);
} catch (Exception e) {