1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2024-12-14 20:20:35 +00:00

Fix instantiation of tracking blocks with empty configuration

This commit is contained in:
Carles Fernandez 2020-02-20 08:23:57 +01:00
parent 3b965654d6
commit b6c2911f39
No known key found for this signature in database
GPG Key ID: 4C583C52B0C3877D
2 changed files with 5 additions and 4 deletions

View File

@ -29,7 +29,7 @@ Dll_Pll_Conf::Dll_Pll_Conf()
/* DLL/PLL tracking configuration */
high_dyn = false;
smoother_length = 10;
fs_in = 0.0;
fs_in = 2000000.0;
vector_length = 0U;
dump = false;
dump_mat = true;
@ -81,7 +81,8 @@ void Dll_Pll_Conf::SetFromConfiguration(ConfigurationInterface *configuration,
item_type = configuration->property(role + ".item_type", item_type);
if (!item_type_valid(item_type))
{
throw std::invalid_argument("Unknown item type: " + item_type);
LOG(WARNING) << "Unknown item type: " + item_type << ". Set to gr_complex";
item_type = "gr_complex";
}
int fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", fs_in);

View File

@ -30,7 +30,7 @@ Dll_Pll_Conf_Fpga::Dll_Pll_Conf_Fpga()
/* DLL/PLL tracking configuration */
high_dyn = false;
smoother_length = 10;
fs_in = 0.0;
fs_in = 12500000.0;
vector_length = 0U;
dump = false;
dump_mat = true;
@ -89,7 +89,7 @@ Dll_Pll_Conf_Fpga::Dll_Pll_Conf_Fpga()
void Dll_Pll_Conf_Fpga::SetFromConfiguration(ConfigurationInterface *configuration,
const std::string &role)
{
int32_t fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", 12500000);
int32_t fs_in_deprecated = configuration->property("GNSS-SDR.internal_fs_hz", fs_in);
fs_in = configuration->property("GNSS-SDR.internal_fs_sps", fs_in_deprecated);
high_dyn = configuration->property(role + ".high_dyn", high_dyn);
smoother_length = configuration->property(role + ".smoother_length", smoother_length);