RSRP computed from recv signal

master
Ismael Gomez 9 years ago
parent bcc80bc6c0
commit a2e1ecebdb

@ -309,7 +309,7 @@ int srslte_chest_dl_estimate_port(srslte_chest_dl_t *q, cf_t *input, cf_t *ce, u
} }
/* Compute RSRP for the channel estimates in this port */ /* Compute RSRP for the channel estimates in this port */
q->rsrp[port_id] = srslte_vec_avg_power_cf(q->pilot_estimates, SRSLTE_REFSIGNAL_NUM_SF(q->cell.nof_prb, port_id)); q->rsrp[port_id] = srslte_vec_avg_power_cf(q->pilot_recv_signal, SRSLTE_REFSIGNAL_NUM_SF(q->cell.nof_prb, port_id));
if (port_id == 0) { if (port_id == 0) {
/* compute rssi only for port 0 */ /* compute rssi only for port 0 */
q->rssi[port_id] = srslte_chest_dl_rssi(q, input, port_id); q->rssi[port_id] = srslte_chest_dl_rssi(q, input, port_id);
@ -333,7 +333,7 @@ float srslte_chest_dl_get_noise_estimate(srslte_chest_dl_t *q) {
} }
float srslte_chest_dl_get_snr(srslte_chest_dl_t *q) { float srslte_chest_dl_get_snr(srslte_chest_dl_t *q) {
return srslte_chest_dl_get_rsrp(q)/srslte_chest_dl_get_noise_estimate(q)-1; return srslte_chest_dl_get_rsrp(q)/srslte_chest_dl_get_noise_estimate(q);
} }
float srslte_chest_dl_get_rssi(srslte_chest_dl_t *q) { float srslte_chest_dl_get_rssi(srslte_chest_dl_t *q) {

@ -39,8 +39,6 @@
#define MAX_CANDIDATES 64 #define MAX_CANDIDATES 64
#define PDSCH_DO_ZF
srslte_dci_format_t ue_formats[] = {SRSLTE_DCI_FORMAT1A, SRSLTE_DCI_FORMAT1}; // SRSLTE_DCI_FORMAT1B should go here also srslte_dci_format_t ue_formats[] = {SRSLTE_DCI_FORMAT1A, SRSLTE_DCI_FORMAT1}; // SRSLTE_DCI_FORMAT1B should go here also
const uint32_t nof_ue_formats = 2; const uint32_t nof_ue_formats = 2;
@ -227,11 +225,9 @@ int srslte_ue_dl_decode_rnti_rv_packet(srslte_ue_dl_t *q, srslte_ra_dl_grant_t *
srslte_softbuffer_rx_reset(&q->softbuffer); srslte_softbuffer_rx_reset(&q->softbuffer);
} }
#ifdef PDSCH_DO_ZF // Uncoment next line to do ZF by default in pdsch_ue example
float noise_estimate = 0; //float noise_estimate = 0;
#else
float noise_estimate = srslte_chest_dl_get_noise_estimate(&q->chest); float noise_estimate = srslte_chest_dl_get_noise_estimate(&q->chest);
#endif
if (q->pdsch_cfg.grant.mcs.mod > 0 && q->pdsch_cfg.grant.mcs.tbs >= 0) { if (q->pdsch_cfg.grant.mcs.mod > 0 && q->pdsch_cfg.grant.mcs.tbs >= 0) {
ret = srslte_pdsch_decode_rnti(&q->pdsch, &q->pdsch_cfg, &q->softbuffer, ret = srslte_pdsch_decode_rnti(&q->pdsch, &q->pdsch_cfg, &q->softbuffer,

Loading…
Cancel
Save