1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2024-12-13 11:40:33 +00:00

Add -dll_bw_hz and -pll_bw_hz commandline flags

API of Galileo_E5a_DLL_PLL_Tracking has been changed for consistency with other blocks
This commit is contained in:
Carles Fernandez 2018-02-18 19:28:21 +01:00
parent 22654d6c1a
commit e5fd943303
19 changed files with 80 additions and 45 deletions

View File

@ -224,19 +224,15 @@ Tracking_5X.implementation=Galileo_E5a_DLL_PLL_Tracking
Tracking_5X.item_type=gr_complex
;#sampling_frequency: Signal Intermediate Frequency in [Hz]
Tracking_5X.if=0
;#pll_bw_hz_init: **Only for E5a** PLL loop filter bandwidth during initialization [Hz]
Tracking_5X.pll_bw_hz_init=20.0;
;#dll_bw_hz_init: **Only for E5a** DLL loop filter bandwidth during initialization [Hz]
Tracking_5X.dll_bw_hz_init=20.0;
;#dll_ti_ms: **Only for E5a** loop filter integration time after initialization (secondary code delay search)[ms]
;Tracking_5X.ti_ms=3;
Tracking_5X.ti_ms=1;
;#pll_bw_hz: PLL loop filter bandwidth [Hz]
;Tracking.pll_bw_hz=5.0;
;#pll_bw_hz: PLL loop filter bandwidth during initialization [Hz]
Tracking_5X.pll_bw_hz=20.0;
;#dll_bw_hz: DLL loop filter bandwidth [Hz]
;Tracking.dll_bw_hz=2.0;
;#dll_bw_hz: DLL loop filter bandwidth during initialization [Hz]
Tracking_5X.dll_bw_hz=20.0;
Tracking_5X.pll_bw_narrow_hz=2.0;
Tracking_5X.dll_bw_narrow_hz=5.0;
;#order: PLL/DLL loop filter order [2] or [3]
Tracking_5X.order=2;
;#early_late_space_chips: correlator early-late space [chips]. Use [0.5]

View File

@ -118,11 +118,11 @@ Acquisition_5X.dump_filename=./acq_dump.dat
Tracking_5X.implementation=Galileo_E5a_DLL_PLL_Tracking
Tracking_5X.item_type=gr_complex
Tracking_5X.if=0
Tracking_5X.pll_bw_hz_init=20.0; **Only for E5a** PLL loop filter bandwidth during initialization [Hz]
Tracking_5X.dll_bw_hz_init=20.0; **Only for E5a** DLL loop filter bandwidth during initialization [Hz]
Tracking_5X.ti_ms=1; **Only for E5a** loop filter integration time after initialization (secondary code delay search)[ms]
Tracking_5X.pll_bw_hz=20.0;
Tracking_5X.dll_bw_hz=20.0;
Tracking_5X.ti_ms=1; **Only for E5a** loop filter integration time after initialization (secondary code delay search)[ms]
Tracking_5X.pll_bw_narrow_hz=20.0;
Tracking_5X.dll_bw_narrow_hz=20.0;
Tracking_5X.order=2;
Tracking_5X.early_late_space_chips=0.5;
Tracking_5X.dump=false

View File

@ -52,3 +52,6 @@ DEFINE_double(carrier_lock_th, 0.85, "Carrier lock threshold (in rad)");
DEFINE_string(RINEX_version, "3.02", "Specifies the RINEX version (2.11 or 3.02)");
DEFINE_double(dll_bw_hz, 0.0, "If defined, bandwidth of the DLL low pass filter, in Hz (overrides the configuration file)");
DEFINE_double(pll_bw_hz, 0.0, "If defined, bandwidth of the PLL low pass filter, in Hz (overrides the configuration file)");

View File

@ -52,6 +52,8 @@ DECLARE_uint32(cn0_samples); //<! Number of correlator outputs used for C
DECLARE_uint32(cn0_min); //<! Minimum valid CN0 (in dB-Hz)
DECLARE_uint32(max_lock_fail); //<! Number number of lock failures before dropping satellite
DECLARE_double(carrier_lock_th); //<! Carrier lock threshold (in rad)
DECLARE_double(dll_bw_hz); //<! Bandwidth of the DLL low pass filter, in Hz (overrides the configuration file)
DECLARE_double(pll_bw_hz) //<! Bandwidth of the PLL low pass filter, in Hz (overrides the configuration file)
// Declare flags for PVT
DECLARE_string(RINEX_version); //<! RINEX version

View File

@ -58,4 +58,4 @@ file(GLOB TRACKING_ADAPTER_HEADERS "*.h")
list(SORT TRACKING_ADAPTER_HEADERS)
add_library(tracking_adapters ${TRACKING_ADAPTER_SOURCES} ${TRACKING_ADAPTER_HEADERS})
source_group(Headers FILES ${TRACKING_ADAPTER_HEADERS})
target_link_libraries(tracking_adapters tracking_gr_blocks gnss_sp_libs)
target_link_libraries(tracking_adapters tracking_gr_blocks gnss_sp_libs gnss_sdr_flags)

View File

@ -38,6 +38,7 @@
#include <glog/logging.h>
#include "Galileo_E1.h"
#include "configuration_interface.h"
#include "gnss_sdr_flags.h"
using google::LogMessage;
@ -71,7 +72,9 @@ GalileoE1DllPllVemlTracking::GalileoE1DllPllVemlTracking(
f_if = configuration->property(role + ".if", 0);
dump = configuration->property(role + ".dump", false);
pll_bw_hz = configuration->property(role + ".pll_bw_hz", 5.0);
if(FLAGS_pll_bw_hz != 0.0) pll_bw_hz = static_cast<float>(FLAGS_pll_bw_hz);
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 0.5);
if(FLAGS_dll_bw_hz != 0.0) dll_bw_hz = static_cast<float>(FLAGS_dll_bw_hz);
pll_bw_narrow_hz = configuration->property(role + ".pll_bw_narrow_hz", 2.0);
dll_bw_narrow_hz = configuration->property(role + ".dll_bw_narrow_hz", 0.25);
int extend_correlation_symbols;

View File

@ -39,6 +39,7 @@
#include <glog/logging.h>
#include "Galileo_E1.h"
#include "configuration_interface.h"
#include "gnss_sdr_flags.h"
using google::LogMessage;
@ -68,7 +69,9 @@ GalileoE1TcpConnectorTracking::GalileoE1TcpConnectorTracking(
f_if = configuration->property(role + ".if", 0);
dump = configuration->property(role + ".dump", false);
pll_bw_hz = configuration->property(role + ".pll_bw_hz", 50.0);
if(FLAGS_pll_bw_hz != 0.0) pll_bw_hz = static_cast<float>(FLAGS_pll_bw_hz);
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 2.0);
if(FLAGS_dll_bw_hz != 0.0) dll_bw_hz = static_cast<float>(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);
port_ch0 = configuration->property(role + ".port_ch0", 2060);

View File

@ -40,6 +40,7 @@
#include <glog/logging.h>
#include "Galileo_E5a.h"
#include "configuration_interface.h"
#include "gnss_sdr_flags.h"
using google::LogMessage;
@ -60,8 +61,8 @@ GalileoE5aDllPllTracking::GalileoE5aDllPllTracking(
std::string default_item_type = "gr_complex";
float pll_bw_hz;
float dll_bw_hz;
float pll_bw_init_hz;
float dll_bw_init_hz;
float pll_bw_narrow_hz;
float dll_bw_narrow_hz;
int ti_ms;
float early_late_space_chips;
item_type = configuration->property(role + ".item_type", default_item_type);
@ -70,10 +71,12 @@ GalileoE5aDllPllTracking::GalileoE5aDllPllTracking(
fs_in = configuration->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
f_if = configuration->property(role + ".if", 0);
dump = configuration->property(role + ".dump", false);
pll_bw_hz = configuration->property(role + ".pll_bw_hz", 5.0);
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 2.0);
pll_bw_init_hz = configuration->property(role + ".pll_bw_init_hz", 20.0);
dll_bw_init_hz = configuration->property(role + ".dll_bw_init_hz", 20.0);
pll_bw_hz = configuration->property(role + ".pll_bw_hz", 20.0);
if(FLAGS_pll_bw_hz != 0.0) pll_bw_hz = static_cast<float>(FLAGS_pll_bw_hz);
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 20.0);
if(FLAGS_dll_bw_hz != 0.0) dll_bw_hz = static_cast<float>(FLAGS_dll_bw_hz);
pll_bw_narrow_hz = configuration->property(role + ".pll_bw_narrow_hz", 5.0);
dll_bw_narrow_hz = configuration->property(role + ".dll_bw_narrow_hz", 2.0);
ti_ms = configuration->property(role + ".ti_ms", 3);
early_late_space_chips = configuration->property(role + ".early_late_space_chips", 0.5);
@ -94,8 +97,8 @@ GalileoE5aDllPllTracking::GalileoE5aDllPllTracking(
dump_filename,
pll_bw_hz,
dll_bw_hz,
pll_bw_init_hz,
dll_bw_init_hz,
pll_bw_narrow_hz,
dll_bw_narrow_hz,
ti_ms,
early_late_space_chips);
}

View File

@ -41,6 +41,7 @@
#include <glog/logging.h>
#include "GLONASS_L1_CA.h"
#include "configuration_interface.h"
#include "gnss_sdr_flags.h"
using google::LogMessage;
@ -70,7 +71,9 @@ GlonassL1CaDllPllCAidTracking::GlonassL1CaDllPllCAidTracking(
f_if = configuration->property(role + ".if", 0);
dump = configuration->property(role + ".dump", false);
pll_bw_hz = configuration->property(role + ".pll_bw_hz", 50.0);
if(FLAGS_pll_bw_hz != 0.0) pll_bw_hz = static_cast<float>(FLAGS_pll_bw_hz);
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 2.0);
if(FLAGS_dll_bw_hz != 0.0) dll_bw_hz = static_cast<float>(FLAGS_dll_bw_hz);
pll_bw_narrow_hz = configuration->property(role + ".pll_bw_narrow_hz", 20.0);
dll_bw_narrow_hz = configuration->property(role + ".dll_bw_narrow_hz", 2.0);
int extend_correlation_ms;

View File

@ -40,6 +40,7 @@
#include <glog/logging.h>
#include "GLONASS_L1_CA.h"
#include "configuration_interface.h"
#include "gnss_sdr_flags.h"
using google::LogMessage;
@ -67,7 +68,9 @@ GlonassL1CaDllPllTracking::GlonassL1CaDllPllTracking(
f_if = configuration->property(role + ".if", 0);
dump = configuration->property(role + ".dump", false);
pll_bw_hz = configuration->property(role + ".pll_bw_hz", 50.0);
if(FLAGS_pll_bw_hz != 0.0) pll_bw_hz = static_cast<float>(FLAGS_pll_bw_hz);
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 2.0);
if(FLAGS_dll_bw_hz != 0.0) dll_bw_hz = static_cast<float>(FLAGS_dll_bw_hz);
early_late_space_chips = configuration->property(role + ".early_late_space_chips", 0.5);
std::string default_dump_filename = "./track_ch";
dump_filename = configuration->property(role + ".dump_filename", default_dump_filename); //unused!

View File

@ -40,6 +40,7 @@
#include <glog/logging.h>
#include "GPS_L1_CA.h"
#include "configuration_interface.h"
#include "gnss_sdr_flags.h"
using google::LogMessage;
@ -69,7 +70,9 @@ GpsL1CaDllPllCAidTracking::GpsL1CaDllPllCAidTracking(
f_if = configuration->property(role + ".if", 0);
dump = configuration->property(role + ".dump", false);
pll_bw_hz = configuration->property(role + ".pll_bw_hz", 50.0);
if(FLAGS_pll_bw_hz != 0.0) pll_bw_hz = static_cast<float>(FLAGS_pll_bw_hz);
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 2.0);
if(FLAGS_dll_bw_hz != 0.0) dll_bw_hz = static_cast<float>(FLAGS_dll_bw_hz);
pll_bw_narrow_hz = configuration->property(role + ".pll_bw_narrow_hz", 20.0);
dll_bw_narrow_hz = configuration->property(role + ".dll_bw_narrow_hz", 2.0);
int extend_correlation_ms;

View File

@ -40,6 +40,8 @@
#include <glog/logging.h>
#include "GPS_L1_CA.h"
#include "configuration_interface.h"
#include "gnss_sdr_flags.h"
using google::LogMessage;
@ -70,7 +72,9 @@ GpsL1CaDllPllCAidTrackingFpga::GpsL1CaDllPllCAidTrackingFpga(
f_if = configuration->property(role + ".if", 0);
dump = configuration->property(role + ".dump", false);
pll_bw_hz = configuration->property(role + ".pll_bw_hz", 50.0);
if(FLAGS_pll_bw_hz != 0.0) pll_bw_hz = static_cast<float>(FLAGS_pll_bw_hz);
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 2.0);
if(FLAGS_dll_bw_hz != 0.0) dll_bw_hz = static_cast<float>(FLAGS_dll_bw_hz);
pll_bw_narrow_hz = configuration->property(role + ".pll_bw_narrow_hz", 20.0);
dll_bw_narrow_hz = configuration->property(role + ".dll_bw_narrow_hz", 2.0);
int extend_correlation_ms;

View File

@ -40,6 +40,7 @@
#include <glog/logging.h>
#include "GPS_L1_CA.h"
#include "configuration_interface.h"
#include "gnss_sdr_flags.h"
using google::LogMessage;
@ -67,7 +68,9 @@ GpsL1CaDllPllTracking::GpsL1CaDllPllTracking(
f_if = configuration->property(role + ".if", 0);
dump = configuration->property(role + ".dump", false);
pll_bw_hz = configuration->property(role + ".pll_bw_hz", 50.0);
if(FLAGS_pll_bw_hz != 0.0) pll_bw_hz = static_cast<float>(FLAGS_pll_bw_hz);
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 2.0);
if(FLAGS_dll_bw_hz != 0.0) dll_bw_hz = static_cast<float>(FLAGS_dll_bw_hz);
early_late_space_chips = configuration->property(role + ".early_late_space_chips", 0.5);
std::string default_dump_filename = "./track_ch";
dump_filename = configuration->property(role + ".dump_filename", default_dump_filename); //unused!

View File

@ -39,6 +39,7 @@
#include <glog/logging.h>
#include "GPS_L1_CA.h"
#include "configuration_interface.h"
#include "gnss_sdr_flags.h"
using google::LogMessage;
@ -67,7 +68,9 @@ GpsL1CaDllPllTrackingGPU::GpsL1CaDllPllTrackingGPU(
f_if = configuration->property(role + ".if", 0);
dump = configuration->property(role + ".dump", false);
pll_bw_hz = configuration->property(role + ".pll_bw_hz", 50.0);
if(FLAGS_pll_bw_hz != 0.0) pll_bw_hz = static_cast<float>(FLAGS_pll_bw_hz);
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 2.0);
if(FLAGS_dll_bw_hz != 0.0) dll_bw_hz = static_cast<float>(FLAGS_dll_bw_hz);
early_late_space_chips = configuration->property(role + ".early_late_space_chips", 0.5);
std::string default_dump_filename = "./track_ch";
dump_filename = configuration->property(role + ".dump_filename",

View File

@ -39,6 +39,7 @@
#include <glog/logging.h>
#include "GPS_L2C.h"
#include "configuration_interface.h"
#include "gnss_sdr_flags.h"
using google::LogMessage;
@ -66,7 +67,9 @@ GpsL2MDllPllTracking::GpsL2MDllPllTracking(
f_if = configuration->property(role + ".if", 0);
dump = configuration->property(role + ".dump", false);
pll_bw_hz = configuration->property(role + ".pll_bw_hz", 50.0);
if(FLAGS_pll_bw_hz != 0.0) pll_bw_hz = static_cast<float>(FLAGS_pll_bw_hz);
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 2.0);
if(FLAGS_dll_bw_hz != 0.0) dll_bw_hz = static_cast<float>(FLAGS_dll_bw_hz);
early_late_space_chips = configuration->property(role + ".early_late_space_chips", 0.5);
std::string default_dump_filename = "./track_ch";
dump_filename = configuration->property(role + ".dump_filename",

View File

@ -39,6 +39,7 @@
#include <glog/logging.h>
#include "GPS_L5.h"
#include "configuration_interface.h"
#include "gnss_sdr_flags.h"
using google::LogMessage;
@ -66,7 +67,9 @@ GpsL5iDllPllTracking::GpsL5iDllPllTracking(
f_if = configuration->property(role + ".if", 0);
dump = configuration->property(role + ".dump", false);
pll_bw_hz = configuration->property(role + ".pll_bw_hz", 50.0);
if(FLAGS_pll_bw_hz != 0.0) pll_bw_hz = static_cast<float>(FLAGS_pll_bw_hz);
dll_bw_hz = configuration->property(role + ".dll_bw_hz", 2.0);
if(FLAGS_dll_bw_hz != 0.0) dll_bw_hz = static_cast<float>(FLAGS_dll_bw_hz);
early_late_space_chips = configuration->property(role + ".early_late_space_chips", 0.5);
std::string default_dump_filename = "./track_ch";
dump_filename = configuration->property(role + ".dump_filename",

View File

@ -63,13 +63,13 @@ galileo_e5a_dll_pll_make_tracking_cc(
std::string dump_filename,
float pll_bw_hz,
float dll_bw_hz,
float pll_bw_init_hz,
float dll_bw_init_hz,
float pll_bw_narrow_hz,
float dll_bw_narrow_hz,
int ti_ms,
float early_late_space_chips)
{
return galileo_e5a_dll_pll_tracking_cc_sptr(new Galileo_E5a_Dll_Pll_Tracking_cc(if_freq,
fs_in, vector_length, dump, dump_filename, pll_bw_hz, dll_bw_hz, pll_bw_init_hz, dll_bw_init_hz, ti_ms, early_late_space_chips));
fs_in, vector_length, dump, dump_filename, pll_bw_hz, dll_bw_hz, pll_bw_narrow_hz, dll_bw_narrow_hz, ti_ms, early_late_space_chips));
}
@ -91,8 +91,8 @@ Galileo_E5a_Dll_Pll_Tracking_cc::Galileo_E5a_Dll_Pll_Tracking_cc(
std::string dump_filename,
float pll_bw_hz,
float dll_bw_hz,
float pll_bw_init_hz,
float dll_bw_init_hz,
float pll_bw_narrow_hz,
float dll_bw_narrow_hz,
int ti_ms,
float early_late_space_chips) :
gr::block("Galileo_E5a_Dll_Pll_Tracking_cc", gr::io_signature::make(1, 1, sizeof(gr_complex)),
@ -114,12 +114,12 @@ Galileo_E5a_Dll_Pll_Tracking_cc::Galileo_E5a_Dll_Pll_Tracking_cc(
d_ti_ms = ti_ms;
d_dll_bw_hz = dll_bw_hz;
d_pll_bw_hz = pll_bw_hz;
d_dll_bw_init_hz = dll_bw_init_hz;
d_pll_bw_init_hz = pll_bw_init_hz;
d_dll_bw_narrow_hz = dll_bw_narrow_hz;
d_pll_bw_narrow_hz = pll_bw_narrow_hz;
// Initialize tracking ==========================================
d_code_loop_filter.set_DLL_BW(d_dll_bw_init_hz);
d_carrier_loop_filter.set_PLL_BW(d_pll_bw_init_hz);
d_code_loop_filter.set_DLL_BW(d_dll_bw_hz);
d_carrier_loop_filter.set_PLL_BW(d_pll_bw_hz);
//--- DLL variables --------------------------------------------------------
d_early_late_spc_chips = early_late_space_chips; // Define early-late offset (in chips)
@ -581,8 +581,8 @@ int Galileo_E5a_Dll_Pll_Tracking_cc::general_work (int noutput_items __attribute
// Change loop parameters ==========================================
d_code_loop_filter.set_pdi(d_current_ti_ms * GALILEO_E5a_CODE_PERIOD);
d_carrier_loop_filter.set_pdi(d_current_ti_ms * GALILEO_E5a_CODE_PERIOD);
d_code_loop_filter.set_DLL_BW(d_dll_bw_hz);
d_carrier_loop_filter.set_PLL_BW(d_pll_bw_hz);
d_code_loop_filter.set_DLL_BW(d_dll_bw_narrow_hz);
d_carrier_loop_filter.set_PLL_BW(d_pll_bw_narrow_hz);
}
else
{

View File

@ -59,8 +59,8 @@ galileo_e5a_dll_pll_make_tracking_cc(long if_freq,
std::string dump_filename,
float pll_bw_hz,
float dll_bw_hz,
float pll_bw_init_hz,
float dll_bw_init_hz,
float pll_bw_narrow_narrowhz,
float dll_bw_narrow_hz,
int ti_ms,
float early_late_space_chips);
@ -92,8 +92,8 @@ private:
std::string dump_filename,
float pll_bw_hz,
float dll_bw_hz,
float pll_bw_init_hz,
float dll_bw_init_hz,
float pll_bw_narrow_hz,
float dll_bw_narrow_hz,
int ti_ms,
float early_late_space_chips);
@ -104,8 +104,8 @@ private:
std::string dump_filename,
float pll_bw_hz,
float dll_bw_hz,
float pll_bw_init_hz,
float dll_bw_init_hz,
float pll_bw_narrow_hz,
float dll_bw_narrow_hz,
int ti_ms,
float early_late_space_chips);
void acquire_secondary();
@ -124,8 +124,8 @@ private:
double d_early_late_spc_chips;
double d_dll_bw_hz;
double d_pll_bw_hz;
double d_dll_bw_init_hz;
double d_pll_bw_init_hz;
double d_dll_bw_narrow_hz;
double d_pll_bw_narrow_hz;
gr_complex* d_codeQ;
gr_complex* d_codeI;

View File

@ -92,10 +92,10 @@ void GalileoE5aTrackingTest::init()
config->set_property("Tracking_5X.dump_filename", "../data/e5a_tracking_ch_");
config->set_property("Tracking_5X.early_late_space_chips", "0.5");
config->set_property("Tracking_5X.order", "2");
config->set_property("Tracking_5X.pll_bw_hz_init","20.0");
config->set_property("Tracking_5X.pll_bw_hz", "5");
config->set_property("Tracking_5X.dll_bw_hz_init","2.0");
config->set_property("Tracking_5X.dll_bw_hz", "2");
config->set_property("Tracking_5X.pll_bw_hz","20.0");
config->set_property("Tracking_5X.dll_bw_hz", "5.0");
config->set_property("Tracking_5X.pll_bw_narrow_hz","2.0");
config->set_property("Tracking_5X.pll_bw_narrow_hz", "2.0");
config->set_property("Tracking_5X.ti_ms", "1");
}