summaryrefslogtreecommitdiff
path: root/gr-network/lib/udp_source_impl.cc
Commit message (Collapse)AuthorAgeFilesLines
* network: fix segfaults when TCP & UDP blocks are restartedClayton Smith2021-12-071-9/+15
| | | | | | | | | 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>
* IWYU: iomanip, iostream, sstreamMarcus Müller2021-09-071-0/+1
| | | | Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
* 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>
* Replace all calls to `get_initial_sptr` with `make_block_sptr`Thomas Habets2020-07-301-8/+8
| | | | | | | | | | | | | | 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: Add grnet networking blocks to GNU Radioghostop142020-03-291-0/+375
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.