summaryrefslogtreecommitdiff
path: root/gr-network/lib
Commit message (Collapse)AuthorAgeFilesLines
* network: fix segfaults when TCP & UDP blocks are restartedClayton Smith2021-12-076-26/+42
| | | | | | | | | The TCP and UDP blocks segfault if start() is called after stop(), because stop() frees resources that are not re-allocated by start(). To fix this, I've moved resource allocation for these blocks from the constructor to start(). Signed-off-by: Clayton Smith <argilo@gmail.com>
* logging core: replace log4cpp by spdlogMarcus Müller2021-11-191-1/+7
| | | | | | | | also: enable formerly disabled qa_logger tests This replaces log4cpp with spdlog. Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* gr-network: Fixup tuntap suppress warning on Debian 11.Ron Economos2021-09-121-10/+12
| | | | Signed-off-by: Ron Economos <w6rz@comcast.net>
* network: tuntap knows what it's doing when it uses strncpy, suppress warningMarcus Müller2021-09-071-3/+14
| | | | Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* IWYU: iomanip, iostream, sstreamMarcus Müller2021-09-071-0/+1
| | | | Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* network: include boost/format where usedMarcus Müller2021-09-072-0/+2
| | | | Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* network: use common precompiled headersMarcus Müller2021-07-191-0/+5
| | | | Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* network: use logging in tuntap_pdu instead of coutMarcus Müller2021-06-171-3/+3
| | | | Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* network: use logging in socket_pdu instead of coutMarcus Müller2021-06-171-2/+3
| | | | Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* runtime, blocks, network: Clean up use of Win headers, fix stream_pdu.Ryan Volz2021-04-171-2/+15
| | | | | | | stream_pdu_base was failing to compile on Windows after moving to gr-network since HAVE_IO_H was not checked for or defined. Signed-off-by: Ryan Volz <ryan.volz@gmail.com>
* gr-network: Clean up lib/CMakeLists.txt.Ron Economos2021-03-251-45/+16
| | | | Signed-off-by: Ron Economos <w6rz@comcast.net>
* network: replace ::bind with lambdaMarcus Müller2021-03-203-4/+3
| | | | Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* gr-pdu: move pdu blocks to gr::pduJacob Gilbert2021-03-189-0/+873
| | | | | | | | | | | | | | | | | | | | | 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>
* clang-tidy: run full .clang-tidy on C++17 codebaseMarcus Müller2021-01-191-2/+2
| | | | | | | | | | | | | | | | | | | | 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>
* modernization: `override` instead of virtual in all compilation unitsMarcus Müller2020-11-033-6/+6
|
* Add `override` for common virtual function overridesThomas Habets2020-11-033-3/+3
| | | | | | | | | | Mostly done with: ``` find -name "*_impl.h" | xargs sed -i -r '/(void forecast|int work|int general_work|bool check_topology)\(/{:back /\)/b nxt;N;b back;:nxt s/\)$|\)(;)/) override\1/g}' ``` Then I removed an incorrect `work` that this found.
* network: lib: Rename s_host variable so MSVC doesn't barf.Ryan Volz2020-10-201-3/+3
| | | | | I don't know why, but MSVC fails with the variable name as "s_host", so make it "str_host" instead.
* network: lib: Use std functions for sleep instead of usleep.Ryan Volz2020-10-201-2/+4
| | | | This fixes compilation with MSVC.
* network: build fixesNicholas Corgan2020-08-242-0/+57
| | | | | * Add missing Windows resource file * Include in component list in GnuradioConfig.cmake
* Replace all calls to `get_initial_sptr` with `make_block_sptr`Thomas Habets2020-07-303-12/+12
| | | | | | | | | | | | | | 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
* gr-network: Remove dead code.Ron Economos2020-04-082-26/+0
|
* gr-network: Add grnet networking blocks to GNU Radioghostop142020-03-297-0/+1252
This PR is to create a new gr-network structure that includes the grnet TCP and UDP source/sink blocks for inclusion into GNU Radio. This includes new modes (TCP source/sink can act as either a TCP server/listener or a client), and UDP supports multiple new header options for dropped packet detection and integration with external sources such as the Allen Telescope Array. The UDP blocks have a number of important performance and tuning comments in the block documentation to help ensure success with the blocks, and examples for each scenario are included. This PR also deprecates the old TCP/UDP blocks but keeps them in place. The new blocks and new functionality resulted in not a 1:1 drop-in replacement for the old blocks so the old blocks were moved to the deprecated UI group to avoid breaking flowgraphs going to GR 3.9. Some of the new features included in these blocks are: 1. The only TCP block is a sink that listens for inbound connections. This inherently limits the ability to transmit data to another 3rd party application listening for data in TCP server mode. A source block is included here as well. 2. The TCP sink block supports both TCP client and server modes. 3. All blocks (TCP and UDP) support IPv6. 4. UDP blocks now include a variety of header options: None, a 64-bit sequence number that can be used to track dropped packets, CHDR, and the Allen Telescope Array header format for GR-native ATA integration. 5. UDP blocks paired with headers can now notify if any data is lost in transit. 6. UDP blocks now have the option to source 0's (no signal) to allow the flowgraph to run if no incoming data is available. 7. UDP blocks now include a buffering mechanism to ensure data is not lost between different timing domains (network packets and GNU Radio scheduler). 8. Block documentation has been added to help guide users through how to properly configure addresses for IPv6 or dual-stack operations, and tuning / testing before using UDP blocks in a production environment. 9. TCP sink has enhanced work logic to remain running and continue to listen for reconnections if a client disconnects.