[hamradio-commits] [gnss-sdr] 35/126: Some cleaning

Carles Fernandez carles_fernandez-guest at moszumanska.debian.org
Sat Dec 26 18:37:59 UTC 2015


This is an automated email from the git hooks/post-receive script.

carles_fernandez-guest pushed a commit to branch next
in repository gnss-sdr.

commit 633655616370d06f406beed834f6607da7f41e52
Author: Carles Fernandez <carles.fernandez at gmail.com>
Date:   Sun Nov 15 23:31:27 2015 +0100

    Some cleaning
---
 src/algorithms/PVT/gnuradio_blocks/hybrid_pvt_cc.h | 1 -
 src/algorithms/PVT/libs/galileo_e1_ls_pvt.cc       | 4 ++--
 src/algorithms/PVT/libs/geojson_printer.cc         | 2 +-
 src/algorithms/PVT/libs/gps_l1_ca_ls_pvt.cc        | 4 ++++
 src/algorithms/PVT/libs/hybrid_ls_pvt.cc           | 7 ++++---
 src/algorithms/PVT/libs/ls_pvt.cc                  | 3 ---
 src/algorithms/PVT/libs/pvt_solution.cc            | 6 +++---
 src/algorithms/PVT/libs/pvt_solution.h             | 2 +-
 8 files changed, 15 insertions(+), 14 deletions(-)

diff --git a/src/algorithms/PVT/gnuradio_blocks/hybrid_pvt_cc.h b/src/algorithms/PVT/gnuradio_blocks/hybrid_pvt_cc.h
index 777c388..eb6e8a9 100644
--- a/src/algorithms/PVT/gnuradio_blocks/hybrid_pvt_cc.h
+++ b/src/algorithms/PVT/gnuradio_blocks/hybrid_pvt_cc.h
@@ -51,7 +51,6 @@
 #include "kml_printer.h"
 #include "geojson_printer.h"
 #include "rinex_printer.h"
-#include "nmea_printer.h"
 #include "hybrid_ls_pvt.h"
 #include "GPS_L1_CA.h"
 #include "Galileo_E1.h"
diff --git a/src/algorithms/PVT/libs/galileo_e1_ls_pvt.cc b/src/algorithms/PVT/libs/galileo_e1_ls_pvt.cc
index 157c034..864b7e7 100644
--- a/src/algorithms/PVT/libs/galileo_e1_ls_pvt.cc
+++ b/src/algorithms/PVT/libs/galileo_e1_ls_pvt.cc
@@ -181,7 +181,7 @@ bool galileo_e1_ls_pvt::get_PVT(std::map<int,Gnss_Synchro> gnss_pseudoranges_map
             DLOG(INFO) << "obs="<< obs;
             DLOG(INFO) << "W=" << W;
 
-            mypos = leastSquarePos(satpos, obs, W);
+            mypos = galileo_e1_ls_pvt::leastSquarePos(satpos, obs, W);
 
             // Compute GST and Gregorian time
             //double GST = galileo_ephemeris_iter->second.Galileo_System_Time(Galileo_week_number, galileo_current_time);
@@ -194,7 +194,7 @@ bool galileo_e1_ls_pvt::get_PVT(std::map<int,Gnss_Synchro> gnss_pseudoranges_map
             d_position_UTC_time = p_time;
             DLOG(INFO) << "Galileo Position at TOW=" << galileo_current_time << " in ECEF (X,Y,Z) = " << mypos;
 
-            cart2geo(static_cast<double>(mypos(0)), static_cast<double>(mypos(1)), static_cast<double>(mypos(2)), 4);
+            galileo_e1_ls_pvt::cart2geo(static_cast<double>(mypos(0)), static_cast<double>(mypos(1)), static_cast<double>(mypos(2)), 4);
             //ToDo: Find an Observables/PVT random bug with some satellite configurations that gives an erratic PVT solution (i.e. height>50 km)
             if (d_height_m > 50000)
                 {
diff --git a/src/algorithms/PVT/libs/geojson_printer.cc b/src/algorithms/PVT/libs/geojson_printer.cc
index 8668d1c..6a642ba 100644
--- a/src/algorithms/PVT/libs/geojson_printer.cc
+++ b/src/algorithms/PVT/libs/geojson_printer.cc
@@ -41,7 +41,7 @@ GeoJSON_Printer::GeoJSON_Printer () {}
 
 GeoJSON_Printer::~GeoJSON_Printer ()
 {
-    close_file();
+    GeoJSON_Printer::close_file();
 }
 
 
diff --git a/src/algorithms/PVT/libs/gps_l1_ca_ls_pvt.cc b/src/algorithms/PVT/libs/gps_l1_ca_ls_pvt.cc
index 5598f96..d51f4e3 100644
--- a/src/algorithms/PVT/libs/gps_l1_ca_ls_pvt.cc
+++ b/src/algorithms/PVT/libs/gps_l1_ca_ls_pvt.cc
@@ -166,9 +166,13 @@ bool gps_l1_ca_ls_pvt::get_PVT(std::map<int,Gnss_Synchro> gnss_pseudoranges_map,
             DLOG(INFO) << "satpos=" << satpos;
             DLOG(INFO) << "obs=" << obs;
             DLOG(INFO) << "W=" << W;
+
             mypos = gps_l1_ca_ls_pvt::leastSquarePos(satpos, obs, W);
+
             DLOG(INFO) << "(new)Position at TOW=" << GPS_current_time << " in ECEF (X,Y,Z) = " << mypos;
+
             gps_l1_ca_ls_pvt::cart2geo(mypos(0), mypos(1), mypos(2), 4);
+
             //ToDo: Find an Observables/PVT random bug with some satellite configurations that gives an erratic PVT solution (i.e. height>50 km)
             if (d_height_m > 50000)
                 {
diff --git a/src/algorithms/PVT/libs/hybrid_ls_pvt.cc b/src/algorithms/PVT/libs/hybrid_ls_pvt.cc
index e387a18..8bd8532 100644
--- a/src/algorithms/PVT/libs/hybrid_ls_pvt.cc
+++ b/src/algorithms/PVT/libs/hybrid_ls_pvt.cc
@@ -257,7 +257,8 @@ bool hybrid_ls_pvt::get_PVT(std::map<int,Gnss_Synchro> gnss_pseudoranges_map, do
             DLOG(INFO) << "satpos=" << satpos;
             DLOG(INFO) << "obs="<< obs;
             DLOG(INFO) << "W=" << W;
-            mypos = leastSquarePos(satpos, obs, W);
+
+            mypos = hybrid_ls_pvt::leastSquarePos(satpos, obs, W);
 
             // Compute GST and Gregorian time
             double GST = galileo_ephemeris_map.find(gnss_pseudoranges_iter->first)->second.Galileo_System_Time(Galileo_week_number, hybrid_current_time);
@@ -269,7 +270,7 @@ bool hybrid_ls_pvt::get_PVT(std::map<int,Gnss_Synchro> gnss_pseudoranges_map, do
             d_position_UTC_time = p_time;
             DLOG(INFO) << "HYBRID Position at TOW=" << hybrid_current_time << " in ECEF (X,Y,Z) = " << mypos;
 
-            cart2geo(static_cast<double>(mypos(0)), static_cast<double>(mypos(1)), static_cast<double>(mypos(2)), 4);
+            hybrid_ls_pvt::cart2geo(static_cast<double>(mypos(0)), static_cast<double>(mypos(1)), static_cast<double>(mypos(2)), 4);
             //ToDo: Find an Observables/PVT random bug with some satellite configurations that gives an erratic PVT solution (i.e. height>50 km)
             if (d_height_m > 50000)
                 {
@@ -290,7 +291,7 @@ bool hybrid_ls_pvt::get_PVT(std::map<int,Gnss_Synchro> gnss_pseudoranges_map, do
 
 
             // ###### Compute DOPs ########
-            compute_DOP();
+            hybrid_ls_pvt::compute_DOP();
 
             // ######## LOG FILE #########
             if(d_flag_dump_enabled == true)
diff --git a/src/algorithms/PVT/libs/ls_pvt.cc b/src/algorithms/PVT/libs/ls_pvt.cc
index a618692..d2251e2 100644
--- a/src/algorithms/PVT/libs/ls_pvt.cc
+++ b/src/algorithms/PVT/libs/ls_pvt.cc
@@ -38,9 +38,6 @@
 
 using google::LogMessage;
 
-//DEFINE_bool(tropo, true, "Apply tropospheric correction");
-
-
 
 Ls_Pvt::Ls_Pvt() : Pvt_Solution()
 {
diff --git a/src/algorithms/PVT/libs/pvt_solution.cc b/src/algorithms/PVT/libs/pvt_solution.cc
index fd2edc4..c1af92d 100644
--- a/src/algorithms/PVT/libs/pvt_solution.cc
+++ b/src/algorithms/PVT/libs/pvt_solution.cc
@@ -511,9 +511,9 @@ int Pvt_Solution::pos_averaging(bool flag_averaring)
                     d_hist_latitude_d.push_front(d_latitude_d);
                     d_hist_height_m.push_front(d_height_m);
 
-                    d_avg_latitude_d = 0;
-                    d_avg_longitude_d = 0;
-                    d_avg_height_m = 0;
+                    d_avg_latitude_d = 0.0;
+                    d_avg_longitude_d = 0.0;
+                    d_avg_height_m = 0.0;
                     for (unsigned int i = 0; i < d_hist_longitude_d.size(); i++)
                         {
                             d_avg_latitude_d = d_avg_latitude_d + d_hist_latitude_d.at(i);
diff --git a/src/algorithms/PVT/libs/pvt_solution.h b/src/algorithms/PVT/libs/pvt_solution.h
index 7adec71..456f7da 100644
--- a/src/algorithms/PVT/libs/pvt_solution.h
+++ b/src/algorithms/PVT/libs/pvt_solution.h
@@ -81,7 +81,7 @@ public:
     double d_HDOP;
     double d_VDOP;
     double d_TDOP;
-    int compute_DOP(); //!< Compute Dilution Of Precision
+    int compute_DOP(); //!< Compute Dilution Of Precision parameters
 
     bool d_flag_averaging;
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-hamradio/gnss-sdr.git



More information about the pkg-hamradio-commits mailing list