Browse Source

Plane: To add a judgment of 0 degrees longitude.

master
murata 8 years ago committed by Tom Pittenger
parent
commit
2f18d1de73
  1. 2
      ArduPlane/ArduPlane.cpp
  2. 2
      ArduPlane/navigation.cpp

2
ArduPlane/ArduPlane.cpp

@ -449,7 +449,7 @@ void Plane::update_GPS_10Hz(void) @@ -449,7 +449,7 @@ void Plane::update_GPS_10Hz(void)
// We countdown N number of good GPS fixes
// so that the altitude is more accurate
// -------------------------------------
if (current_loc.lat == 0) {
if (current_loc.lat == 0 && current_loc.lng == 0) {
ground_start_count = 5;
} else {

2
ArduPlane/navigation.cpp

@ -63,7 +63,7 @@ void Plane::navigate() @@ -63,7 +63,7 @@ void Plane::navigate()
return;
}
if (next_WP_loc.lat == 0) {
if (next_WP_loc.lat == 0 && next_WP_loc.lng == 0) {
return;
}

Loading…
Cancel
Save