Commit 3c4edbb3 authored by masayuki.harada's avatar masayuki.harada Committed by Haruki NAOI

Fix receive pucch 1a and power adjustment of pucch.

(cherry picked from commit 6d5a40bd826de160ddf55599f61d1359cfba3fa4)

# Conflicts:
#	openair1/PHY/LTE_TRANSPORT/pucch.c
parent 4892feae
...@@ -1303,8 +1303,12 @@ uint32_t rx_pucch(PHY_VARS_eNB *eNB, ...@@ -1303,8 +1303,12 @@ uint32_t rx_pucch(PHY_VARS_eNB *eNB,
#endif #endif
} }
// this is total energy received, summed over data and reference // this is total energy received, summed over data and reference
if (fmt==pucch_format1a){
stat += ((((stat_re*stat_re)) + ((stat_ref_re*stat_ref_re)) + ((stat_ref_im*stat_ref_im)))/nsymb);
}else{
stat += ((((stat_re*stat_re)) + ((stat_im*stat_im)) + stat += ((((stat_re*stat_re)) + ((stat_im*stat_im)) +
((stat_ref_re*stat_ref_re)) + ((stat_ref_im*stat_ref_im)))/nsymb); ((stat_ref_re*stat_ref_re)) + ((stat_ref_im*stat_ref_im)))/nsymb);
}
// now second slot // now second slot
stat_re=0; stat_re=0;
...@@ -1335,8 +1339,12 @@ uint32_t rx_pucch(PHY_VARS_eNB *eNB, ...@@ -1335,8 +1339,12 @@ uint32_t rx_pucch(PHY_VARS_eNB *eNB,
printf("aa%d re %d : phase %d : stat %d\n",aa,re,phase,stat); printf("aa%d re %d : phase %d : stat %d\n",aa,re,phase,stat);
#endif #endif
if (fmt==pucch_format1a){
stat += ((((stat_re*stat_re)) + ((stat_ref_re*stat_ref_re)) + ((stat_ref_im*stat_ref_im)))/nsymb);
}else{
stat += ((((stat_re*stat_re)) + ((stat_im*stat_im)) + stat += ((((stat_re*stat_re)) + ((stat_im*stat_im)) +
((stat_ref_re*stat_ref_re)) + ((stat_ref_im*stat_ref_im)))/nsymb); ((stat_ref_re*stat_ref_re)) + ((stat_ref_im*stat_ref_im)))/nsymb);
}
} //re } //re
......
...@@ -602,7 +602,7 @@ void fill_sr_indication(PHY_VARS_eNB *eNB,uint16_t rnti,int frame,int subframe,u ...@@ -602,7 +602,7 @@ void fill_sr_indication(PHY_VARS_eNB *eNB,uint16_t rnti,int frame,int subframe,u
// pdu->rx_ue_information.handle = handle; // pdu->rx_ue_information.handle = handle;
pdu->rx_ue_information.tl.tag = NFAPI_RX_UE_INFORMATION_TAG; pdu->rx_ue_information.tl.tag = NFAPI_RX_UE_INFORMATION_TAG;
pdu->rx_ue_information.rnti = rnti; pdu->rx_ue_information.rnti = rnti;
int SNRtimes10 = dB_fixed_x10(stat) - 10 * eNB->measurements.n0_pucch_dB; int SNRtimes10 = dB_fixed_x10(stat) - 10 * eNB->measurements.n0_pucch_dB - 10 * eNB->pucch1_DTX_threshold;
pdu->ul_cqi_information.tl.tag = NFAPI_UL_CQI_INFORMATION_TAG; pdu->ul_cqi_information.tl.tag = NFAPI_UL_CQI_INFORMATION_TAG;
if (SNRtimes10 < -640) pdu->ul_cqi_information.ul_cqi=0; if (SNRtimes10 < -640) pdu->ul_cqi_information.ul_cqi=0;
...@@ -1839,7 +1839,7 @@ void fill_uci_harq_indication (PHY_VARS_eNB *eNB, LTE_eNB_UCI *uci, int frame, i ...@@ -1839,7 +1839,7 @@ void fill_uci_harq_indication (PHY_VARS_eNB *eNB, LTE_eNB_UCI *uci, int frame, i
pdu->rx_ue_information.rnti = uci->rnti; pdu->rx_ue_information.rnti = uci->rnti;
// estimate UL_CQI for MAC (from antenna port 0 only) // estimate UL_CQI for MAC (from antenna port 0 only)
pdu->ul_cqi_information.tl.tag = NFAPI_UL_CQI_INFORMATION_TAG; pdu->ul_cqi_information.tl.tag = NFAPI_UL_CQI_INFORMATION_TAG;
int SNRtimes10 = dB_fixed_x10(uci->stat) - 10 * eNB->measurements.n0_pucch_dB; int SNRtimes10 = dB_fixed_x10(uci->stat) - 10 * eNB->measurements.n0_pucch_dB - 10 * eNB->pucch1ab_DTX_threshold;
if (SNRtimes10 < -100) if (SNRtimes10 < -100)
LOG_I (PHY, "uci->stat %d \n", uci->stat); LOG_I (PHY, "uci->stat %d \n", uci->stat);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment