Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: MTK3339 TextLCD mbed tsi_sensor
Fork of app_gps by
Diff: main.cpp
- Revision:
- 6:c8efb299b0f0
- Parent:
- 5:244867f8fc75
- Child:
- 7:ef6489900709
- Child:
- 8:ffc4ef2442fa
diff -r 244867f8fc75 -r c8efb299b0f0 main.cpp
--- a/main.cpp Mon Jul 13 14:35:32 2015 +0000
+++ b/main.cpp Mon Jul 13 14:53:57 2015 +0000
@@ -109,6 +109,16 @@
stdevLat = stdev(coords[LAT], N);
stdevLon = stdev(coords[LON], N);
+ if (3*stdevLat <= 0.00001 && 3*stdevLon <= 0.00001) {
+ initPos[LAT] = meanLat;
+ initPos[LON] = meanLon;
+ set = true;
+ }
+
+ lcd.cls();
+ lcd.printf("%f\n%f %d", stdevLat, stdevLon, i);
+
+ /*
for (int j=0; j<N; j++) {
if (coords[LAT][j] > meanLat-stdevLat && coords[LAT][j] < meanLat+stdevLat &&
coords[LON][j] > meanLon-stdevLon && coords[LON][j] < meanLon+stdevLon)
@@ -120,6 +130,7 @@
initPos[LON] = coords[LON][i%N];
set = true;
}
+ */
}
i++;
