aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/usrp/multi_usrp.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'host/lib/usrp/multi_usrp.cpp')
-rw-r--r--host/lib/usrp/multi_usrp.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/host/lib/usrp/multi_usrp.cpp b/host/lib/usrp/multi_usrp.cpp
index 5130d3ae8..2e38a9ff8 100644
--- a/host/lib/usrp/multi_usrp.cpp
+++ b/host/lib/usrp/multi_usrp.cpp
@@ -193,7 +193,7 @@ public:
_rx_dsp(chan)[DSP_PROP_STREAM_CMD] = stream_cmd;
return;
}
- for (size_t c = 0; m < get_rx_num_channels(); m++){
+ for (size_t c = 0; c < get_rx_num_channels(); c++){
issue_stream_cmd(stream_cmd, c);
}
}
@@ -245,13 +245,13 @@ public:
return _rx_subdev(chan)[SUBDEV_PROP_NAME].as<std::string>();
}
- void set_rx_rate(double rate){
+ void set_rx_rate(double rate, size_t chan){
if (chan != ALL_CHANS){
_rx_dsp(chan)[DSP_PROP_HOST_RATE] = rate;
do_samp_rate_warning_message(rate, get_rx_rate(chan), "RX");
return;
}
- for (size_t c = 0; m < get_rx_num_channels(); m++){
+ for (size_t c = 0; c < get_rx_num_channels(); c++){
set_rx_rate(rate, c);
}
}
@@ -261,13 +261,13 @@ public:
}
tune_result_t set_rx_freq(const tune_request_t &tune_request, size_t chan){
- tune_result_t r = tune_rx_subdev_and_dsp(_rx_subdev(chan), _rx_dsp(chan), chan%rx_cpm(), tune_request);
+ tune_result_t r = tune_rx_subdev_and_dsp(_rx_subdev(chan), _rx_dsp(chan), tune_request);
do_tune_freq_warning_message(tune_request.target_freq, get_rx_freq(chan), "RX");
return r;
}
double get_rx_freq(size_t chan){
- return derive_freq_from_rx_subdev_and_dsp(_rx_subdev(chan), _rx_dsp(chan), chan%rx_cpm());
+ return derive_freq_from_rx_subdev_and_dsp(_rx_subdev(chan), _rx_dsp(chan));
}
freq_range_t get_rx_freq_range(size_t chan){
@@ -347,13 +347,13 @@ public:
return tx_cpm()*get_num_mboards(); //total num channels
}
- void set_tx_rate(double rate){
+ void set_tx_rate(double rate, size_t chan){
if (chan != ALL_CHANS){
_tx_dsp(chan)[DSP_PROP_HOST_RATE] = rate;
do_samp_rate_warning_message(rate, get_tx_rate(chan), "TX");
return;
}
- for (size_t c = 0; m < get_tx_num_channels(); m++){
+ for (size_t c = 0; c < get_tx_num_channels(); c++){
set_tx_rate(rate, c);
}
}
@@ -363,13 +363,13 @@ public:
}
tune_result_t set_tx_freq(const tune_request_t &tune_request, size_t chan){
- tune_result_t r = tune_tx_subdev_and_dsp(_tx_subdev(chan), _tx_dsp(chan), chan%tx_cpm(), tune_request);
+ tune_result_t r = tune_tx_subdev_and_dsp(_tx_subdev(chan), _tx_dsp(chan), tune_request);
do_tune_freq_warning_message(tune_request.target_freq, get_tx_freq(chan), "TX");
return r;
}
double get_tx_freq(size_t chan){
- return derive_freq_from_tx_subdev_and_dsp(_tx_subdev(chan), _tx_dsp(chan), chan%tx_cpm());
+ return derive_freq_from_tx_subdev_and_dsp(_tx_subdev(chan), _tx_dsp(chan));
}
freq_range_t get_tx_freq_range(size_t chan){
@@ -453,11 +453,11 @@ private:
}
wax::obj _rx_dsp(size_t chan){
prop_names_t dsp_names = _mboard(chan/rx_cpm())[MBOARD_PROP_RX_DSP_NAMES].as<prop_names_t>();
- return _mboard(chan/rx_cpm())[named_prop_t(MBOARD_PROP_RX_DSP, dsp_names.at(chan%rx_cpm())];
+ return _mboard(chan/rx_cpm())[named_prop_t(MBOARD_PROP_RX_DSP, dsp_names.at(chan%rx_cpm()))];
}
wax::obj _tx_dsp(size_t chan){
prop_names_t dsp_names = _mboard(chan/tx_cpm())[MBOARD_PROP_TX_DSP_NAMES].as<prop_names_t>();
- return _mboard(chan/tx_cpm())[named_prop_t(MBOARD_PROP_TX_DSP, dsp_names.at(chan%tx_cpm())];
+ return _mboard(chan/tx_cpm())[named_prop_t(MBOARD_PROP_TX_DSP, dsp_names.at(chan%tx_cpm()))];
}
wax::obj _rx_dboard(size_t chan){
std::string db_name = get_rx_subdev_spec(chan/rx_cpm()).at(chan%rx_cpm()).db_name;