From 24b1096209bfb785625adb8381ca2899a728063e Mon Sep 17 00:00:00 2001 From: Ismael Gomez Date: Thu, 15 Mar 2018 18:35:40 +0100 Subject: [PATCH 1/2] Fixed bug in compute_ri() when passed NULL parameter causing segfault in MIMO --- srsue/src/phy/phch_worker.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/srsue/src/phy/phch_worker.cc b/srsue/src/phy/phch_worker.cc index e613719cb..cb27a5000 100644 --- a/srsue/src/phy/phch_worker.cc +++ b/srsue/src/phy/phch_worker.cc @@ -418,7 +418,9 @@ void phch_worker::compute_ri(uint8_t *ri, uint8_t *pmi, float *sinr) { /* If 2 ort more receiving antennas, select RI */ float cn = 0.0f; srslte_ue_dl_ri_select(&ue_dl, ri, &cn); - Debug("TM3 RI select %d layers, κ=%fdB\n", (*ri) + 1, cn); + if (ri) { + Debug("TM3 RI select %d layers, κ=%fdB\n", (*ri) + 1, cn); + } } else { /* If only one receiving antenna, force RI for 1 layer */ if (ri) { From 622b3221d73dbf9ef067eb196d924e8caacbe67e Mon Sep 17 00:00:00 2001 From: Ismael Gomez Date: Thu, 15 Mar 2018 18:37:16 +0100 Subject: [PATCH 2/2] Don't restart RX stream when setting RX srate (causes UHD corruption in MIMO) --- lib/src/radio/radio.cc | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/src/radio/radio.cc b/lib/src/radio/radio.cc index fc21b73be..7008790a3 100644 --- a/lib/src/radio/radio.cc +++ b/lib/src/radio/radio.cc @@ -301,9 +301,7 @@ void radio::set_master_clock_rate(double rate) void radio::set_rx_srate(double srate) { - srslte_rf_stop_rx_stream(&rf_device); srslte_rf_set_rx_srate(&rf_device, srate); - srslte_rf_start_rx_stream(&rf_device, false); } void radio::set_tx_freq(double freq)