diff --git a/CMakeLists.txt b/CMakeLists.txt index e3a44189f..dec1a3edb 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -702,14 +702,25 @@ if(NOT ${FILESYSTEM_FOUND}) set(BOOST_COMPONENTS ${BOOST_COMPONENTS} filesystem) endif() find_package(Boost ${GNSSSDR_BOOST_MIN_VERSION} COMPONENTS ${BOOST_COMPONENTS} REQUIRED) + +if(NOT Boost_FOUND) + message(FATAL_ERROR "Fatal error: Boost (version >=${GNSSSDR_BOOST_MIN_VERSION}) required.") +endif() + set_package_properties(Boost PROPERTIES URL "https://www.boost.org" - DESCRIPTION "Portable C++ source libraries" PURPOSE "Used widely across the source code." TYPE REQUIRED ) -if(NOT Boost_FOUND) - message(FATAL_ERROR "Fatal error: Boost (version >=${GNSSSDR_BOOST_MIN_VERSION}) required.") + +if(CMAKE_VERSION VERSION_GREATER 3.14) + set_package_properties(Boost PROPERTIES + DESCRIPTION "Portable C++ source libraries (found: ${Boost_VERSION_STRING})" + ) +else() + set_package_properties(Boost PROPERTIES + DESCRIPTION "Portable C++ source libraries (found: ${Boost_MAJOR_VERSION}.${Boost_MINOR_VERSION}.${Boost_SUBMINOR_VERSION})" + ) endif() if(CMAKE_VERSION VERSION_LESS 3.5) @@ -1669,6 +1680,10 @@ if(NOT MATIO_FOUND OR MATIO_VERSION_STRING VERSION_LESS ${GNSSSDR_MATIO_MIN_VERS set_package_properties(MATIO PROPERTIES PURPOSE "Matio v${GNSSSDR_MATIO_LOCAL_VERSION} will be downloaded and built when doing '${CMAKE_MAKE_PROGRAM_PRETTY_NAME}'." ) +else() + set_package_properties(MATIO PROPERTIES + DESCRIPTION "MATLAB MAT File I/O Library (found: v.${MATIO_VERSION_STRING})" + ) endif() @@ -1796,6 +1811,13 @@ if(Protobuf_FOUND AND CMAKE_VERSION VERSION_LESS 3.9) set(Protobuf_VERSION "${_PROTOBUF_MAJOR_VERSION}.${_PROTOBUF_MINOR_VERSION}.${_PROTOBUF_SUBMINOR_VERSION}") endif() endif() + +if(Protobuf_FOUND) + set_package_properties(Protobuf PROPERTIES + DESCRIPTION "Structured data serialization mechanism (found: v${Protobuf_VERSION})" + ) +endif() + if(Protobuf_FOUND AND CMAKE_CROSSCOMPILING) find_program(PROTOC_EXECUTABLE protoc) if(NOT PROTOC_EXECUTABLE) @@ -1815,6 +1837,7 @@ if(Protobuf_FOUND AND CMAKE_CROSSCOMPILING) message(FATAL_ERROR "Please install the Protocol Buffers compiler v${Protobuf_VERSION} in the host machine") endif() endif() + if((NOT Protobuf_FOUND) OR (NOT Protobuf_PROTOC_EXECUTABLE) OR (${Protobuf_VERSION} VERSION_LESS ${GNSSSDR_PROTOBUF_MIN_VERSION})) unset(Protobuf_PROTOC_EXECUTABLE) if(CMAKE_CROSSCOMPILING) diff --git a/cmake/Modules/FindLOG4CPP.cmake b/cmake/Modules/FindLOG4CPP.cmake index 784d1f2d0..83d6532ac 100644 --- a/cmake/Modules/FindLOG4CPP.cmake +++ b/cmake/Modules/FindLOG4CPP.cmake @@ -85,7 +85,6 @@ find_library(LOG4CPP_LIBRARY /usr/lib/alpha-linux-gnu /usr/lib64 /usr/lib - /usr/local/lib /opt/local/lib ${LOG4CPP_ROOT}/lib $ENV{LOG4CPP_ROOT}/lib diff --git a/docs/changelog b/docs/changelog index 25156e270..3b8c0438e 100644 --- a/docs/changelog +++ b/docs/changelog @@ -64,8 +64,9 @@ - The receiver now admits FPGA off-loading, allowing for real time operation at high sampling rates and higher number of signals and channels. - Fixed program termination (avoiding hangs and segfaults in some platforms/configurations). - The Labsat_Signal_Source now terminates the receiver's execution when the end of file(s) is reached. It now accepts LabSat 2 filenames and series of LabSat 3 files. -- CMake now generates a summary of enabled/disabled features. This info is also stored in a file called features.log in the building directory. +- Added configuration parameters to set the annotation rate in KML, GPX, GeoJSON and NMEA outputs, set by default to 1 s. - New parameter PVT.show_local_time_zone displays time in the local time zone. Subject to the proper system configuration of the machine running the software receiver. +- CMake now generates a summary of enabled/disabled features. This info is also stored in a file called features.log in the building directory. - Improved information provided to the user in case of failure. diff --git a/src/algorithms/PVT/adapters/rtklib_pvt.cc b/src/algorithms/PVT/adapters/rtklib_pvt.cc index cae7fc052..51579ad06 100644 --- a/src/algorithms/PVT/adapters/rtklib_pvt.cc +++ b/src/algorithms/PVT/adapters/rtklib_pvt.cc @@ -138,6 +138,11 @@ Rtklib_Pvt::Rtklib_Pvt(ConfigurationInterface* configuration, pvt_output_parameters.rtcm_msg_rate_ms[k] = rtcm_MT1097_rate_ms; } + pvt_output_parameters.kml_rate_ms = bc::lcm(configuration->property(role + ".kml_rate_ms", pvt_output_parameters.kml_rate_ms), pvt_output_parameters.output_rate_ms); + pvt_output_parameters.gpx_rate_ms = bc::lcm(configuration->property(role + ".gpx_rate_ms", pvt_output_parameters.gpx_rate_ms), pvt_output_parameters.output_rate_ms); + pvt_output_parameters.geojson_rate_ms = bc::lcm(configuration->property(role + ".geojson_rate_ms", pvt_output_parameters.geojson_rate_ms), pvt_output_parameters.output_rate_ms); + pvt_output_parameters.nmea_rate_ms = bc::lcm(configuration->property(role + ".nmea_rate_ms", pvt_output_parameters.nmea_rate_ms), pvt_output_parameters.output_rate_ms); + // Infer the type of receiver /* * TYPE | RECEIVER diff --git a/src/algorithms/PVT/gnuradio_blocks/rtklib_pvt_gs.cc b/src/algorithms/PVT/gnuradio_blocks/rtklib_pvt_gs.cc index 2af4082b6..199ce7d04 100644 --- a/src/algorithms/PVT/gnuradio_blocks/rtklib_pvt_gs.cc +++ b/src/algorithms/PVT/gnuradio_blocks/rtklib_pvt_gs.cc @@ -178,6 +178,11 @@ rtklib_pvt_gs::rtklib_pvt_gs(uint32_t nchannels, std::string kml_dump_filename; kml_dump_filename = d_dump_filename; d_kml_output_enabled = conf_.kml_output_enabled; + d_kml_rate_ms = conf_.kml_rate_ms; + if (d_kml_rate_ms == 0) + { + d_kml_output_enabled = false; + } if (d_kml_output_enabled) { d_kml_dump = std::make_shared(conf_.kml_output_path); @@ -192,6 +197,11 @@ rtklib_pvt_gs::rtklib_pvt_gs(uint32_t nchannels, std::string gpx_dump_filename; gpx_dump_filename = d_dump_filename; d_gpx_output_enabled = conf_.gpx_output_enabled; + d_gpx_rate_ms = conf_.gpx_rate_ms; + if (d_gpx_rate_ms == 0) + { + d_gpx_output_enabled = false; + } if (d_gpx_output_enabled) { d_gpx_dump = std::make_shared(conf_.gpx_output_path); @@ -206,6 +216,11 @@ rtklib_pvt_gs::rtklib_pvt_gs(uint32_t nchannels, std::string geojson_dump_filename; geojson_dump_filename = d_dump_filename; d_geojson_output_enabled = conf_.geojson_output_enabled; + d_geojson_rate_ms = conf_.geojson_rate_ms; + if (d_geojson_rate_ms == 0) + { + d_geojson_output_enabled = false; + } if (d_geojson_output_enabled) { d_geojson_printer = std::make_shared(conf_.geojson_output_path); @@ -218,6 +233,12 @@ rtklib_pvt_gs::rtklib_pvt_gs(uint32_t nchannels, // initialize nmea_printer d_nmea_output_file_enabled = (conf_.nmea_output_file_enabled or conf_.flag_nmea_tty_port); + d_nmea_rate_ms = conf_.nmea_rate_ms; + if (d_nmea_rate_ms == 0) + { + d_nmea_output_file_enabled = false; + } + if (d_nmea_output_file_enabled) { d_nmea_printer = std::make_shared(conf_.nmea_dump_filename, conf_.nmea_output_file_enabled, conf_.flag_nmea_tty_port, conf_.nmea_dump_devname, conf_.nmea_output_file_path); @@ -1799,19 +1820,31 @@ int rtklib_pvt_gs::work(int noutput_items, gr_vector_const_void_star& input_item } if (d_kml_output_enabled) { - d_kml_dump->print_position(d_pvt_solver, false); + if (current_RX_time_ms % d_kml_rate_ms == 0) + { + d_kml_dump->print_position(d_pvt_solver, false); + } } if (d_gpx_output_enabled) { - d_gpx_dump->print_position(d_pvt_solver, false); + if (current_RX_time_ms % d_gpx_rate_ms == 0) + { + d_gpx_dump->print_position(d_pvt_solver, false); + } } if (d_geojson_output_enabled) { - d_geojson_printer->print_position(d_pvt_solver, false); + if (current_RX_time_ms % d_geojson_rate_ms == 0) + { + d_geojson_printer->print_position(d_pvt_solver, false); + } } if (d_nmea_output_file_enabled) { - d_nmea_printer->Print_Nmea_Line(d_pvt_solver, false); + if (current_RX_time_ms % d_nmea_rate_ms == 0) + { + d_nmea_printer->Print_Nmea_Line(d_pvt_solver, false); + } } /* diff --git a/src/algorithms/PVT/gnuradio_blocks/rtklib_pvt_gs.h b/src/algorithms/PVT/gnuradio_blocks/rtklib_pvt_gs.h index a97874da8..ade48e8b7 100644 --- a/src/algorithms/PVT/gnuradio_blocks/rtklib_pvt_gs.h +++ b/src/algorithms/PVT/gnuradio_blocks/rtklib_pvt_gs.h @@ -106,6 +106,11 @@ private: int32_t d_rtcm_MT1097_rate_ms; // Galileo MSM7. The type 7 Multiple Signal Message format for Europe’s Galileo system int32_t d_rtcm_MSM_rate_ms; + int32_t d_kml_rate_ms; + int32_t d_gpx_rate_ms; + int32_t d_geojson_rate_ms; + int32_t d_nmea_rate_ms; + int32_t d_last_status_print_seg; // for status printer uint32_t d_nchannels; diff --git a/src/algorithms/PVT/libs/pvt_conf.cc b/src/algorithms/PVT/libs/pvt_conf.cc index 990745632..d16db0526 100644 --- a/src/algorithms/PVT/libs/pvt_conf.cc +++ b/src/algorithms/PVT/libs/pvt_conf.cc @@ -35,6 +35,10 @@ Pvt_Conf::Pvt_Conf() type_of_receiver = 0U; output_rate_ms = 0; display_rate_ms = 0; + kml_rate_ms = 1000; + gpx_rate_ms = 1000; + geojson_rate_ms = 1000; + nmea_rate_ms = 1000; rinex_version = 0; rinexobs_rate_ms = 0; diff --git a/src/algorithms/PVT/libs/pvt_conf.h b/src/algorithms/PVT/libs/pvt_conf.h index 7d6b02f89..1b6897e7e 100644 --- a/src/algorithms/PVT/libs/pvt_conf.h +++ b/src/algorithms/PVT/libs/pvt_conf.h @@ -41,6 +41,10 @@ public: uint32_t type_of_receiver; int32_t output_rate_ms; int32_t display_rate_ms; + int32_t kml_rate_ms; + int32_t gpx_rate_ms; + int32_t geojson_rate_ms; + int32_t nmea_rate_ms; int32_t rinex_version; int32_t rinexobs_rate_ms; diff --git a/src/utils/rinex2assist/CMakeLists.txt b/src/utils/rinex2assist/CMakeLists.txt index 312462ea1..78c07c428 100644 --- a/src/utils/rinex2assist/CMakeLists.txt +++ b/src/utils/rinex2assist/CMakeLists.txt @@ -99,3 +99,5 @@ else() message(STATUS "Boost Iostreams library not found.") message(STATUS " rinex2assist will not be built.") endif() + +set(Boost_FOUND TRUE) # trick for summary report