aboutsummaryrefslogtreecommitdiff
path: root/src/modules/ekf_att_pos_estimator
diff options
context:
space:
mode:
authorLorenz Meier <lm@inf.ethz.ch>2014-06-30 00:35:47 +0200
committerLorenz Meier <lm@inf.ethz.ch>2014-06-30 00:35:47 +0200
commit6f75d1a20f6c66a8bfb87032048d1369d01fbb5e (patch)
tree6bedca6af46742c7cc5742693e77a1bea53eddfc /src/modules/ekf_att_pos_estimator
parent4796c0350e817d7316e8bb135df04796bc0f3330 (diff)
parent2448e2adbc22af348aa799473c30ac5f1cba9cd0 (diff)
downloadpx4-firmware-6f75d1a20f6c66a8bfb87032048d1369d01fbb5e.tar.gz
px4-firmware-6f75d1a20f6c66a8bfb87032048d1369d01fbb5e.tar.bz2
px4-firmware-6f75d1a20f6c66a8bfb87032048d1369d01fbb5e.zip
Merge pull request #1093 from DonLakeFlyer/WarningsBugs
Fix bugs found through compiler warnings
Diffstat (limited to 'src/modules/ekf_att_pos_estimator')
-rw-r--r--src/modules/ekf_att_pos_estimator/estimator.cpp2
-rw-r--r--src/modules/ekf_att_pos_estimator/estimator.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/modules/ekf_att_pos_estimator/estimator.cpp b/src/modules/ekf_att_pos_estimator/estimator.cpp
index 1320b4668..f8b9e9fbd 100644
--- a/src/modules/ekf_att_pos_estimator/estimator.cpp
+++ b/src/modules/ekf_att_pos_estimator/estimator.cpp
@@ -1986,7 +1986,7 @@ void AttPosEKF::calcposNED(float (&posNED)[3], double lat, double lon, float hgt
posNED[2] = -(hgt - hgtRef);
}
-void AttPosEKF::calcLLH(float (&posNED)[3], float lat, float lon, float hgt, float latRef, float lonRef, float hgtRef)
+void AttPosEKF::calcLLH(float posNED[3], float &lat, float &lon, float &hgt, float latRef, float lonRef, float hgtRef)
{
lat = latRef + posNED[0] * earthRadiusInv;
lon = lonRef + posNED[1] * earthRadiusInv / cos(latRef);
diff --git a/src/modules/ekf_att_pos_estimator/estimator.h b/src/modules/ekf_att_pos_estimator/estimator.h
index e821089f2..69d8cfce8 100644
--- a/src/modules/ekf_att_pos_estimator/estimator.h
+++ b/src/modules/ekf_att_pos_estimator/estimator.h
@@ -301,7 +301,7 @@ static void calcvelNED(float (&velNED)[3], float gpsCourse, float gpsGndSpd, flo
static void calcposNED(float (&posNED)[3], double lat, double lon, float hgt, double latRef, double lonRef, float hgtRef);
-static void calcLLH(float (&posNED)[3], float lat, float lon, float hgt, float latRef, float lonRef, float hgtRef);
+static void calcLLH(float posNED[3], float &lat, float &lon, float &hgt, float latRef, float lonRef, float hgtRef);
static void quat2Tnb(Mat3f &Tnb, const float (&quat)[4]);