diff options
author | Johnathan Corgan <johnathan@corganlabs.com> | 2017-10-05 16:39:09 -0700 |
---|---|---|
committer | Johnathan Corgan <johnathan@corganlabs.com> | 2017-10-05 16:39:09 -0700 |
commit | 6fa9d33246251f44a0e78682e50e9a1cb0b03171 (patch) | |
tree | 513fed9b2dfb49f9c3fbb2a7a98526d27927c166 /gr-uhd/include/gnuradio/uhd/usrp_source.h | |
parent | 07a0ca6c3664669f85faeee00fa69d2af3a7b59f (diff) | |
parent | 3c63f7334d6de70d655aa97fcccbfb950645f4d4 (diff) |
Merge branch 'next' into python3
Diffstat (limited to 'gr-uhd/include/gnuradio/uhd/usrp_source.h')
-rw-r--r-- | gr-uhd/include/gnuradio/uhd/usrp_source.h | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/gr-uhd/include/gnuradio/uhd/usrp_source.h b/gr-uhd/include/gnuradio/uhd/usrp_source.h index 552c518f1c..60413e35d4 100644 --- a/gr-uhd/include/gnuradio/uhd/usrp_source.h +++ b/gr-uhd/include/gnuradio/uhd/usrp_source.h @@ -98,6 +98,33 @@ namespace gr { */ virtual void issue_stream_cmd(const ::uhd::stream_cmd_t &cmd) = 0; + /*! Configure the timeout value on the UHD recv() call + * + * This is an advanced use parameter. Changing the timeout value affects + * the latency of this block; a high timeout value can be more optimal + * for high-throughput applications (e.g., 1 second) and setting it to + * zero will have the best latency. Changing the timeout value may also + * be useful for custom FPGA modifications, where traffic might not be + * continuously streaming. + * For specialized high-performance use cases, twiddling these knobs may + * improve performance, but changes are not generally applicable. + * + * Note that UHD's recv() call may block until the timeout is over, which + * means this block might also block for up to the timeout value. + * + * \param timeout Timeout parameter in seconds. Cf. the UHD manual for + * uhd::rx_streamer::recv() for more details. A lower + * value will mean lower latency, but higher CPU load. + * \param one_packet If true, only receive one packet at a time. Cf. the + * UHD manual for uhd::rx_streamer::recv() for more + * details. A value of true will mean lower latency, + * but higher CPU load. + */ + virtual void set_recv_timeout( + const double timeout, + const bool one_packet=true + ) = 0; + /*! * Returns identifying information about this USRP's configuration. * Returns motherboard ID, name, and serial. |