|
|
|
@@ -149,7 +149,8 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco
|
|
|
|
|
int scg_id,
|
|
|
|
|
int servCellIndex,
|
|
|
|
|
int n_physical_antenna_ports,
|
|
|
|
|
int initial_csi_index) {
|
|
|
|
|
int initial_csi_index,
|
|
|
|
|
int uid) {
|
|
|
|
|
AssertFatal(servingcellconfigcommon!=NULL,"servingcellconfigcommon is null\n");
|
|
|
|
|
AssertFatal(secondaryCellGroup!=NULL,"secondaryCellGroup is null\n");
|
|
|
|
|
|
|
|
|
@@ -184,7 +185,17 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco
|
|
|
|
|
ASN_SEQUENCE_ADD(&secondaryCellGroup->rlc_BearerToAddModList->list, RLC_BearerConfig);
|
|
|
|
|
secondaryCellGroup->mac_CellGroupConfig=calloc(1,sizeof(*secondaryCellGroup->mac_CellGroupConfig));
|
|
|
|
|
secondaryCellGroup->mac_CellGroupConfig->drx_Config = NULL;
|
|
|
|
|
secondaryCellGroup->mac_CellGroupConfig->schedulingRequestConfig = NULL;
|
|
|
|
|
|
|
|
|
|
secondaryCellGroup->mac_CellGroupConfig->schedulingRequestConfig = calloc(1,sizeof(*secondaryCellGroup->mac_CellGroupConfig->schedulingRequestConfig));
|
|
|
|
|
secondaryCellGroup->mac_CellGroupConfig->schedulingRequestConfig->schedulingRequestToAddModList = calloc(1,sizeof(*secondaryCellGroup->mac_CellGroupConfig->schedulingRequestConfig->schedulingRequestToAddModList));
|
|
|
|
|
NR_SchedulingRequestToAddMod_t *SchedulingRequestConf = calloc(1,sizeof(*SchedulingRequestConf));
|
|
|
|
|
SchedulingRequestConf->schedulingRequestId = 0; //Could be changed
|
|
|
|
|
SchedulingRequestConf->sr_ProhibitTimer = calloc(1,sizeof(*SchedulingRequestConf->sr_ProhibitTimer));
|
|
|
|
|
*SchedulingRequestConf->sr_ProhibitTimer = NR_SchedulingRequestToAddMod__sr_ProhibitTimer_ms16;
|
|
|
|
|
SchedulingRequestConf->sr_TransMax = NR_SchedulingRequestToAddMod__sr_TransMax_n32;
|
|
|
|
|
ASN_SEQUENCE_ADD(&secondaryCellGroup->mac_CellGroupConfig->schedulingRequestConfig->schedulingRequestToAddModList->list,SchedulingRequestConf);
|
|
|
|
|
secondaryCellGroup->mac_CellGroupConfig->schedulingRequestConfig->schedulingRequestToReleaseList = NULL;
|
|
|
|
|
|
|
|
|
|
secondaryCellGroup->mac_CellGroupConfig->bsr_Config=calloc(1,sizeof(*secondaryCellGroup->mac_CellGroupConfig->bsr_Config));
|
|
|
|
|
secondaryCellGroup->mac_CellGroupConfig->bsr_Config->periodicBSR_Timer = NR_BSR_Config__periodicBSR_Timer_sf10;
|
|
|
|
|
secondaryCellGroup->mac_CellGroupConfig->bsr_Config->retxBSR_Timer = NR_BSR_Config__retxBSR_Timer_sf160;
|
|
|
|
@@ -251,7 +262,7 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco
|
|
|
|
|
if ((bitmap>>(63-i))&0x01){
|
|
|
|
|
ssbElem[n_ssb] = calloc(1,sizeof(struct NR_CFRA_SSB_Resource));
|
|
|
|
|
ssbElem[n_ssb]->ssb = i;
|
|
|
|
|
ssbElem[n_ssb]->ra_PreambleIndex = 63;
|
|
|
|
|
ssbElem[n_ssb]->ra_PreambleIndex = 63 - (uid % 64);
|
|
|
|
|
ASN_SEQUENCE_ADD(&secondaryCellGroup->spCellConfig->reconfigurationWithSync->rach_ConfigDedicated->choice.uplink->cfra->resources.choice.ssb->ssb_ResourceList.list,ssbElem[n_ssb]);
|
|
|
|
|
n_ssb++;
|
|
|
|
|
}
|
|
|
|
@@ -263,8 +274,8 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco
|
|
|
|
|
secondaryCellGroup->spCellConfig->rlf_TimersAndConstants = calloc(1,sizeof(*secondaryCellGroup->spCellConfig->rlf_TimersAndConstants));
|
|
|
|
|
secondaryCellGroup->spCellConfig->rlf_TimersAndConstants->present = NR_SetupRelease_RLF_TimersAndConstants_PR_setup;
|
|
|
|
|
secondaryCellGroup->spCellConfig->rlf_TimersAndConstants->choice.setup=calloc(1,sizeof(*secondaryCellGroup->spCellConfig->rlf_TimersAndConstants->choice.setup));
|
|
|
|
|
secondaryCellGroup->spCellConfig->rlf_TimersAndConstants->choice.setup->t310 = NR_RLF_TimersAndConstants__t310_ms2000;
|
|
|
|
|
secondaryCellGroup->spCellConfig->rlf_TimersAndConstants->choice.setup->n310 = NR_RLF_TimersAndConstants__n310_n10;
|
|
|
|
|
secondaryCellGroup->spCellConfig->rlf_TimersAndConstants->choice.setup->t310 = NR_RLF_TimersAndConstants__t310_ms4000;
|
|
|
|
|
secondaryCellGroup->spCellConfig->rlf_TimersAndConstants->choice.setup->n310 = NR_RLF_TimersAndConstants__n310_n20;
|
|
|
|
|
secondaryCellGroup->spCellConfig->rlf_TimersAndConstants->choice.setup->n311 = NR_RLF_TimersAndConstants__n311_n1;
|
|
|
|
|
secondaryCellGroup->spCellConfig->rlf_TimersAndConstants->choice.setup->ext1 = calloc(1,sizeof(*secondaryCellGroup->spCellConfig->rlf_TimersAndConstants->choice.setup->ext1));
|
|
|
|
|
secondaryCellGroup->spCellConfig->rlf_TimersAndConstants->choice.setup->ext1->t311 = NR_RLF_TimersAndConstants__ext1__t311_ms30000;
|
|
|
|
@@ -975,7 +986,7 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco
|
|
|
|
|
NR_PUCCH_Resource_t *pucchres2=calloc(1,sizeof(*pucchres2));
|
|
|
|
|
NR_PUCCH_Resource_t *pucchres3=calloc(1,sizeof(*pucchres3));
|
|
|
|
|
pucchres0->pucch_ResourceId=1;
|
|
|
|
|
pucchres0->startingPRB=8;
|
|
|
|
|
pucchres0->startingPRB= (8 + uid) % curr_bwp;
|
|
|
|
|
pucchres0->intraSlotFrequencyHopping=NULL;
|
|
|
|
|
pucchres0->secondHopPRB=NULL;
|
|
|
|
|
pucchres0->format.present= NR_PUCCH_Resource__format_PR_format0;
|
|
|
|
@@ -986,7 +997,7 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco
|
|
|
|
|
ASN_SEQUENCE_ADD(&pucch_Config->resourceToAddModList->list,pucchres0);
|
|
|
|
|
|
|
|
|
|
pucchres1->pucch_ResourceId=2;
|
|
|
|
|
pucchres1->startingPRB=8;
|
|
|
|
|
pucchres1->startingPRB= (8 + uid) % curr_bwp;
|
|
|
|
|
pucchres1->intraSlotFrequencyHopping=NULL;
|
|
|
|
|
pucchres1->secondHopPRB=NULL;
|
|
|
|
|
pucchres1->format.present= NR_PUCCH_Resource__format_PR_format0;
|
|
|
|
@@ -1029,7 +1040,19 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco
|
|
|
|
|
pucchfmt2->nrofSlots=NULL;
|
|
|
|
|
pucchfmt2->pi2BPSK=NULL;
|
|
|
|
|
pucchfmt2->simultaneousHARQ_ACK_CSI=NULL;
|
|
|
|
|
pucch_Config->schedulingRequestResourceToAddModList=NULL;
|
|
|
|
|
|
|
|
|
|
// for scheduling requestresource
|
|
|
|
|
pucch_Config->schedulingRequestResourceToAddModList = calloc(1,sizeof(*pucch_Config->schedulingRequestResourceToAddModList));
|
|
|
|
|
NR_SchedulingRequestResourceConfig_t *schedulingRequestResourceConfig = calloc(1,sizeof(*schedulingRequestResourceConfig));
|
|
|
|
|
schedulingRequestResourceConfig->schedulingRequestResourceId = 1;
|
|
|
|
|
schedulingRequestResourceConfig->schedulingRequestID = 0;
|
|
|
|
|
schedulingRequestResourceConfig->periodicityAndOffset = calloc(1,sizeof(*schedulingRequestResourceConfig->periodicityAndOffset));
|
|
|
|
|
schedulingRequestResourceConfig->periodicityAndOffset->present = NR_SchedulingRequestResourceConfig__periodicityAndOffset_PR_sl10;
|
|
|
|
|
schedulingRequestResourceConfig->periodicityAndOffset->choice.sl10 = 7;
|
|
|
|
|
schedulingRequestResourceConfig->resource = calloc(1,sizeof(*schedulingRequestResourceConfig->resource));
|
|
|
|
|
*schedulingRequestResourceConfig->resource = 1;
|
|
|
|
|
ASN_SEQUENCE_ADD(&pucch_Config->schedulingRequestResourceToAddModList->list,schedulingRequestResourceConfig);
|
|
|
|
|
|
|
|
|
|
pucch_Config->schedulingRequestResourceToReleaseList=NULL;
|
|
|
|
|
pucch_Config->multi_CSI_PUCCH_ResourceList=NULL;
|
|
|
|
|
pucch_Config->dl_DataToUL_ACK = calloc(1,sizeof(*pucch_Config->dl_DataToUL_ACK));
|
|
|
|
@@ -1177,7 +1200,7 @@ void fill_default_secondaryCellGroup(NR_ServingCellConfigCommon_t *servingcellco
|
|
|
|
|
csirep1->reportConfigType.present = NR_CSI_ReportConfig__reportConfigType_PR_periodic;
|
|
|
|
|
csirep1->reportConfigType.choice.periodic = calloc(1,sizeof(*csirep1->reportConfigType.choice.periodic));
|
|
|
|
|
csirep1->reportConfigType.choice.periodic->reportSlotConfig.present=NR_CSI_ReportPeriodicityAndOffset_PR_slots320;
|
|
|
|
|
csirep1->reportConfigType.choice.periodic->reportSlotConfig.choice.slots320 = 49;
|
|
|
|
|
csirep1->reportConfigType.choice.periodic->reportSlotConfig.choice.slots320 = 9 + (10 * uid) % 320;
|
|
|
|
|
NR_PUCCH_CSI_Resource_t *pucchcsires1 = calloc(1,sizeof(*pucchcsires1));
|
|
|
|
|
pucchcsires1->uplinkBandwidthPartId=1;
|
|
|
|
|
pucchcsires1->pucch_Resource=3;
|
|
|
|
@@ -1241,14 +1264,22 @@ void fill_default_reconfig(NR_ServingCellConfigCommon_t *servingcellconfigcommon
|
|
|
|
|
NR_RRCReconfiguration_IEs_t *reconfig,
|
|
|
|
|
NR_CellGroupConfig_t *secondaryCellGroup,
|
|
|
|
|
int n_physical_antenna_ports,
|
|
|
|
|
int initial_csi_index) {
|
|
|
|
|
int initial_csi_index,
|
|
|
|
|
int uid) {
|
|
|
|
|
AssertFatal(servingcellconfigcommon!=NULL,"servingcellconfigcommon is null\n");
|
|
|
|
|
AssertFatal(reconfig!=NULL,"reconfig is null\n");
|
|
|
|
|
AssertFatal(secondaryCellGroup!=NULL,"secondaryCellGroup is null\n");
|
|
|
|
|
// radioBearerConfig
|
|
|
|
|
reconfig->radioBearerConfig=NULL;
|
|
|
|
|
// secondaryCellGroup
|
|
|
|
|
fill_default_secondaryCellGroup(servingcellconfigcommon,servingcellconfigdedicated,secondaryCellGroup,1,1,n_physical_antenna_ports,initial_csi_index);
|
|
|
|
|
fill_default_secondaryCellGroup(servingcellconfigcommon,
|
|
|
|
|
servingcellconfigdedicated,
|
|
|
|
|
secondaryCellGroup,
|
|
|
|
|
1,
|
|
|
|
|
1,
|
|
|
|
|
n_physical_antenna_ports,
|
|
|
|
|
initial_csi_index,
|
|
|
|
|
uid);
|
|
|
|
|
xer_fprint(stdout, &asn_DEF_NR_CellGroupConfig, (const void*)secondaryCellGroup);
|
|
|
|
|
|
|
|
|
|
char scg_buffer[1024];
|
|
|
|
|