summaryrefslogtreecommitdiff
path: root/gnuradio-runtime/python/gnuradio
Commit message (Collapse)AuthorAgeFilesLines
...
* thrift: replace ::bind with lambdaMarcus Müller2021-03-201-1/+1
| | | | Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* runtime: add int_t and short_t PDU typesJacob Gilbert2021-03-181-3/+5
| | | | | | | These are not used yet but are valid PDUs and should be included here so as not to imply PDUs can have only byte/float/complex type uvec's Signed-off-by: Jacob Gilbert <jacob.gilbert@protonmail.com>
* gr-blocks: remove pdu blocksJacob Gilbert2021-03-181-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | The following have been moved to the new gr::pdu module or to gr::network and are no longer needed in gr::blocks: - pdu (noblock) - pdu_filter block - pdu_remove block - pdu_set block - pdu_to_tagged_stream block - random_pdu block - socket_pdu block - stream_pdu_base (noblock) - tagged_stream_to_pdu block - tcp_connection (noblock) - tuntap_pdu block The digital and FEC modules had a large number of references to the PDU blocks that were moved from gr-blocks to gr-pdu, this updates these changes in example flowgraphs and a few python files. The usage-manual update will be propagated to the wiki so that future exports will remain up to date. Signed-off-by: Jacob Gilbert <jacob.gilbert@protonmail.com>
* gr-pdu: move pdu blocks to gr::pduJacob Gilbert2021-03-185-1/+150
| | | | | | | | | | | | | | | | | | | | | Moving the following from gr::blocks into gr-pdu: - pdu_filter block - pdu_remove block - pdu_set block - pdu_to_tagged_stream block - random_pdu block - tagged_stream_to_pdu block Moving the following from gr::blocks into gr-network: - socket_pdu block - stream_pdu_base (noblock) - tcp_connection (noblock) - tuntap_pdu block Moving the following from gr::blocks into gr: - pdu (noblock, general PDU functions) Signed-off-by: Jacob Gilbert <jacob.gilbert@protonmail.com>
* gr-pdu: initial commit with the PDU moduleJacob Gilbert2021-03-181-0/+1
| | | | | | | There is only one simple block in here for now, and there are probably some doxygen issues but it builds and tests properly. Signed-off-by: Jacob Gilbert <jacob.gilbert@protonmail.com>
* Replace boost::filesystem with std::filesystemZackery Spytz2021-03-131-1/+1
| | | | Signed-off-by: Zackery Spytz <zspytz@gmail.com>
* runtime: clean up realtime impl namespaceJosh Morman2021-03-084-89/+11
| | | | Signed-off-by: Josh Morman <jmorman@perspectalabs.com>
* runtime: gr_unittest: Add waitFor() API callMartin Braun2021-03-031-0/+41
| | | | | | | This is a helper for adding conditional waits into test cases. Useful for tests with a non-deterministic execution time. Signed-off-by: Martin Braun <martin.braun@ettus.com>
* pybind: remove forecast from python bindingsJosh Morman2021-02-185-35/+0
| | | | | | | | There is no scenario that a block or app should be calling forecast over the python interface. This is only called by the scheduler, and for python blocks would pass through the gateway interface. Signed-off-by: Josh Morman <jmorman@perspectalabs.com>
* python: add the dll runtime path in __init__.pyJosh Blum2021-01-271-0/+13
| | | | | | | | | | | python3.8 and up need to have the dll search path set explicitly before importing. More details can be found here: https://docs.python.org/3/whatsnew/3.8.html#bpo-36085-whatsnew Without the fix, python libraries will fail to import regardless of how PATH is configured. The solution searches for the runtime path for gnuradio dlls and calls add_dll_directory() before imports. As a precedent, a similar behaviour is implemented in the gi/__init__.py module used with pygtk. Signed-off-by: Josh Blum <josh@joshknows.com>
* clang-tidy: run full .clang-tidy on C++17 codebaseMarcus Müller2021-01-195-5/+5
| | | | | | | | | | | | | | | | | | | | 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>
* runtime: simplify math fxpt sine/cosine calculationArtem Pisarenko2021-01-171-1/+1
| | | | | | | | | Algorithm improved in order to eliminate getting output values outside of range [-1.0, 1.0) Fixes #2993 Signed-off-by: Artem Pisarenko <artem.k.pisarenko@gmail.com>
* runtime: added missing algorithm headerJosh Blum2021-01-111-1/+1
| | | | | | tag_checker.h uses std::sort Signed-off-by: Josh Blum <josh@joshknows.com>
* runtime: Add terminate handlingPaul Wicks2020-12-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | This consists of the following changes: 1. Add a top_block parameter to control exception handling This restores past behavior where the scheduler catches exceptions raised in block threads, allowing flowgraphs to continue running after the failure of an individual block. It also adds optional new behavior, selected by setting catch_exceptions=False to the top block, which causes exceptions to not be caught. In this mode of operation, a std::terminate handler can be installed to print a stack trace before the flowgraph exits. 2. Add terminate_handler to top_block_impl This adds a terminate_handler function that prints information about any uncaught exceptions and also attempts to print a backtrace for said exception after which it calls std::abort. The backtrace is printed via libunwind, which is a new optional dependency. If libunwind is not found/installed, then the terminate handler will still print information about the exception and then exit. Co-Authored-By: Scott Torborg <storborg@gmail.com>
* add import fft to python files that reference fft.windowJosh Morman2020-12-181-1/+1
| | | | Signed-off-by: Josh Morman <jmorman@perspectalabs.com>
* global replace of filter.firdes.WIN_ with fft.window.WIN_Josh Morman2020-12-181-2/+2
| | | | Signed-off-by: Josh Morman <jmorman@perspectalabs.com>
* runtime: abolish the gru python moduleMarcus Müller2020-12-174-46/+0
| | | | Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* move msgq_runner out of runtime into gr-uhd/apps, its single consumerMarcus Müller2020-12-173-72/+0
| | | | Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* modernization: `override` instead of virtual in all compilation unitsMarcus Müller2020-11-0314-14/+14
|
* qa: run autopep8 formatting on qa python filesmormj2020-10-306-31/+45
| | | | | | 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-306-6/+6
|
* Remove gru.daemonize and dial_tone_daemon exampleClayton Smith2020-10-303-94/+0
| | | | | | | These were added in GNU Radio 3.1.3, but a Google search finds no mention of gru.daemonize outside of the changelog. Modern Python programs could use the python-daemon library, which implements the daemon specification of PEP 3143.
* Remove freqz and gnuplot_freqz from gru moduleClayton Smith2020-10-304-426/+0
|
* Remove hexint and hexshort from gru moduleClayton Smith2020-10-303-34/+0
|
* Fix typos throughout the codeluzpaz2020-10-292-4/+4
| | | | | | | * 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-293-23/+0
|
* gru: remove unused filesClayton Smith2020-10-206-164/+0
|
* audio: fix lcm calculationClayton Smith2020-10-201-1/+1
|
* runtime: remove six (#3808)mormj2020-10-201-4/+1
|\
| * runtime: remove sixClayton Smith2020-10-051-4/+1
| |
* | pybind11: Remove SWIG remnants.Ron Economos2020-10-122-3/+1
|/
* runtime: add alias for io_signature{v,3,2}Josh Morman2020-08-141-0/+4
|
* python: Remove unnecessary 'from __future__ import'Oleksandr Kravchuk2020-08-0333-54/+0
| | | | | | | | | | | | | | | | All of the removed `from __future__ import` were needed in older versions of Python (mostly 2.5.x and below) but later became mandatory in most versions of Python 3 hence are not necessary anymore. More specifically, according to __future__.py[1]: - unicode_literals is part of Python since versions 2.6.0 and 3.0.0; - print_function is part of Python since versions 2.6.0 and 3.0.0; - absolute_import is part of Python since versions 2.5.0 and 3.0.0; - division is part of Python since versions 2.2.0 and 3.0.0; Get rid of those unnecessary imports to slightly clean up the codebase. [1] https://github.com/python/cpython/blob/master/Lib/__future__.py
* Replace all calls to `get_initial_sptr` with `make_block_sptr`Thomas Habets2020-07-303-3/+3
| | | | | | | | | | | | | | First batch of changes: ``` find […] -print0 | xargs -0 sed -i -r '/get_initial_sptr/{:nxt N;/;/!b nxt;s/get_initial_sptr\(\s*new ([^(]+)(.*)\)\)/make_block_sptr<\1>\2)/}' ``` Then: * Back out `sptr_magic.h` edits * Change some `friend` clauses * clang-format the whole thing * Update checksums in the pybind11 bindings files
* pybind: include and enable realtime_impl wrappingMarcus Müller2020-06-222-3/+3
| | | | | This solves the issue of gr.enable_realtime_scheduling() failing because rt_status_t wasn't wrapped without.
* utils: move python search path in build dir upJosh Morman2020-06-041-1/+1
|
* pybind: update hash for basic_block.hJosh Morman2020-06-041-1/+1
|
* pybind: add hash check to binding file creation (#3472)mormj2020-06-0445-46/+398
|
* runtime: replace py gateway with pybind11 support, remove fevalJosh Morman2020-06-041-99/+0
|
* runtime: disable prefs from python bindingsJosh Morman2020-06-041-2/+2
|
* runtime: add pybind11 bindingsJosh Morman2020-06-04106-212/+7342
|
* Update license header to SPDX formatdevnulling2020-01-2741-530/+41
|
* Exception Handling QA: increase wait time to ensure error could've occuredMarcus Müller2020-01-061-2/+2
| | | | | Prior to this, the unit test was flaky, especially when running the test suite concurrently, as test setup could take more than 0.5 s.
* runtime: add GR_PREFS_PATH env variable searchJosh Morman2020-01-061-0/+40
| | | | | | | When looking for the config file, allow the env variable GR_PREFS_PATH to be searched so that multiple installations of GR each with its own prefs can be used, similar to what is currently done in GRC
* Add a top_block parameter to control exception handlingScott Torborg2020-01-052-23/+35
| | | | | | | | | This restores past behavior where the scheduler catches exceptions raised in block threads, allowing flowgraphs to continue running after the failure of an individual block. It also adds optional new behavior, selected by setting catch_exceptions=False to the top block, which causes exceptions to not be caught. In this mode of operation, a std::terminate handler can be installed to print a stack trace before the flowgraph exits.
* Remove catch statements from thread_body_wrapper.hPaul Wicks2020-01-051-0/+83
| | | | | | | | | | This commit removes the catch statements from thread_body_wrapper.h. The reason to do this is that, as-is, a single block in a flowgraph may throw an exception and stop functioning, but the only indication of this to the user is printing the exception's what() to stderr. With this patch, any uncaught exception will call std::terminate, which should still print the exception's what(), but will also terminate the process, rather than leaving a zombie flowgraph.
* runtime: fix gr_unittest floatAlmostEqualNicolas Cuervo2020-01-021-8/+8
| | | | | | The call inside this assert was using a generator inside the standard all(), which was always returning `False`, and silently passing the test, instead of actually asserting in fail. Changing to list comprehension for assertion raising
* Fix for misc. documentation + trivial typosluz.paz2019-07-173-4/+4
| | | | | | | | | | | | | Found via `codespell -q 3 -L ans,sinc,hist,ist,ith,uint,fo -S ./volk` Fix typos in gnuradio-runtime/ Fix typos in gr-digital/ Fix typos in gr-qtgui/ Fix typos in gr-channels/ Fix typos in grc/ Fix typos gr-filter/ Fix typos in gr-uhd/ Fix typos in gr-blocks/ Fix typos in gr-fec/
* Purge gr-comedi and all references to it from mainline GNU RadioMarcus Müller2019-07-171-1/+0
| | | | | This includes the gr-comedi/ subdirectory, the build infrastructure and CMake modules referencing Comedi, and the documentation.
* ctrlport monitors: fix config checkBastian Bloessl2019-06-193-16/+11
|