From 8a060558894fa41f25cdc3b5cef13a3a5226e437 Mon Sep 17 00:00:00 2001 From: Ismael Gomez Date: Wed, 11 May 2016 21:17:26 +0100 Subject: [PATCH] Fixed srslte_static link with volk when disableMEX. Calibrated PSS-based noise estimation --- matlab/tests/equalizer_test.m | 2 +- srslte/lib/CMakeLists.txt | 4 +++- srslte/lib/ch_estimation/chest_dl.c | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/matlab/tests/equalizer_test.m b/matlab/tests/equalizer_test.m index fc6b18c66..a8fa65edc 100644 --- a/matlab/tests/equalizer_test.m +++ b/matlab/tests/equalizer_test.m @@ -12,7 +12,7 @@ Nrealizations=10; w1=0.1; w2=0.3; -enb.NDLRB = 50; % Number of resource blocks +enb.NDLRB = 25; % Number of resource blocks enb.CellRefP = 1; % One transmit antenna port enb.NCellID = 0; % Cell ID diff --git a/srslte/lib/CMakeLists.txt b/srslte/lib/CMakeLists.txt index 0621232ee..4e0990563 100644 --- a/srslte/lib/CMakeLists.txt +++ b/srslte/lib/CMakeLists.txt @@ -92,7 +92,9 @@ endif(RF_FOUND) if(VOLK_FOUND) target_link_libraries(srslte ${VOLK_LIBRARIES}) - target_link_libraries(srslte_static ${VOLK_LIBRARIES}) + if(NOT DisableMEX) + target_link_libraries(srslte_static ${VOLK_LIBRARIES}) + endif(NOT DisableMEX) endif(VOLK_FOUND) INSTALL(TARGETS srslte DESTINATION ${LIBRARY_DIR}) diff --git a/srslte/lib/ch_estimation/chest_dl.c b/srslte/lib/ch_estimation/chest_dl.c index 05b15f841..e5963aac7 100644 --- a/srslte/lib/ch_estimation/chest_dl.c +++ b/srslte/lib/ch_estimation/chest_dl.c @@ -205,7 +205,7 @@ static float estimate_noise_pss(srslte_chest_dl_t *q, cf_t *input, cf_t *ce) srslte_vec_sub_ccc(q->tmp_pss_noisy, q->tmp_pss, q->tmp_pss_noisy, SRSLTE_PSS_LEN); /* Compute average power */ - float power = q->cell.nof_ports*srslte_vec_avg_power_cf(q->tmp_pss_noisy, SRSLTE_PSS_LEN); + float power = q->cell.nof_ports*srslte_vec_avg_power_cf(q->tmp_pss_noisy, SRSLTE_PSS_LEN)/sqrt(2); return power; }