Added PRS resource repetition capability in OAI gNB and UE
This commit is contained in:
@@ -68,11 +68,14 @@ uint8_t check_prs_slot_gNB(uint8_t *prs_rsc_id, NR_gNB_PRS *prs_vars, NR_DL_FRAM
|
||||
uint8_t is_prs_slot = 0, rsc_id = 0;
|
||||
for(rsc_id = 0; rsc_id < prs_vars->NumPRSResources; rsc_id++)
|
||||
{
|
||||
if((prs_vars->prs_cfg[rsc_id].PRSResourceSetPeriod[1] + prs_vars->prs_cfg[rsc_id].PRSResourceOffset) == ((frame_tx*fp->slots_per_frame+nr_slot_tx)%prs_vars->prs_cfg[rsc_id].PRSResourceSetPeriod[0]))
|
||||
for (int i = 0; i < prs_vars->prs_cfg[rsc_id].PRSResourceRepetition; i++)
|
||||
{
|
||||
is_prs_slot = 1;
|
||||
*prs_rsc_id = rsc_id;
|
||||
break;
|
||||
if( (((frame_tx*fp->slots_per_frame + nr_slot_tx) - (prs_vars->prs_cfg[rsc_id].PRSResourceSetPeriod[1] + prs_vars->prs_cfg[rsc_id].PRSResourceOffset))%prs_vars->prs_cfg[rsc_id].PRSResourceSetPeriod[0]) == i*prs_vars->prs_cfg[rsc_id].PRSResourceTimeGap )
|
||||
{
|
||||
is_prs_slot = 1;
|
||||
*prs_rsc_id = rsc_id;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return is_prs_slot;
|
||||
|
||||
@@ -1381,13 +1381,15 @@ uint8_t check_prs_slot_nrUE(PHY_VARS_NR_UE *ue, NR_DL_FRAME_PARMS *fp, uint8_t *
|
||||
{
|
||||
for(rsc_id = 0; rsc_id < ue->prs_vars[gNB_id]->NumPRSResources; rsc_id++)
|
||||
{
|
||||
if((ue->prs_vars[gNB_id]->prs_resource[rsc_id].prs_cfg.PRSResourceSetPeriod[1] + ue->prs_vars[gNB_id]->prs_resource[rsc_id].prs_cfg.PRSResourceOffset) ==
|
||||
((frame_rx*fp->slots_per_frame + nr_slot_rx)%ue->prs_vars[gNB_id]->prs_resource[rsc_id].prs_cfg.PRSResourceSetPeriod[0]))
|
||||
for (int i = 0; i < ue->prs_vars[gNB_id]->prs_resource[rsc_id].prs_cfg.PRSResourceRepetition; i++)
|
||||
{
|
||||
is_prs_slot = 1;
|
||||
*prs_rsc_id = rsc_id;
|
||||
*prs_gNB_id = gNB_id;
|
||||
return is_prs_slot;
|
||||
if( (((frame_rx*fp->slots_per_frame + nr_slot_rx) - (ue->prs_vars[gNB_id]->prs_resource[rsc_id].prs_cfg.PRSResourceSetPeriod[1] + ue->prs_vars[gNB_id]->prs_resource[rsc_id].prs_cfg.PRSResourceOffset))%ue->prs_vars[gNB_id]->prs_resource[rsc_id].prs_cfg.PRSResourceSetPeriod[0]) == i*ue->prs_vars[gNB_id]->prs_resource[rsc_id].prs_cfg.PRSResourceTimeGap)
|
||||
{
|
||||
is_prs_slot = 1;
|
||||
*prs_rsc_id = rsc_id;
|
||||
*prs_gNB_id = gNB_id;
|
||||
return is_prs_slot;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user