aboutsummaryrefslogtreecommitdiff
path: root/src/modules/navigator
diff options
context:
space:
mode:
authorThomas Gubler <thomasgubler@gmail.com>2014-09-19 09:51:56 +0200
committerThomas Gubler <thomasgubler@gmail.com>2014-09-19 09:51:56 +0200
commitec39427d79249575b1bd8ca7af0929d08c084060 (patch)
tree37422c80876ce5a902964ea99ad7f8fa07006da6 /src/modules/navigator
parent772c5f745cdb2213e9d89d2ab3f373ac5ea2009a (diff)
downloadpx4-firmware-ec39427d79249575b1bd8ca7af0929d08c084060.tar.gz
px4-firmware-ec39427d79249575b1bd8ca7af0929d08c084060.tar.bz2
px4-firmware-ec39427d79249575b1bd8ca7af0929d08c084060.zip
geofence: lat/lon is double
This is the same change as 5832948371866aec8f0c7f16b13869f270d36aad but against the master branch. Some time ago the type of lat and lon in the global_pos uorb topic was changed but this use here was missed.
Diffstat (limited to 'src/modules/navigator')
-rw-r--r--src/modules/navigator/geofence.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/modules/navigator/geofence.cpp b/src/modules/navigator/geofence.cpp
index 266215308..49aec21e0 100644
--- a/src/modules/navigator/geofence.cpp
+++ b/src/modules/navigator/geofence.cpp
@@ -76,11 +76,7 @@ Geofence::~Geofence()
bool Geofence::inside(const struct vehicle_global_position_s *vehicle)
{
- double lat = vehicle->lat / 1e7d;
- double lon = vehicle->lon / 1e7d;
- //float alt = vehicle->alt;
-
- return inside(lat, lon, vehicle->alt);
+ return inside(vehicle->lat, vehicle->lon, vehicle->alt);
}
bool Geofence::inside(double lat, double lon, float altitude)