diff --git a/src/algorithms/tracking/adapters/galileo_e1_dll_pll_veml_tracking.cc b/src/algorithms/tracking/adapters/galileo_e1_dll_pll_veml_tracking.cc index 1beba6c51..174112c03 100644 --- a/src/algorithms/tracking/adapters/galileo_e1_dll_pll_veml_tracking.cc +++ b/src/algorithms/tracking/adapters/galileo_e1_dll_pll_veml_tracking.cc @@ -134,11 +134,11 @@ GalileoE1DllPllVemlTracking::GalileoE1DllPllVemlTracking( int extend_correlation_symbols = configuration->property(role + ".extend_correlation_symbols", 1); float early_late_space_chips = configuration->property(role + ".early_late_space_chips", 0.15); trk_param.early_late_space_chips = early_late_space_chips; - float very_early_late_space_chips = configuration->property(role + ".very_early_late_space_chips", 0.6); + float very_early_late_space_chips = configuration->property(role + ".very_early_late_space_chips", 0.5); trk_param.very_early_late_space_chips = very_early_late_space_chips; float early_late_space_narrow_chips = configuration->property(role + ".early_late_space_narrow_chips", 0.15); trk_param.early_late_space_narrow_chips = early_late_space_narrow_chips; - float very_early_late_space_narrow_chips = configuration->property(role + ".very_early_late_space_narrow_chips", 0.6); + float very_early_late_space_narrow_chips = configuration->property(role + ".very_early_late_space_narrow_chips", 0.5); trk_param.very_early_late_space_narrow_chips = very_early_late_space_narrow_chips; bool track_pilot = configuration->property(role + ".track_pilot", false); if (extend_correlation_symbols < 1) diff --git a/src/algorithms/tracking/adapters/galileo_e1_dll_pll_veml_tracking_fpga.cc b/src/algorithms/tracking/adapters/galileo_e1_dll_pll_veml_tracking_fpga.cc index 531f64560..4d00fff10 100644 --- a/src/algorithms/tracking/adapters/galileo_e1_dll_pll_veml_tracking_fpga.cc +++ b/src/algorithms/tracking/adapters/galileo_e1_dll_pll_veml_tracking_fpga.cc @@ -81,11 +81,11 @@ GalileoE1DllPllVemlTrackingFpga::GalileoE1DllPllVemlTrackingFpga( int32_t extend_correlation_symbols = configuration->property(role + ".extend_correlation_symbols", 1); float early_late_space_chips = configuration->property(role + ".early_late_space_chips", 0.15); trk_param_fpga.early_late_space_chips = early_late_space_chips; - float very_early_late_space_chips = configuration->property(role + ".very_early_late_space_chips", 0.6); + float very_early_late_space_chips = configuration->property(role + ".very_early_late_space_chips", 0.5); trk_param_fpga.very_early_late_space_chips = very_early_late_space_chips; float early_late_space_narrow_chips = configuration->property(role + ".early_late_space_narrow_chips", 0.15); trk_param_fpga.early_late_space_narrow_chips = early_late_space_narrow_chips; - float very_early_late_space_narrow_chips = configuration->property(role + ".very_early_late_space_narrow_chips", 0.6); + float very_early_late_space_narrow_chips = configuration->property(role + ".very_early_late_space_narrow_chips", 0.5); trk_param_fpga.very_early_late_space_narrow_chips = very_early_late_space_narrow_chips; bool track_pilot = configuration->property(role + ".track_pilot", false); if (extend_correlation_symbols < 1) diff --git a/src/algorithms/tracking/adapters/galileo_e1_tcp_connector_tracking.cc b/src/algorithms/tracking/adapters/galileo_e1_tcp_connector_tracking.cc index 0d74dcb0d..7864dcea4 100644 --- a/src/algorithms/tracking/adapters/galileo_e1_tcp_connector_tracking.cc +++ b/src/algorithms/tracking/adapters/galileo_e1_tcp_connector_tracking.cc @@ -75,7 +75,7 @@ GalileoE1TcpConnectorTracking::GalileoE1TcpConnectorTracking( dll_bw_hz = static_cast(FLAGS_dll_bw_hz); } early_late_space_chips = configuration->property(role + ".early_late_space_chips", 0.15); - very_early_late_space_chips = configuration->property(role + ".very_early_late_space_chips", 0.6); + very_early_late_space_chips = configuration->property(role + ".very_early_late_space_chips", 0.5); port_ch0 = configuration->property(role + ".port_ch0", 2060); std::string default_dump_filename = "./track_ch"; dump_filename = configuration->property(role + ".dump_filename", default_dump_filename); diff --git a/src/algorithms/tracking/libs/tracking_discriminators.cc b/src/algorithms/tracking/libs/tracking_discriminators.cc index b6ab1490e..994709bcb 100644 --- a/src/algorithms/tracking/libs/tracking_discriminators.cc +++ b/src/algorithms/tracking/libs/tracking_discriminators.cc @@ -95,14 +95,14 @@ double pll_cloop_two_quadrant_atan(gr_complex prompt_s1) */ double dll_nc_e_minus_l_normalized(gr_complex early_s1, gr_complex late_s1) { - double P_early, P_late; - P_early = std::abs(early_s1); - P_late = std::abs(late_s1); - if (P_early + P_late == 0.0) + double P_early = std::abs(early_s1); + double P_late = std::abs(late_s1); + double E_plus_L = P_early + P_late; + if (E_plus_L == 0.0) { return 0.0; } - return 0.5 * (P_early - P_late) / (P_early + P_late); + return 0.5 * (P_early - P_late) / E_plus_L; } @@ -117,12 +117,13 @@ double dll_nc_e_minus_l_normalized(gr_complex early_s1, gr_complex late_s1) */ double dll_nc_vemlp_normalized(gr_complex very_early_s1, gr_complex early_s1, gr_complex late_s1, gr_complex very_late_s1) { - double P_early, P_late; - P_early = std::sqrt(std::norm(very_early_s1) + std::norm(early_s1)); - P_late = std::sqrt(std::norm(very_late_s1) + std::norm(late_s1)); - if (P_early + P_late == 0.0) + double Early = std::sqrt(very_early_s1.real() * very_early_s1.real() + very_early_s1.imag() * very_early_s1.imag() + early_s1.real() * early_s1.real() + early_s1.imag() * early_s1.imag()); + double Late = std::sqrt(late_s1.real() * late_s1.real() + late_s1.imag() * late_s1.imag() + very_late_s1.real() * very_late_s1.real() + very_late_s1.imag() * very_late_s1.imag()); + + double E_plus_L = Early + Late; + if (E_plus_L == 0.0) { return 0.0; } - return (P_early - P_late) / (P_early + P_late); + return (Early - Late) / E_plus_L; } diff --git a/src/core/system_parameters/GPS_L1_CA.h b/src/core/system_parameters/GPS_L1_CA.h index ee81a18e8..5208527ce 100644 --- a/src/core/system_parameters/GPS_L1_CA.h +++ b/src/core/system_parameters/GPS_L1_CA.h @@ -58,7 +58,7 @@ const uint32_t GPS_L1_CA_CODE_PERIOD_MS = 1U; //!< GPS L1 C/A code period const double GPS_L1_CA_CHIP_PERIOD = 9.7752e-07; //!< GPS L1 C/A chip period [seconds] //optimum parameters -const uint32_t GPS_L1_CA_OPT_ACQ_FS_HZ = 1000000; //!< Sampling frequncy that maximizes the acquisition SNR while using a non-multiple of chip rate +const uint32_t GPS_L1_CA_OPT_ACQ_FS_HZ = 2000000; //!< Sampling frequncy that maximizes the acquisition SNR while using a non-multiple of chip rate /*! * \brief Maximum Time-Of-Arrival (TOA) difference between satellites for a receiver operated on Earth surface is 20 ms diff --git a/src/core/system_parameters/GPS_L2C.h b/src/core/system_parameters/GPS_L2C.h index 95542e2e2..367534441 100644 --- a/src/core/system_parameters/GPS_L2C.h +++ b/src/core/system_parameters/GPS_L2C.h @@ -64,7 +64,7 @@ const double GPS_L2_L_PERIOD = 1.5; //!< GPS L2 L code period [s const int32_t GPS_L2C_HISTORY_DEEP = 5; //optimum parameters -const uint32_t GPS_L2C_OPT_ACQ_FS_HZ = 1000000; //!< Sampling frequncy that maximizes the acquisition SNR while using a non-multiple of chip rate +const uint32_t GPS_L2C_OPT_ACQ_FS_HZ = 2000000; //!< Sampling frequncy that maximizes the acquisition SNR while using a non-multiple of chip rate const int32_t GPS_L2C_M_INIT_REG[115] =