RSRP computed from recv signal

This commit is contained in:
Ismael Gomez 2016-02-17 17:08:16 +00:00
parent bcc80bc6c0
commit a2e1ecebdb
2 changed files with 4 additions and 8 deletions

View File

@ -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 */
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) {
/* compute rssi only for port 0 */
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) {
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) {

View File

@ -39,8 +39,6 @@
#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
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);
}
#ifdef PDSCH_DO_ZF
float noise_estimate = 0;
#else
// Uncoment next line to do ZF by default in pdsch_ue example
//float noise_estimate = 0;
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) {
ret = srslte_pdsch_decode_rnti(&q->pdsch, &q->pdsch_cfg, &q->softbuffer,