aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib
diff options
context:
space:
mode:
authorMartin Braun <martin.braun@ettus.com>2016-12-13 17:55:37 -0800
committerMartin Braun <martin.braun@ettus.com>2016-12-13 17:55:37 -0800
commita0c5ed6a8ec43536a1dfd3935d07e29d4f0df92b (patch)
tree8f6b1be63e5265bf5b09bc9f4e8f52c1050c170d /host/lib
parentb0f01fd4dd9b2072b6e84137225ab52d2e13d8ca (diff)
parent2a72dd9094bea085995ba7c49d2e102403bdbc42 (diff)
downloaduhd-a0c5ed6a8ec43536a1dfd3935d07e29d4f0df92b.tar.gz
uhd-a0c5ed6a8ec43536a1dfd3935d07e29d4f0df92b.tar.bz2
uhd-a0c5ed6a8ec43536a1dfd3935d07e29d4f0df92b.zip
Merge branch 'maint'
Diffstat (limited to 'host/lib')
-rw-r--r--host/lib/rfnoc/ddc_block_ctrl_impl.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/host/lib/rfnoc/ddc_block_ctrl_impl.cpp b/host/lib/rfnoc/ddc_block_ctrl_impl.cpp
index 2aac22ca4..fb70b6f45 100644
--- a/host/lib/rfnoc/ddc_block_ctrl_impl.cpp
+++ b/host/lib/rfnoc/ddc_block_ctrl_impl.cpp
@@ -121,7 +121,15 @@ public:
double get_output_samp_rate(size_t port=ANY_PORT)
{
- port = port == ANY_PORT ? 0 : port;
+ if (port == ANY_PORT) {
+ port = 0;
+ for (size_t i = 0; i < get_input_ports().size(); i++) {
+ if (_rx_streamer_active.count(i) and _rx_streamer_active.at(i)) {
+ port = i;
+ break;
+ }
+ }
+ }
if (not (_rx_streamer_active.count(port) and _rx_streamer_active.at(port))) {
return RATE_UNDEFINED;
}