summaryrefslogtreecommitdiff
path: root/gr-digital/python/digital
Commit message (Collapse)AuthorAgeFilesLines
* cmake: change how test files are build when cross compilingPhilip Balister2021-12-031-0/+3
| | | | | | | | | | | | | | | | | | | | * When cross compiling gnuradio, change how the test files are built. Normally, the gnuradio QA code expects to run in the build tree. For the cross compilng case, we cannot run the QA code during the build process. The changes here allow the creation of an additional package that can be installed on a target that will run the QA code against the installed libraries. Major changes are not using full paths to test files (since they include paths that only exist on the build machine) and not setting environment variables in the shell files to force the QA code to use code in the build tree. This patch disables the C++ only tests, these need some work and then they can be added back for the cross compile case. Signed-off-by: Philip Balister <philip@balister.org>
* digital: pep8 formattingJosh Morman2021-11-2431-434/+638
| | | | Signed-off-by: Josh Morman <jmorman@gnuradio.org>
* Revert "Replace boost::any with std::any"Josh Morman2021-11-061-1/+1
| | | | This reverts commit ccd28dfbb1504fdc29db267acd8aa3354fe10cd2.
* Replace boost::any with std::anyMarcus Müller2021-10-281-1/+1
| | | | | | | | This is a modernization possible through C++17 Fixes #4780 Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* digital: remove deprecation of pfb_clock_syncJosh Morman2021-10-142-2/+2
| | | | Signed-off-by: Josh Morman <jmorman@peratonlabs.com>
* gr-digital: Fix constellation normalization by average powerDavid Pi2021-09-071-1/+22
| | | | | | | Correct power normalization calculation. Add a qa test for amplitude and power normalization. Signed-off-by: David Pi <david.pinho@gmail.com>
* gr-digital: fix gfsk documentationSolomon Tan2021-09-021-35/+34
| | | | | | | The gfsk hier block documentation is shifted so it will be shown in the documentation tab of the block. It is otherwise not shown. Signed-off-by: Solomon Tan <solomonbstoner@yahoo.com.au>
* gr-digital: replace clk recovery MM in hier blksSolomon Tan2021-09-022-26/+50
| | | | | | | | | | | | | As Clock Recovery MM is deprecated, this commit replaces them in the hier blocks, gmfsk demod and gfsk demod, with Andy Wall's Symbol Sync block. Backward compatibility is maintained by keeping the parameters unchanged, and converting the two gain values to the corresponding loop bandwidth value that Symbol Sync requires. Even though `mu` parameter's services is no longer required, we leave it in the hier block for backward compatibility purposes. Signed-off-by: Solomon Tan <solomonbstoner@yahoo.com.au>
* gr-digital: Make unpack optional for gmsk mod hier blockSolomon Tan2021-08-231-3/+8
| | | | | | | Allow the unpack option to be disabled for custom, non-byte-aligned bit streams in gmsk mod, just like how it was done for gfsk in #4940. Signed-off-by: Solomon Tan <solomonbstoner@yahoo.com.au>
* digital/chunks to symbols: be less inefficientMarcus Müller2021-07-271-1/+1
| | | | | | | | | | | | | The block formerly took the tags from get_tags_in_range (which are sorted), gave them to tag_checker, which sorted them, and then went through every input sample, checking its index against the next tag. Removed the tag_checker; that saves us a sorting of a sorted vector. The other optimization is to not dispatch any tag encountered to the own message handler; instead, the handler is called directly. Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* digital: more details in constellation testMarcus Müller2021-07-271-1/+14
| | | | Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* digital: at least superficially test chunk_to_symbols dimensions>1Marcus Müller2021-07-271-0/+44
| | | | Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* digital: add int() cast where requiredJeff Long2021-07-271-1/+1
| | | | | | | Skiphead requires an integer number of samples, but was being called with a float parameter. Signed-off-by: Jeff Long <willcode4@gmail.com>
* gfsk: Make packed_to_unpacked optionalSolomon Tan2021-07-211-3/+11
| | | | | | | | | | | Provide the option to not use the packed_to_unpacked block in the gfsk mod hier block so that the latter can be used to modulate non-byte-aligned bit stream. The option enables packed_to_unpacked by default for backward compatibility. Signed-off-by: Solomon Tan <solomonbstoner@yahoo.com.au>
* digital: Added a crc16 basic block. (#4649)cmrincon2021-07-124-0/+76
| | | Signed-off-by: cmrincon <cmrincon611@hotmail.com>
* runtime: use < instead of compare_offset, remove Python comparison classMarcus Müller2021-06-281-2/+1
| | | | | | | Since the introduction of the comparison operator obsoletes the comparison class, remove it. Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* global: automatically remove unused boost includesMarcus Müller2021-06-221-1/+1
| | | | | | | | used command: sed -i '/^#include.*boost.*$/d' $(ag -L '(boost::|BOOST)' $(ag --cpp -l '#include <boost')) Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* digital: Clean up differential encoder QA testDaniel Estévez2021-06-121-40/+12
| | | | | | | | There was a lot of repetition in the different test cases for different modulus. This commit removes the repetition by using subtests. Signed-off-by: Daniel Estévez <daniel@destevez.net>
* digital: Add NRZI option to differential en/decoderDaniel Estévez2021-06-127-2/+134
| | | | | | | | | | | | | | | | | | | This adds an option to the differential encoder an decoder blocks to perform NRZI encoding and decoding. NRZI only makes sense with a modulus of 2, so the blocks constructors will throw and exception if passed nrzi = true and a modulus different from 2. The GRC blocks handle this by hiding the modulus field if the user selects NRZI encoding. A new unit test for the NRZI version of the blocks is added. Besides checking that encode plus decode gives the original, this test also compares the C++ implementation results against a Numpy implementation. Additionally, a faster implementation of differential encoding/ decoding for modulus 2 is included here. Signed-off-by: Daniel Estévez <daniel@destevez.net>
* digital: Gut packet_utils.pyMartin Braun2021-05-225-496/+8
| | | | | | | | | | | This module is a deprecated module and is used nowhere in GNU Radio, with the exception of a single variable (default_access_code). We keep that variable and remove all the rest. Because this module was the only consumer of crc.py, that was also removed. Signed-off-by: Martin Braun <martin.braun@ettus.com>
* digital: Remove crc32 utilityMartin Braun2021-05-226-155/+19
| | | | | | | | | | This patch removes a crc32 utility that used to be used in our CRC32 blocks, but no longer is. Right now, all this does is expose a generic CRC32 function to the user (both via Python and C++), but there are enough other libraries that let the user do that. Therefore, we'll remove this. Signed-off-by: Martin Braun <martin@gnuradio.org>
* digital: fix qa for equalizersJosh Morman2021-04-214-105/+59
| | | | Signed-off-by: Josh Morman <jmorman@perspectalabs.com>
* digital: remove simple_{correlator,framer}Josh Morman2021-04-219-334/+0
| | | | Signed-off-by: Josh Morman <jmorman@perspectalabs.com>
* digital: remove deprecated equalizersJosh Morman2021-04-218-338/+0
| | | | Signed-off-by: Josh Morman <jmorman@perspectalabs.com>
* digital: Fix documentation for corr_est 'threshold' paramterIpsit2021-03-101-2/+2
| | | | | Signed-off-by: Ipsit <mmkipsit@gmail.com> Signed-off-by: Martin Braun <martin@gnuradio.org>
* digital: qa: Add preconditions to wait for qa_packet_headerparser_bMartin Braun2021-03-031-10/+6
| | | | | | | This is an attempt to avoid QA failures due to messages not being delivered before wait() concludes. Signed-off-by: Martin Braun <martin@gnuradio.org>
* digital: include control_loop class in child class bindingsJeppe Ledet-Pedersen2021-02-154-0/+4
| | | | | | | | costas_loop_cc, fll_band_edge_cc, and constellation_receiver_cb all inherit from gr::blocks::control_loop. Add the class to the bindings so the control loop methods are available in Python. Signed-off-by: Jeppe Ledet-Pedersen <jlp@satlab.com>
* gr-digital: qa_header_payload_demux fixJeff Long2021-02-151-4/+8
| | | | | | | | | | The HeaderToMessageBlock adapter assumed it would receive a complete header in work(). Also, forecast() is not currently working for Python blocks, so a local buffer was required in the adapter. Two asserts needed list(). Signed-off-by: Jeff Long <willcode4@gmail.com>
* gr-digital: improved performance and capability of scramblers to 64-bit ↵Elof Wecksell2021-01-2913-24/+138
| | | | | | | registers. Use __builtin_parity or volk popcnt. qa was also enhanced to detect errors. Signed-off-by: Elof Wecksell <elof@wecksell.se> Co-authored-by: Martin Braun <martin@gnuradio.org>
* digital: change ofdm_chanest qa test to have noise vectorJosh Morman2021-01-201-4/+2
| | | | Signed-off-by: Josh Morman <jmorman@perspectalabs.com>
* clang-tidy: run full .clang-tidy on C++17 codebaseMarcus Müller2021-01-193-3/+3
| | | | | | | | | | | | | | | | | | | | run /usr/share/clang/run-clang-tidy.py -checks=file '-header-filter=.*' -fix .. from build directory. Then, clang-format -i $(git diff --name-only origin/master) to clang-format changed files. Then, refresh all header hashes in pybind bindings (*/python/bindings/*.cc) Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* digital: fix bindings and yaml for constellationJosh Morman2021-01-081-59/+11
| | | | Signed-off-by: Josh Morman <jmorman@perspectalabs.com>
* digital: ofdm: Fix whitespace in OFDM chanest blockMartin Braun2020-12-192-35/+17
| | | | | | | | Both the C++ and Python files have really weird whitespace issues, making them hard to read. This makes the whitespace usage for consistent with usual formatting, and fixes some Doxygen issues. Signed-off-by: Martin Braun <martin@gnuradio.org>
* gr-digital: Document normalization parameter in constellation.hRon Economos2020-12-181-1/+1
| | | | Signed-off-by: Ron Economos <w6rz@comcast.net>
* Allow to choose whether to normalize constellation average magnitude, ↵Eduardo Sánchez Muñoz2020-12-181-5/+12
| | | | | | average power or to not normalize at all. Signed-off-by: Eduardo Sánchez Muñoz <esm@eduardosm.net>
* digital: update pybind hashes for mpsk_snr_estJosh Morman2020-12-182-2/+2
|
* digital: deprecate clock recovery blocks covered by symbol_syncJosh Morman2020-12-175-5/+5
| | | | | | | The pfb, msk and mm clock recovery blocks are all covered by the symbol_sync block. See https://www.youtube.com/watch?v=uMEfx_l5Oxk Signed-off-by: Josh Morman <jmorman@perspectalabs.com>
* digital: add constellation_encoder blockJosh Morman2020-11-166-1/+153
|
* modernization: `override` instead of virtual in all compilation unitsMarcus Müller2020-11-0313-13/+13
|
* Remove unused gru importsClayton Smith2020-11-021-1/+0
| | | | | Neither of these files use the gru module anymore. I've tested that they work correctly after removing the unused imports.
* digital: remove obsolete digital voice blocksClayton Smith2020-11-021-90/+0
| | | | | | | As far as I can tell, the last reference to these classes was removed in 2c1ac6a86dada1a16fa4d112781678c595af46b2 back in 2011. They are non-functional, since they haven't kept up with API changes like the transition to hier_block2.
* qa: fix typomormj2020-10-301-2/+2
|
* qa: run autopep8 formatting on qa python filesmormj2020-10-3050-1254/+2229
| | | | | | find ./ -iname qa*.py | xargs autopep8 --in-place -a -a mostly formats whitespace and gets rid of trailing semicolons
* qa: remove xml file parameter causing deprecation warningsmormj2020-10-3042-42/+41
|
* Remove hexint and hexshort from gru moduleClayton Smith2020-10-301-1/+1
|
* Fix typos throughout the codeluzpaz2020-10-294-7/+7
| | | | | | | * Fix various typos Found via `codespell v2.0.dev` `codespell -q 3 -L ans,fo,hist,inout,ist,ith,nd,sinc,uint -S ./volk`
* Remove gcd, lcm, and log2 from gru moduleClayton Smith2020-10-291-2/+2
|
* pybind: add implicit conversion from int to enummormj2020-10-287-0/+14
| | | | | | | | | | | | | * dtv: add implicit conversion from int to enum * analog: add implicit conversion from int to enum * blocks: add implicit conversion from int to enum * digital: add implicit conversion from int to enum * fec: add implicit conversion from int to enum * fft: add implicit conversion from int to enum * filter: add implicit conversion from int to enum * qtgui: add implicit conversion from int to enum * trellis: add implicit conversion from int to enum * vocoder: add implicit conversion from int to enum * bindtool: add implicitly_convertible to all enums
* digital: ofdm_equalizer_simpledfe: add enable_soft_output optionjapm482020-10-282-4/+36
| | | | | | | | | Enable outputting equalized symbols that are not exactly constellation symbols. This is useful for OFDM soft decoding/demodulation (e.g. optimal turbo or LDPC decoding). For compatibility, this new behaviour has to be enabled by setting the new option "enable_soft_output" to true (false by default).
* Merge pull request #3809 from argilo/digital-remove-sixmormj2020-10-202-24/+21
|\ | | | | digital: remove six