Commit Graph

40 Commits

Author SHA1 Message Date
Carles Fernandez cecf7e5e43
Fix building if boost::endian is not available 2022-12-05 15:02:35 +01:00
Jeff Melville b6c7e4a6f1 Fix register unpacking for Labsat3W files
This change fixes a bug in the unpacking of Labsat 3 Wideband files
when using the Labsat_Signal_Source. The original endian conversion
loop includes a cast from char->uint64_t that (surprisingly) incurs a sign
extension when the MSB of the char is set. ORing the unmasked uint64_t
into the register can set undesired bits.

The changes replace the old endian conversion loop with a ``boost`` utility
function.

Signed-off-by: Jeff Melville <dev@jeffmelville.com>
2022-09-20 10:24:51 -04:00
Carles Fernandez 8d9875e881
Prefer initialization to assignment in constructors 2021-12-14 14:06:37 +01:00
Carles Fernandez cc38d6bc08
Fixes for building against GNU Radio master
Log4cpp has been replaced by spdlog
2021-11-23 13:30:48 +01:00
Carles Fernandez 9e386b8857
Make clang-tidy 13 happy (was: modernize-return-braced-init-list check) 2021-10-08 14:50:05 +02:00
Carles Fernandez ccbe1c9ac9
Add includes (make cpplint's build/include_what_you_use filter happy) 2021-10-08 11:15:01 +02:00
Carles Fernandez ac6d7feeab
Fix clang-format job 2021-03-14 22:17:22 +01:00
Carles Fernandez 9e1ee33cd2
Add multiple RF output capability to LabSat 3 Wideband format 2021-03-14 20:00:18 +01:00
Carles Fernandez 32c699befc
Add LabSat 3 Wideband format to Labsat_Signal_Source 2021-03-11 22:13:23 +01:00
Carles Fernandez 7308745f05
Apply more concise file header format
Re-license CMake scripts with BSD-3-Clause
2020-12-30 13:35:06 +01:00
Carles Fernandez 499de7a9f1
Update file headers 2020-07-28 16:57:15 +02:00
Carles Fernandez c04948fd02
Reduce number of warnings raised by bugprone-* clang-tidy checks 2020-07-10 00:37:55 +02:00
Carles Fernandez 09bcd1981c Replace std::endl by \n character. There is no need to always flush the stream. 2020-07-07 18:53:50 +02:00
Carles Fernandez 81af1a531b
Redesign of pointer management
Avoid indirection caused by passing shared_ptr by reference

The block factory does not have responsability on the lifetime of their inputs

Define std::make_unique when using C++11 and make use of it

Printers are turned into unique_ptr to express ownership

Printers do not participate on the lifelime of the data, so they take const raw pointers

Modernize tests code
2020-06-18 11:49:28 +02:00
Carles Fernandez 4d0d263280
Make the software package compliant with the REUSE Specification v3.0 (see https://reuse.software/spec/)
Update license headers to SPDX format (see https://spdx.org/)
Add license to all files
Add CI job in GitHub Actions to ensure compliance
2020-02-08 01:20:02 +01:00
Carles Fernandez d4bb6e5731
Always have a space between // and comment 2019-08-18 22:16:13 +02:00
Carles Fernandez 80c4cdd1cb
Avoid usage of variable length arrays, which is a C99 feature 2019-08-14 11:58:00 +02:00
Carles Fernandez 070996cdb4
Apply clang-tidy check readability-else-after-return 2019-08-04 13:15:03 +02:00
Carles Fernandez a4d6800e22
Update copyright year
Applied on files changed since last release
clang-format applied
2019-07-26 12:38:20 +02:00
Javier Arribas 1313edd716 Partial implementation of the new event queue and its dependencies. Still NOT usable 2019-07-16 17:41:12 +02:00
Carles Fernandez d7460022ed
Avoid C arrays
See https://clang.llvm.org/extra/clang-tidy/checks/modernize-avoid-c-arrays.html
2019-07-14 14:09:12 +02:00
Carles Fernandez da5e21a5b1
Fix message typos, improve messages, clean code 2019-05-12 10:59:11 +02:00
Carles Fernandez f959428321
Improve initial mesages of Labsat source 2019-05-11 11:45:46 +02:00
Carles Fernandez e574c55ca9
Smoother transition when reading a sequence of files
From:
End of current file, reading the next Labsat file in sequence: /Users/carlesfernandez/Downloads/time/output/output_0000.LS3
Labsat file source is reading samples from /Users/carlesfernandez/Downloads/time/output/output_0001.LS3
Warning

To:
End of current file, reading the next Labsat file in sequence: /Users/carlesfernandez/Downloads/time/output/output_0001.LS3
Labsat file source is reading samples from /Users/carlesfernandez/Downloads/time/output/output_0001.LS3
2019-05-10 15:05:35 +02:00
Javier Arribas f2baf32e3f Optimizing LabSat Source 2019-05-06 12:55:32 +02:00
Carles Fernandez baeb326f84
Avoid unnecessary copy 2019-04-27 12:49:37 +02:00
Carles Fernandez 35c42c41d7
Stop the Labsat_Signal_Source when the end of file is reached. This allows to use this source for automated testing.
Now the block also accepts directly *.ls2 names in filename parameter

Remove samples parameter, it was not used. This source reads the full file(s).

Make labsat23_source constructor private, so only the smart pointer wrapper can be called
2019-04-12 12:59:57 +02:00
Carles Fernandez 73b7341904
clang-tidy: apply readability-braces-around-statements plus code formatting
See http://releases.llvm.org/7.0.0/tools/clang/tools/extra/docs/clang-tidy/checks/readability-braces-around-statements.html
Code formatting applied with:
  find ../src/ -iname *.h -o -iname *.cc | xargs clang-format -i
2019-02-11 21:13:02 +01:00
Carles Fernandez 4b2b205e21
Avoid throwing exceptions from destructors
Detected by clang-tidy check bugprone-exception-escape
2019-02-10 21:55:51 +01:00
Carles Fernandez 17260bbcea
Miscelaneous code improvements by clang-tidy 2018-12-08 18:49:31 +01:00
Carles Fernandez 327fec627c clang-tidy: apply readability-else-after-return fix (see https://clang.llvm.org/extra/clang-tidy/checks/readability-else-after-return.html) 2018-12-03 22:08:19 +01:00
Carles Fernandez 0d408a6024 clang-tidy: apply modernize-use-auto fix (see https://clang.llvm.org/extra/clang-tidy/checks/modernize-use-auto.html) 2018-12-03 16:25:11 +01:00
Carles Fernandez af8d93af1a
Remove unused variable 2018-11-24 18:41:36 +01:00
Carles Fernandez 0d60d97c24
Use https instead of http in links when available
Update copyright year in headers
2018-05-13 22:49:11 +02:00
Carles Fernandez a2eb5d5344
Improve readability, reorder includes 2018-04-29 13:26:21 +02:00
Carles Fernandez 34f24562cf Apply automated code formatting
Documented at .clang-format
See http://clang.llvm.org/docs/ClangFormat.html and http://clang.llvm.org/docs/ClangFormatStyleOptions.html
2018-03-03 02:03:39 +01:00
Carles Fernandez 24f6003ba0 Remove iostream from header files
and in redundant places such as in unit tests
2018-02-25 22:49:06 +01:00
Carles Fernandez 8386289984 Initialize all members in the constructor 2018-01-23 22:52:15 +01:00
Carles Fernandez 2a9d6975e0 Apply coding style 2018-01-23 20:07:43 +01:00
Javier Arribas 84fe651f0d Adding Labsat v2 and v3 single channel signal recorder file source 2018-01-23 17:31:42 +01:00