Compare commits

...

10 Commits

31 changed files with 1612 additions and 71 deletions

View File

@@ -36,6 +36,7 @@
#include "LAYER2/nr_pdcp/nr_pdcp_oai_api.h"
#include "LAYER2/nr_rlc/nr_rlc_oai_api.h"
#include "RRC/NR/MESSAGES/asn1_msg.h"
#include "PHY/MODULATION/nr_modulation.h"
/*
* NR SLOT PROCESSING SEQUENCE
@@ -519,9 +520,23 @@ static int UE_dl_preprocessing(PHY_VARS_NR_UE *UE, const UE_nr_rxtx_proc_t *proc
// Start synchronization with a target gNB
if (UE->synch_request.received_synch_request == 1) {
fapi_nr_synch_request_t *synch_req = &UE->synch_request.synch_req;
if( synch_req->absoluteFrequencySSB != UINT64_MAX) {
uint64_t diff = UE->frame_parms.dl_CarrierFreq - UE->frame_parms.ul_CarrierFreq;
uint64_t dl_bw = (12 * UE->frame_parms.N_RB_DL) * (15000 << synch_req->scs);
uint64_t dl_CarrierFreq = (dl_bw >> 1) + synch_req->absoluteFrequencyPointA;
UE->frame_parms.dl_CarrierFreq = dl_CarrierFreq;
UE->frame_parms.ul_CarrierFreq = dl_CarrierFreq - diff;
nr_rf_card_config_freq(&openair0_cfg[UE->rf_map.card], UE->frame_parms.ul_CarrierFreq, UE->frame_parms.dl_CarrierFreq, 0);
UE->rfdevice.trx_set_freq_func(&UE->rfdevice, &openair0_cfg[0]);
init_symbol_rotation(&UE->frame_parms);
}
UE->is_synchronized = 0;
UE->UE_scan_carrier = UE->synch_request.synch_req.ssb_bw_scan;
UE->target_Nid_cell = UE->synch_request.synch_req.target_Nid_cell;
UE->UE_scan_carrier = synch_req->ssb_bw_scan;
UE->target_Nid_cell = synch_req->target_Nid_cell;
clean_UE_harq(UE);
UE->synch_request.received_synch_request = 0;
}

View File

@@ -681,6 +681,9 @@ typedef struct
} fapi_nr_prach_config_t;
typedef struct {
uint64_t absoluteFrequencySSB;
uint64_t absoluteFrequencyPointA;
uint8_t scs;
int16_t target_Nid_cell;
bool ssb_bw_scan;
} fapi_nr_synch_request_t;

View File

@@ -420,14 +420,31 @@ typedef struct f1ap_drb_to_be_released_t {
long rb_id;
} f1ap_drb_to_be_released_t;
typedef struct protocol_extension_container_s {
uint8_t *handover_oreparation_information;
uint32_t handover_oreparation_information_length;
uint8_t *cell_group_config;
uint32_t cell_group_config_length;
uint8_t *measurement_timing_configuration;
uint32_t measurement_timing_configuration_length;
uint8_t *ue_assistance_information;
uint32_t ue_assistance_information_length;
uint8_t *cg_config;
uint32_t cg_config_length;
uint8_t *ue_ssistance_information_EUTRA;
uint32_t ue_ssistance_information_EUTRA_length;
} protocol_extension_container_t;
typedef struct cu_to_du_rrc_information_s {
uint8_t * cG_ConfigInfo;
uint32_t cG_ConfigInfo_length;
uint8_t * uE_CapabilityRAT_ContainerList;
uint32_t uE_CapabilityRAT_ContainerList_length;
uint8_t * measConfig;
uint32_t measConfig_length;
}cu_to_du_rrc_information_t;
uint8_t *cG_ConfigInfo;
uint32_t cG_ConfigInfo_length;
uint8_t *uE_CapabilityRAT_ContainerList;
uint32_t uE_CapabilityRAT_ContainerList_length;
uint8_t *measConfig;
uint32_t measConfig_length;
protocol_extension_container_t *ie_extensions;
uint32_t ie_extensions_length;
} cu_to_du_rrc_information_t;
typedef struct du_to_cu_rrc_information_s {
uint8_t * cellGroupConfig;
@@ -463,6 +480,7 @@ typedef struct f1ap_ue_context_setup_s {
//uint8_t *du_to_cu_rrc_information;
du_to_cu_rrc_information_t *du_to_cu_rrc_information;
uint32_t du_to_cu_rrc_information_length;
uint16_t *crnti;
f1ap_drb_to_be_setup_t *drbs_to_be_setup;
uint8_t drbs_to_be_setup_length;
f1ap_drb_to_be_setup_t *drbs_to_be_modified;
@@ -479,6 +497,7 @@ typedef struct f1ap_ue_context_setup_s {
ReconfigurationCompl_t ReconfigComplOutcome;
uint8_t *rrc_container;
int rrc_container_length;
uint8_t *transmission_action_indicator;
} f1ap_ue_context_setup_t, f1ap_ue_context_modif_req_t, f1ap_ue_context_modif_resp_t;
typedef enum F1ap_Cause_e {

View File

@@ -272,6 +272,22 @@ int CU_send_UE_CONTEXT_SETUP_REQUEST(sctp_assoc_t assoc_id, f1ap_ue_context_setu
OCTET_STRING_fromBuf(measConfig, (const char*)f1ap_ue_context_setup_req->cu_to_du_rrc_information->measConfig,
f1ap_ue_context_setup_req->cu_to_du_rrc_information->measConfig_length);
}
/* optional */
/* 6.4 iE_Extensions */
if (f1ap_ue_context_setup_req->cu_to_du_rrc_information->ie_extensions != NULL) {
F1AP_ProtocolExtensionContainer_10696P60_t *p_10696P60 = calloc(1, sizeof(*p_10696P60));
ie6->value.choice.CUtoDURRCInformation.iE_Extensions = (struct F1AP_ProtocolExtensionContainer *)p_10696P60;
if (f1ap_ue_context_setup_req->cu_to_du_rrc_information->ie_extensions->cell_group_config != NULL) {
asn1cSequenceAdd(p_10696P60->list, F1AP_CUtoDURRCInformation_ExtIEs_t, cu_to_du__ExtIEs);
cu_to_du__ExtIEs->id = F1AP_ProtocolIE_ID_id_CellGroupConfig;
cu_to_du__ExtIEs->criticality = F1AP_Criticality_reject;
cu_to_du__ExtIEs->extensionValue.present = F1AP_CUtoDURRCInformation_ExtIEs__extensionValue_PR_CellGroupConfig;
F1AP_CellGroupConfig_t *CellGroupConfig = &cu_to_du__ExtIEs->extensionValue.choice.CellGroupConfig;
OCTET_STRING_fromBuf(CellGroupConfig,
(const char *)f1ap_ue_context_setup_req->cu_to_du_rrc_information->ie_extensions->cell_group_config,
f1ap_ue_context_setup_req->cu_to_du_rrc_information->ie_extensions->cell_group_config_length);
}
}
}
/* optional */
@@ -600,6 +616,12 @@ int CU_handle_UE_CONTEXT_SETUP_RESPONSE(instance_t instance, sctp_assoc_t assoc_
F1AP_ProtocolIE_ID_id_gNB_DU_UE_F1AP_ID, true);
f1ap_ue_context_setup_resp->gNB_DU_ue_id = ie->value.choice.GNB_DU_UE_F1AP_ID;
LOG_D(F1AP, "f1ap_ue_context_setup_resp->gNB_DU_ue_id is: %d \n", f1ap_ue_context_setup_resp->gNB_DU_ue_id);
F1AP_FIND_PROTOCOLIE_BY_ID(F1AP_UEContextSetupResponseIEs_t, ie, container, F1AP_ProtocolIE_ID_id_C_RNTI, false);
if (ie) {
f1ap_ue_context_setup_resp->crnti = calloc(1, sizeof(uint16_t));
*f1ap_ue_context_setup_resp->crnti = ie->value.choice.C_RNTI;
}
// DUtoCURRCInformation
F1AP_FIND_PROTOCOLIE_BY_ID(F1AP_UEContextSetupResponseIEs_t, ie, container,
F1AP_ProtocolIE_ID_id_DUtoCURRCInformation, true);
@@ -1001,12 +1023,12 @@ int CU_send_UE_CONTEXT_MODIFICATION_REQUEST(sctp_assoc_t assoc_id, f1ap_ue_conte
/* optional */
/* c7. TransmissionActionIndicator */
if (0) {
if (f1ap_ue_context_modification_req->transmission_action_indicator != NULL) {
asn1cSequenceAdd(out->protocolIEs.list, F1AP_UEContextModificationRequestIEs_t, ie7);
ie7->id = F1AP_ProtocolIE_ID_id_TransmissionActionIndicator;
ie7->criticality = F1AP_Criticality_ignore;
ie7->value.present = F1AP_UEContextModificationRequestIEs__value_PR_TransmissionActionIndicator;
ie7->value.choice.TransmissionActionIndicator = F1AP_TransmissionActionIndicator_stop;
ie7->value.choice.TransmissionActionIndicator = *f1ap_ue_context_modification_req->transmission_action_indicator;
}
/* optional */

View File

@@ -176,6 +176,24 @@ int DU_handle_UE_CONTEXT_SETUP_REQUEST(instance_t instance, sctp_assoc_t assoc_i
f1ap_ue_context_setup_req->cu_to_du_rrc_information->uE_CapabilityRAT_ContainerList_length = ieCuRrcInfo->value.choice.CUtoDURRCInformation.uE_CapabilityRAT_ContainerList->size;
LOG_D(F1AP, "Size f1ap_ue_context_setup_req->cu_to_du_rrc_information->uE_CapabilityRAT_ContainerList_length: %d \n", f1ap_ue_context_setup_req->cu_to_du_rrc_information->uE_CapabilityRAT_ContainerList_length);
}
if (ieCuRrcInfo->value.choice.CUtoDURRCInformation.iE_Extensions != NULL) {
f1ap_ue_context_setup_req->cu_to_du_rrc_information->ie_extensions = (protocol_extension_container_t *)calloc(1, sizeof(protocol_extension_container_t));
F1AP_ProtocolExtensionContainer_10696P60_t *ie_extensions = (F1AP_ProtocolExtensionContainer_10696P60_t *)ieCuRrcInfo->value.choice.CUtoDURRCInformation.iE_Extensions;
for (int i_ext = 0; i_ext < ie_extensions->list.count; i_ext++) {
F1AP_CUtoDURRCInformation_ExtIEs_t *ie = ie_extensions->list.array[i_ext];
switch (ie->extensionValue.present) {
case F1AP_CUtoDURRCInformation_ExtIEs__extensionValue_PR_CellGroupConfig:
f1ap_ue_context_setup_req->cu_to_du_rrc_information->ie_extensions->cell_group_config =
(uint8_t *)calloc(1, ie->extensionValue.choice.CellGroupConfig.size*sizeof(uint8_t));
memcpy(f1ap_ue_context_setup_req->cu_to_du_rrc_information->ie_extensions->cell_group_config, ie->extensionValue.choice.CellGroupConfig.buf, ie->extensionValue.choice.CellGroupConfig.size);
f1ap_ue_context_setup_req->cu_to_du_rrc_information->ie_extensions->cell_group_config_length = ie->extensionValue.choice.CellGroupConfig.size;
break;
default:
LOG_E(F1AP, "%s: Procedures for extension value %i are not implemented yet!\n", __FUNCTION__, ie->extensionValue.present);
break;
}
}
}
}
/* DRB */
@@ -352,15 +370,12 @@ int DU_send_UE_CONTEXT_SETUP_RESPONSE(sctp_assoc_t assoc_id, f1ap_ue_context_set
/* optional */
/* c4. C_RNTI */
if (0) {
if (resp->crnti!=NULL) {
asn1cSequenceAdd(out->protocolIEs.list, F1AP_UEContextSetupResponseIEs_t, ie4);
ie4->id = F1AP_ProtocolIE_ID_id_C_RNTI;
ie4->criticality = F1AP_Criticality_ignore;
ie4->value.present = F1AP_UEContextSetupResponseIEs__value_PR_C_RNTI;
//C_RNTI_TO_BIT_STRING(rntiP, &ie->value.choice.C_RNTI);
ie4->value.choice.C_RNTI=0;
AssertFatal(false, "not implemented\n");
LOG_E(F1AP,"RNTI to code!\n");
ie4->value.choice.C_RNTI = *resp->crnti;
}
/* optional */
@@ -1015,6 +1030,7 @@ int DU_handle_UE_CONTEXT_MODIFICATION_REQUEST(instance_t instance, sctp_assoc_t
/* correct here */
if ( ieRRC->value.choice.RRCContainer.size ) {
f1ap_ue_context_modification_req->rrc_container = malloc(ieRRC->value.choice.RRCContainer.size);
f1ap_ue_context_modification_req->rrc_container_length = ieRRC->value.choice.RRCContainer.size;
memcpy(f1ap_ue_context_modification_req->rrc_container,
ieRRC->value.choice.RRCContainer.buf, ieRRC->value.choice.RRCContainer.size);
f1ap_ue_context_modification_req->rrc_container_length = ieRRC->value.choice.RRCContainer.size;
@@ -1051,6 +1067,19 @@ int DU_handle_UE_CONTEXT_MODIFICATION_REQUEST(instance_t instance, sctp_assoc_t
}
}
/* TransmissionActionIndicator */
F1AP_UEContextModificationRequestIEs_t *ieTxInd;
F1AP_FIND_PROTOCOLIE_BY_ID(F1AP_UEContextModificationRequestIEs_t,
ieTxInd,
container,
F1AP_ProtocolIE_ID_id_TransmissionActionIndicator,
false);
if (ieTxInd) {
f1ap_ue_context_modification_req->transmission_action_indicator = calloc(1, sizeof(uint8_t));
*f1ap_ue_context_modification_req->transmission_action_indicator = ieTxInd->value.choice.TransmissionActionIndicator;
}
ue_context_modification_request(f1ap_ue_context_modification_req);
return 0;
}

View File

@@ -1728,9 +1728,8 @@ void RCconfig_NRRRC(gNB_RRC_INST *rrc)
rrc->eth_params_s.transp_preference = ETH_UDP_MODE;
}
rrc->nr_cellid = (uint64_t)*(GNBParamList.paramarray[i][GNB_NRCELLID_IDX].u64ptr);
rrc->nr_cellid = (uint64_t)*(GNBParamList.paramarray[i][GNB_NRCELLID_IDX].u64ptr);
rrc->location_ho_trigger = (int32_t)*(GNBParamList.paramarray[i][GNB_LOCATION_HO_TRIGGER_IDX].iptr);
if (strcmp(*(GNBParamList.paramarray[i][GNB_TRANSPORT_S_PREFERENCE_IDX].strptr), "local_mac") == 0) {

View File

@@ -134,6 +134,7 @@ typedef enum {
#define GNB_CONFIG_STRING_FORCEUL256QAMOFF "force_UL256qam_off"
#define GNB_CONFIG_STRING_GNB_DU_ID "gNB_DU_ID"
#define GNB_CONFIG_STRING_GNB_CU_UP_ID "gNB_CU_UP_ID"
#define GNB_CONFIG_STRING_LOCATION_HO_TRIGGER "location_ho_trigger"
#define GNB_CONFIG_HLP_STRING_ENABLE_SDAP "enable the SDAP layer\n"
#define GNB_CONFIG_HLP_FORCE256QAMOFF "suppress activation of 256 QAM despite UE support"
@@ -180,6 +181,7 @@ typedef enum {
{GNB_CONFIG_STRING_USE_DELTA_MCS, GNB_CONFIG_HLP_USE_DELTA_MCS, 0, .iptr=NULL, .defintval=0, TYPE_INT, 0}, \
{GNB_CONFIG_STRING_FORCEUL256QAMOFF, GNB_CONFIG_HLP_FORCEUL256QAMOFF, 0, .iptr=NULL, .defintval=0, TYPE_INT, 0}, \
{GNB_CONFIG_STRING_MAXMIMOLAYERS, GNB_CONFIG_HLP_MAXMIMOLAYERS, 0, .iptr=NULL, .defintval=-1, TYPE_INT, 0}, \
{GNB_CONFIG_STRING_LOCATION_HO_TRIGGER, NULL, 0, .iptr=NULL, .defintval=-1, TYPE_INT, 0}, \
}
// clang-format on
@@ -216,6 +218,7 @@ typedef enum {
#define GNB_USE_DELTA_MCS_IDX 29
#define GNB_FORCEUL256QAMOFF_IDX 30
#define GNB_MAXMIMOLAYERS_IDX 31
#define GNB_LOCATION_HO_TRIGGER_IDX 32
#define TRACKING_AREA_CODE_OKRANGE {0x0001,0xFFFD}
#define GNBPARAMS_CHECK { \

View File

@@ -1512,6 +1512,23 @@ static void handle_reconfiguration_with_sync(NR_UE_MAC_INST_t *mac,
}
if (reconfigurationWithSync->spCellConfigCommon) {
if (reconfigurationWithSync->spCellConfigCommon->downlinkConfigCommon && reconfigurationWithSync->spCellConfigCommon->downlinkConfigCommon->frequencyInfoDL) {
struct NR_FrequencyInfoDL *frequencyInfoDL = reconfigurationWithSync->spCellConfigCommon->downlinkConfigCommon->frequencyInfoDL;
mac->synch_request.synch_req.scs = frequencyInfoDL->scs_SpecificCarrierList.list.array[0]->subcarrierSpacing;
mac->synch_request.synch_req.absoluteFrequencySSB = from_nrarfcn(*frequencyInfoDL->frequencyBandList.list.array[0],
frequencyInfoDL->scs_SpecificCarrierList.list.array[0]->subcarrierSpacing,
*frequencyInfoDL->absoluteFrequencySSB);
mac->synch_request.synch_req.absoluteFrequencyPointA = from_nrarfcn(*frequencyInfoDL->frequencyBandList.list.array[0],
frequencyInfoDL->scs_SpecificCarrierList.list.array[0]->subcarrierSpacing,
frequencyInfoDL->absoluteFrequencyPointA);
} else {
// UINT64_MAX is an invalid value
mac->synch_request.synch_req.absoluteFrequencySSB = UINT64_MAX;
mac->synch_request.synch_req.absoluteFrequencyPointA = UINT64_MAX;
}
NR_ServingCellConfigCommon_t *scc = reconfigurationWithSync->spCellConfigCommon;
if (scc->physCellId)
mac->physCellId = *scc->physCellId;

View File

@@ -2002,7 +2002,7 @@ static int get_nr_prach_info_from_ssb_index(prach_association_pattern_t *prach_a
ssb_info_p->mapped_ro[n_mapped_ro]->frame,
ssb_info_p->mapped_ro[n_mapped_ro]->slot,
prach_assoc_pattern->nb_of_frame);
if ((slot == ssb_info_p->mapped_ro[n_mapped_ro]->slot) &&
if ((slot == ssb_info_p->mapped_ro[n_mapped_ro]->slot) && prach_assoc_pattern->prach_conf_period_list[0].nb_of_frame != 0 &&
(ssb_info_p->mapped_ro[n_mapped_ro]->frame == (frame % prach_assoc_pattern->nb_of_frame))) {
uint8_t prach_config_period_nb = ssb_info_p->mapped_ro[n_mapped_ro]->frame / prach_assoc_pattern->prach_conf_period_list[0].nb_of_frame;
uint8_t frame_nb_in_prach_config_period = ssb_info_p->mapped_ro[n_mapped_ro]->frame % prach_assoc_pattern->prach_conf_period_list[0].nb_of_frame;

View File

@@ -334,7 +334,8 @@ static void nr_store_dlsch_buffer(module_id_t module_id, frame_t frame, sub_fram
const int lcid = c->lcid;
const uint16_t rnti = UE->rnti;
LOG_D(NR_MAC, "In %s: UE %x: LCID %d\n", __FUNCTION__, rnti, lcid);
if (lcid == DL_SCH_LCID_DTCH && sched_ctrl->rrc_processing_timer > 0) {
if ((lcid == DL_SCH_LCID_DTCH && sched_ctrl->rrc_processing_timer > 0) ||
(sched_ctrl->transmission_stop && sched_ctrl->rrc_processing_timer == 0)) {
continue;
}
start_meas(&RC.nrmac[module_id]->rlc_status_ind);
@@ -958,7 +959,7 @@ void nr_schedule_ue_spec(module_id_t module_id,
* Possible improvement: take the periodicity from input file.
* If such UE is not scheduled now, it will be by the preprocessor later.
* If we add the CE, ta_apply will be reset */
if (frame == (sched_ctrl->ta_frame + 100) % 1024) {
if ((frame == (sched_ctrl->ta_frame + 100) % 1024) && (sched_ctrl->transmission_stop == false)) {
sched_ctrl->ta_apply = true; /* the timer is reset once TA CE is scheduled */
LOG_D(NR_MAC, "[UE %04x][%d.%d] UL timing alignment procedures: setting flag for Timing Advance command\n", UE->rnti, frame, slot);
}

View File

@@ -2671,6 +2671,17 @@ void mac_remove_nr_ue(gNB_MAC_INST *nr_mac, rnti_t rnti)
memcpy(UE_info->list, newUEs, sizeof(UE_info->list));
NR_SCHED_UNLOCK(&UE_info->mutex);
const int CC_id = 0;
NR_COMMON_channels_t *cc = &nr_mac->common_channels[CC_id];
for (int i = 0; i < NR_NB_RA_PROC_MAX; i++) {
NR_RA_t *ra = &cc->ra[i];
if (ra->rnti == UE->rnti) {
nr_clear_ra_proc(ra);
ra->cfra = 0;
}
}
delete_nr_ue_data(UE, nr_mac->common_channels, &UE_info->uid_allocator);
}
@@ -2729,7 +2740,7 @@ void nr_csirs_scheduling(int Mod_idP, frame_t frame, sub_frame_t slot, int n_slo
if (UE_info->sched_csirs & (1 << dl_bwp->bwp_id))
continue;
NR_UE_sched_ctrl_t *sched_ctrl = &UE->UE_sched_ctrl;
if (sched_ctrl->rrc_processing_timer > 0) {
if ((sched_ctrl->rrc_processing_timer > 0) || sched_ctrl->transmission_stop) {
continue;
}
@@ -3010,6 +3021,13 @@ int nr_mac_enable_ue_rrc_processing_timer(gNB_MAC_INST *mac, NR_UE_info_t *UE, b
return 0;
}
int nr_transmission_action_indicator_stop(NR_UE_info_t *UE_info)
{
UE_info->UE_sched_ctrl.transmission_stop = true;
LOG_I(NR_MAC, "gNB-DU received the TransmissionActionIndicator with Stop value for UE %04x\n", UE_info->rnti);
return 0;
}
void nr_mac_release_ue(gNB_MAC_INST *mac, int rnti)
{
NR_SCHED_ENSURE_LOCKED(&mac->sched_lock);

View File

@@ -532,7 +532,8 @@ void nr_schedule_srs(int module_id, frame_t frame, int slot)
sched_ctrl->sched_srs.srs_scheduled = false;
}
if ((sched_ctrl->ul_failure && !get_softmodem_params()->phy_test) || sched_ctrl->rrc_processing_timer > 0) {
if ((sched_ctrl->ul_failure && !get_softmodem_params()->phy_test) ||
sched_ctrl->rrc_processing_timer > 0 || sched_ctrl->transmission_stop) {
continue;
}

View File

@@ -223,7 +223,8 @@ void nr_csi_meas_reporting(int Mod_idP,
NR_UE_sched_ctrl_t *sched_ctrl = &UE->UE_sched_ctrl;
NR_UE_UL_BWP_t *ul_bwp = &UE->current_UL_BWP;
const int n_slots_frame = nr_slots_per_frame[ul_bwp->scs];
if ((sched_ctrl->rrc_processing_timer > 0) || (sched_ctrl->ul_failure && !get_softmodem_params()->phy_test)) {
if ((sched_ctrl->rrc_processing_timer > 0) || sched_ctrl->transmission_stop ||
(sched_ctrl->ul_failure && !get_softmodem_params()->phy_test)) {
continue;
}
const NR_CSI_MeasConfig_t *csi_measconfig = UE->sc_info.csi_MeasConfig;
@@ -1370,7 +1371,7 @@ void nr_sr_reporting(gNB_MAC_INST *nrmac, frame_t SFN, sub_frame_t slot)
NR_UE_sched_ctrl_t *sched_ctrl = &UE->UE_sched_ctrl;
NR_UE_UL_BWP_t *ul_bwp = &UE->current_UL_BWP;
const int n_slots_frame = nr_slots_per_frame[ul_bwp->scs];
if (sched_ctrl->ul_failure || sched_ctrl->rrc_processing_timer > 0)
if (sched_ctrl->ul_failure || sched_ctrl->rrc_processing_timer > 0 || sched_ctrl->transmission_stop)
continue;
NR_PUCCH_Config_t *pucch_Config = ul_bwp->pucch_Config;

View File

@@ -1804,7 +1804,7 @@ static void pf_ul(module_id_t module_id,
const bool do_sched = nr_UE_is_to_be_scheduled(scc, 0, UE, sched_pusch->frame, sched_pusch->slot, nrmac->ulsch_max_frame_inactivity);
LOG_D(NR_MAC,"pf_ul: do_sched UE %04x => %s\n",UE->rnti,do_sched ? "yes" : "no");
if ((B == 0 && !do_sched) || (sched_ctrl->rrc_processing_timer > 0)) {
if ((B == 0 && !do_sched) || (sched_ctrl->rrc_processing_timer > 0) || sched_ctrl->transmission_stop) {
continue;
}

View File

@@ -53,6 +53,7 @@ bool nr_mac_prepare_ra_ue(gNB_MAC_INST *nrmac, uint32_t rnti, NR_CellGroupConfig
bool nr_mac_prepare_cellgroup_update(gNB_MAC_INST *nrmac, NR_UE_info_t *UE, NR_CellGroupConfig_t *CellGroup);
int nr_mac_enable_ue_rrc_processing_timer(gNB_MAC_INST *mac, NR_UE_info_t *UE, bool apply_cellGroup);
int nr_transmission_action_indicator_stop(NR_UE_info_t *UE_info);
void clear_nr_nfapi_information(gNB_MAC_INST *gNB,
int CC_idP,

View File

@@ -26,11 +26,13 @@
#include "openair2/F1AP/f1ap_common.h"
#include "openair2/LAYER2/nr_rlc/nr_rlc_oai_api.h"
#include "F1AP_CauseRadioNetwork.h"
#include "NR_HandoverCommand.h"
#include "openair3/ocp-gtpu/gtp_itf.h"
#include "openair2/LAYER2/nr_pdcp/nr_pdcp_oai_api.h"
#include "uper_decoder.h"
#include "uper_encoder.h"
#include "SIMULATION/TOOLS/sim.h"
// Standarized 5QI values and Default Priority levels as mentioned in 3GPP TS 23.501 Table 5.7.4-1
const uint64_t qos_fiveqi[26] = {1, 2, 3, 4, 65, 66, 67, 71, 72, 73, 74, 76, 5, 6, 7, 8, 9, 69, 70, 79, 80, 82, 83, 84, 85, 86};
@@ -161,11 +163,19 @@ static int handle_ue_context_srbs_setup(NR_UE_info_t *UE,
for (int i = 0; i < srbs_len; i++) {
const f1ap_srb_to_be_setup_t *srb = &req_srbs[i];
NR_RLC_BearerConfig_t *rlc_BearerConfig = get_bearerconfig_from_srb(srb);
nr_rlc_add_srb(UE->rnti, srb->srb_id, rlc_BearerConfig);
int priority = rlc_BearerConfig->mac_LogicalChannelConfig->ul_SpecificParameters->priority;
nr_lc_config_t c = {.lcid = rlc_BearerConfig->logicalChannelIdentity, .priority = priority};
nr_mac_add_lcid(&UE->UE_sched_ctrl, &c);
rnti_t rnti = UE ? UE->rnti
: cellGroupConfig->spCellConfig && cellGroupConfig->spCellConfig->reconfigurationWithSync
? cellGroupConfig->spCellConfig->reconfigurationWithSync->newUE_Identity
: 0;
AssertFatal(rnti > 0, "Invalid RNTI\n");
nr_rlc_add_srb(rnti, srb->srb_id, rlc_BearerConfig);
if (UE) {
int priority = rlc_BearerConfig->mac_LogicalChannelConfig->ul_SpecificParameters->priority;
nr_lc_config_t c = {.lcid = rlc_BearerConfig->logicalChannelIdentity, .priority = priority};
nr_mac_add_lcid(&UE->UE_sched_ctrl, &c);
}
(*resp_srbs)[i] = *srb;
@@ -227,16 +237,24 @@ static int handle_ue_context_drbs_setup(NR_UE_info_t *UE,
const f1ap_drb_to_be_setup_t *drb = &req_drbs[i];
f1ap_drb_to_be_setup_t *resp_drb = &(*resp_drbs)[i];
NR_RLC_BearerConfig_t *rlc_BearerConfig = get_bearerconfig_from_drb(drb);
nr_rlc_add_drb(UE->rnti, drb->drb_id, rlc_BearerConfig);
nr_lc_config_t c = {.lcid = rlc_BearerConfig->logicalChannelIdentity, .nssai = drb->nssai};
int prio = 100;
for (int q = 0; q < drb->drb_info.flows_to_be_setup_length; ++q) {
c.qos_config[q] = get_qos_config(&drb->drb_info.flows_mapped_to_drb[q].qos_params.qos_characteristics);
prio = min(prio, c.qos_config[q].priority);
rnti_t rnti = UE ? UE->rnti
: cellGroupConfig->spCellConfig && cellGroupConfig->spCellConfig->reconfigurationWithSync
? cellGroupConfig->spCellConfig->reconfigurationWithSync->newUE_Identity
: 0;
AssertFatal(rnti > 0, "Invalid RNTI\n");
nr_rlc_add_drb(rnti, drb->drb_id, rlc_BearerConfig);
if (UE) {
nr_lc_config_t c = {.lcid = rlc_BearerConfig->logicalChannelIdentity, .nssai = drb->nssai};
int prio = 100;
for (int q = 0; q < drb->drb_info.flows_to_be_setup_length; ++q) {
c.qos_config[q] = get_qos_config(&drb->drb_info.flows_mapped_to_drb[q].qos_params.qos_characteristics);
prio = min(prio, c.qos_config[q].priority);
}
c.priority = prio;
nr_mac_add_lcid(&UE->UE_sched_ctrl, &c);
}
c.priority = prio;
nr_mac_add_lcid(&UE->UE_sched_ctrl, &c);
*resp_drb = *drb;
// just put same number of tunnels in DL as in UL
@@ -247,7 +265,7 @@ static int handle_ue_context_drbs_setup(NR_UE_info_t *UE,
int qfi = -1; // don't put PDU session marker in GTP
gtpv1u_gnb_create_tunnel_resp_t resp_f1 = {0};
int ret = drb_gtpu_create(f1inst,
UE->rnti,
rnti,
drb->drb_id,
drb->drb_id,
qfi,
@@ -376,9 +394,50 @@ void ue_context_setup_request(const f1ap_ue_context_setup_t *req)
NR_SCHED_LOCK(&mac->sched_lock);
NR_UE_info_t *UE = find_nr_UE(&RC.nrmac[0]->UE_info, req->gNB_DU_ue_id);
AssertFatal(UE, "did not find UE with RNTI %04x, but UE Context Setup Failed not implemented\n", req->gNB_DU_ue_id);
NR_CellGroupConfig_t *new_CellGroup = clone_CellGroupConfig(UE->CellGroup);
NR_CellGroupConfig_t *new_CellGroup = NULL;
if (UE == NULL) {
asn_dec_rval_t dec_rval = uper_decode_complete(NULL,
&asn_DEF_NR_CellGroupConfig,
(void **)&new_CellGroup,
(uint8_t *)req->cu_to_du_rrc_information->ie_extensions->cell_group_config,
(int)req->cu_to_du_rrc_information->ie_extensions->cell_group_config_length);
AssertFatal(dec_rval.code == RC_OK, "could not decode cellGroupConfig\n");
rnti_t newUE_Identity = 0;
if (new_CellGroup->spCellConfig &&
new_CellGroup->spCellConfig->reconfigurationWithSync) {
newUE_Identity = new_CellGroup->spCellConfig->reconfigurationWithSync->newUE_Identity;
} else {
newUE_Identity = (taus() % 65518) + 1;
}
if (new_CellGroup->spCellConfig && new_CellGroup->spCellConfig->reconfigurationWithSync) {
NR_ServingCellConfigCommon_t *scc = mac->common_channels[0].ServingCellConfigCommon;
asn_copy(&asn_DEF_NR_ServingCellConfigCommon,
(void **)&new_CellGroup->spCellConfig->reconfigurationWithSync->spCellConfigCommon,
scc);
}
resp.crnti = calloc(1, sizeof(uint16_t));
*resp.crnti = newUE_Identity;
resp.gNB_DU_ue_id = newUE_Identity;
asn_set_empty(&new_CellGroup->rlc_BearerToAddModList->list);
new_CellGroup->rlc_BearerToAddModList->list.count = 0;
if (!du_exists_f1_ue_data(resp.gNB_DU_ue_id)) {
LOG_I(NR_MAC, "No CU UE ID stored for UE RNTI %04x, adding CU UE ID %d\n", resp.gNB_DU_ue_id, resp.gNB_CU_ue_id);
f1_ue_data_t new_ue_data = {.secondary_ue = resp.gNB_CU_ue_id};
du_add_f1_ue_data(resp.gNB_DU_ue_id, &new_ue_data);
}
nr_mac_prepare_ra_ue(mac, newUE_Identity, new_CellGroup);
} else {
new_CellGroup = clone_CellGroupConfig(UE->CellGroup);
}
if (req->srbs_to_be_setup_length > 0) {
resp.srbs_to_be_setup_length = handle_ue_context_srbs_setup(UE,
@@ -401,9 +460,9 @@ void ue_context_setup_request(const f1ap_ue_context_setup_t *req)
nr_rlc_srb_recv_sdu(req->gNB_DU_ue_id, id, req->rrc_container, req->rrc_container_length);
}
UE->capability = ue_cap;
if (ue_cap != NULL) {
// store the new UE capabilities, and update the cellGroupConfig
UE->capability = ue_cap;
NR_ServingCellConfigCommon_t *scc = mac->common_channels[0].ServingCellConfigCommon;
update_cellGroupConfig(new_CellGroup, UE->uid, UE->capability, &mac->radio_config, scc);
}
@@ -417,7 +476,8 @@ void ue_context_setup_request(const f1ap_ue_context_setup_t *req)
AssertFatal(enc_rval.encoded > 0, "Could not encode CellGroup, failed element %s\n", enc_rval.failed_type->name);
resp.du_to_cu_rrc_information->cellGroupConfig_length = (enc_rval.encoded + 7) >> 3;
nr_mac_prepare_cellgroup_update(mac, UE, new_CellGroup);
if (UE != NULL)
nr_mac_prepare_cellgroup_update(mac, UE, new_CellGroup);
NR_SCHED_UNLOCK(&mac->sched_lock);
@@ -485,7 +545,31 @@ void ue_context_modification_request(const f1ap_ue_context_modif_req_t *req)
if (req->rrc_container != NULL) {
logical_chan_id_t id = 1;
nr_rlc_srb_recv_sdu(req->gNB_DU_ue_id, id, req->rrc_container, req->rrc_container_length);
NR_HandoverCommand_t *ho_command = NULL;
asn_dec_rval_t dec_rval = uper_decode(NULL,
&asn_DEF_NR_HandoverCommand,
(void **)&ho_command,
req->rrc_container,
req->rrc_container_length,
0,
0);
if (dec_rval.code == RC_OK && ho_command->criticalExtensions.present == NR_HandoverCommand__criticalExtensions_PR_c1
&& ho_command->criticalExtensions.choice.c1->present == NR_HandoverCommand__criticalExtensions__c1_PR_handoverCommand) {
if (LOG_DEBUGFLAG(DEBUG_ASN1)) {
xer_fprint(stdout, &asn_DEF_NR_HandoverCommand, ho_command);
}
OCTET_STRING_t *handoverCommandMessage =
&ho_command->criticalExtensions.choice.c1->choice.handoverCommand->handoverCommandMessage;
// handoverCommandMessage->buf contains the RRCReconfiguration
nr_rlc_srb_recv_sdu(req->gNB_DU_ue_id, id, handoverCommandMessage->buf, handoverCommandMessage->size);
nr_mac_enable_ue_rrc_processing_timer(mac, UE, UE->apply_cellgroup);
} else {
nr_rlc_srb_recv_sdu(req->gNB_DU_ue_id, id, req->rrc_container, req->rrc_container_length);
}
}
if (req->ReconfigComplOutcome != RRCreconf_info_not_present && req->ReconfigComplOutcome != RRCreconf_success) {
@@ -520,6 +604,10 @@ void ue_context_modification_request(const f1ap_ue_context_modif_req_t *req)
} else {
ASN_STRUCT_FREE(asn_DEF_NR_CellGroupConfig, new_CellGroup); // we actually don't need it
}
if (req->transmission_action_indicator != NULL) {
nr_transmission_action_indicator_stop(UE);
}
NR_SCHED_UNLOCK(&mac->sched_lock);
/* some sanity checks, since we use the same type for request and response */

View File

@@ -161,6 +161,10 @@ static void ue_context_setup_response_f1ap(const f1ap_ue_context_setup_t *req, c
for (int i = 0; i < f1ap_msg->drbs_to_be_setup_length; ++i)
f1ap_msg->drbs_to_be_setup[i] = resp->drbs_to_be_setup[i];
}
if (resp->crnti) {
f1ap_msg->crnti = calloc(1, sizeof(uint16_t));
*f1ap_msg->crnti = *resp->crnti;
}
f1ap_msg->du_to_cu_rrc_information = malloc(sizeof(*resp->du_to_cu_rrc_information));
AssertFatal(f1ap_msg->du_to_cu_rrc_information != NULL, "out of memory\n");

View File

@@ -648,6 +648,9 @@ typedef struct {
/// per-LC configuration
seq_arr_t lc_config;
/// Stop transmission when gNB-DU receives the transmission action indicator with value Stop
bool transmission_stop;
} NR_UE_sched_ctrl_t;
typedef struct {

View File

@@ -80,6 +80,7 @@
#include "NR_PCCH-Message.h"
#include "NR_PagingRecord.h"
#include "NR_UE-CapabilityRequestFilterNR.h"
#include "NR_HandoverCommand.h"
#include "common/utils/nr/nr_common.h"
#if defined(NR_Rel16)
#include "NR_SCS-SpecificCarrier.h"
@@ -1372,3 +1373,25 @@ int do_NR_Paging(uint8_t Mod_id, uint8_t *buffer, uint32_t tmsi)
return((enc_rval.encoded+7)/8);
}
int16_t do_NR_HandoverCommand(uint8_t *ho_buf, int16_t ho_size, uint8_t *rrc_buffer, int16_t rrc_size)
{
NR_HandoverCommand_t *ho_command = calloc(1, sizeof(NR_HandoverCommand_t));
ho_command->criticalExtensions.present = NR_HandoverCommand__criticalExtensions_PR_c1;
ho_command->criticalExtensions.choice.c1 = calloc(1, sizeof(struct NR_HandoverCommand__criticalExtensions__c1));
ho_command->criticalExtensions.choice.c1->present = NR_HandoverCommand__criticalExtensions__c1_PR_handoverCommand;
ho_command->criticalExtensions.choice.c1->choice.handoverCommand = calloc(1, sizeof(struct NR_HandoverCommand_IEs));
AssertFatal(OCTET_STRING_fromBuf(&ho_command->criticalExtensions.choice.c1->choice.handoverCommand->handoverCommandMessage,
(char *)rrc_buffer, rrc_size) != -1, "fatal: OCTET_STRING_fromBuf failed\n");
if (LOG_DEBUGFLAG(DEBUG_ASN1)) {
xer_fprint(stdout, &asn_DEF_NR_HandoverCommand, ho_command);
}
asn_enc_rval_t enc_rval = uper_encode_to_buffer(&asn_DEF_NR_HandoverCommand, NULL, ho_command, ho_buf, ho_size);
AssertFatal(enc_rval.encoded > 0, "ASN1 message encoding failed (%s, %lu)!\n", enc_rval.failed_type->name, enc_rval.encoded);
return ((enc_rval.encoded + 7) / 8);
}

View File

@@ -106,6 +106,8 @@ int do_RRCReconfiguration(const gNB_RRC_UE_t *UE,
struct NR_RRCReconfiguration_v1530_IEs__dedicatedNAS_MessageList *dedicatedNAS_MessageList,
NR_CellGroupConfig_t *cellGroupConfig);
int16_t do_NR_HandoverCommand(uint8_t *ho_buf, int16_t ho_size, uint8_t *rrc_buffer, int16_t rrc_size);
int do_RRCSetupComplete(uint8_t *buffer,
size_t buffer_size,
const uint8_t Transaction_id,

View File

@@ -73,6 +73,17 @@ static void ue_context_setup_request_f1ap(sctp_assoc_t assoc_id, const f1ap_ue_c
AssertFatal(du2cu_new->uE_CapabilityRAT_ContainerList != NULL, "out of memory\n");
memcpy(du2cu_new->uE_CapabilityRAT_ContainerList, du2cu_req->uE_CapabilityRAT_ContainerList, du2cu_new->uE_CapabilityRAT_ContainerList_length);
}
if (req->cu_to_du_rrc_information->ie_extensions != NULL && req->cu_to_du_rrc_information->ie_extensions->cell_group_config != NULL) {
const cu_to_du_rrc_information_t *du2cu_req = req->cu_to_du_rrc_information;
cu_to_du_rrc_information_t *du2cu_new = f1ap_msg->cu_to_du_rrc_information;
du2cu_new->ie_extensions = calloc(1, sizeof(protocol_extension_container_t));
AssertFatal(du2cu_new->ie_extensions != NULL, "out of memory\n");
DevAssert(du2cu_req->ie_extensions->cell_group_config_length > 0);
du2cu_new->ie_extensions->cell_group_config_length = du2cu_req->ie_extensions->cell_group_config_length;
du2cu_new->ie_extensions->cell_group_config = malloc(du2cu_new->ie_extensions->cell_group_config_length);
AssertFatal(du2cu_new->ie_extensions->cell_group_config != NULL, "out of memory\n");
memcpy(du2cu_new->ie_extensions->cell_group_config, du2cu_req->ie_extensions->cell_group_config, du2cu_new->ie_extensions->cell_group_config_length);
}
}
if (req->drbs_to_be_setup_length > 0) {
int n = req->drbs_to_be_setup_length;

View File

@@ -144,21 +144,14 @@ typedef struct nr_e_rab_param_s {
} __attribute__ ((__packed__)) nr_e_rab_param_t;
typedef struct HANDOVER_INFO_NR_s {
uint8_t ho_prepare;
uint8_t ho_complete;
uint8_t modid_s; //module_idP of serving cell
uint8_t modid_t; //module_idP of target cell
uint8_t ueid_s; //UE index in serving cell
uint8_t ueid_t; //UE index in target cell
// NR not define at this moment
//AS_Config_t as_config; /* these two parameters are taken from 36.331 section 10.2.2: HandoverPreparationInformation-r8-IEs */
//AS_Context_t as_context; /* They are mandatory for HO */
uint8_t buf[RRC_BUF_SIZE]; /* ASN.1 encoded handoverCommandMessage */
int size; /* size of above message in bytes */
} NR_HANDOVER_INFO;
typedef struct nr_handover_info_s {
bool location_ho_timer_active;
int location_ho_timer;
rnti_t source_rnti;
rnti_t target_rnti;
sctp_assoc_t source_assoc_id;
sctp_assoc_t target_assoc_id;
} nr_handover_info_t;
#define NR_RRC_BUFFER_SIZE sizeof(RRC_BUFFER_NR)
@@ -257,7 +250,7 @@ typedef struct gNB_RRC_UE_s {
NR_SRB_INFO_TABLE_ENTRY Srb[NR_NUM_SRB];
NR_MeasConfig_t *measConfig;
NR_HANDOVER_INFO *handover_info;
nr_handover_info_t handover_info;
NR_MeasResults_t *measResults;
bool as_security_active;
@@ -453,10 +446,13 @@ typedef struct gNB_RRC_INST_s {
// RRC configuration
gNB_RrcConfigurationReq configuration;
f1ap_drb_to_be_setup_t drbs[32];
// gNB N3 GTPU instance
instance_t e1_inst;
int location_ho_trigger;
char *uecap_file;
// security configuration (preferred algorithms)

View File

@@ -192,6 +192,15 @@ static void rrc_deliver_dl_rrc_message(void *deliver_pdu_data, ue_id_t ue_id, in
data->rrc->mac_rrc.dl_rrc_message_transfer(data->assoc_id, data->dl_rrc);
}
static void nr_rrc_prepare_protected_rrc_message(void *deliver_pdu_data, ue_id_t ue_id, int srb_id, char *buf, int size, int sdu_id)
{
DevAssert(deliver_pdu_data != NULL);
deliver_dl_rrc_message_data_t *data = (deliver_dl_rrc_message_data_t *)deliver_pdu_data;
data->dl_rrc->rrc_container_length = size;
memcpy(data->dl_rrc->rrc_container, buf, size);
DevAssert(data->dl_rrc->srb_id == srb_id);
}
void nr_rrc_transfer_protected_rrc_message(const gNB_RRC_INST *rrc,
const gNB_RRC_UE_t *ue_p,
uint8_t srb_id,
@@ -265,6 +274,162 @@ static void rrc_gNB_CU_DU_init(gNB_RRC_INST *rrc)
cu_init_f1_ue_data();
}
static uint64_t get_ssb_bitmap_from_SIB1(const NR_SIB1_t *sib1)
{
return ((uint64_t)sib1->servingCellConfigCommon->ssb_PositionsInBurst.inOneGroup.buf[0]) << 56;
}
static rnti_t get_new_rnti(gNB_RRC_INST *rrc)
{
rnti_t rnti;
do {
rnti = (taus() % 65518) + 1;
} while (rrc_gNB_get_ue_context(rrc, rnti) != NULL);
return rnti;
}
void nr_HO_trigger(gNB_RRC_INST *rrc, rrc_gNB_ue_context_t *ue_context_pP, nr_rrc_du_container_t *du)
{
LOG_I(NR_RRC, "Handover triggered\n");
// The gNB-CU sends a UE CONTEXT SETUP REQUEST message to the target gNB-DU to create a UE context and setup
// SRBs and DRBs bearers
// Handover information
gNB_RRC_UE_t *ue_p = &ue_context_pP->ue_context;
nr_rrc_du_container_t *target_du = find_target_du(rrc, du->assoc_id);
if (target_du == NULL) {
LOG_E(NR_RRC, "Target gNB-DU not found. Handover aborted.\n");
return;
}
if (!ue_p->masterCellGroup || !ue_p->masterCellGroup->spCellConfig) {
LOG_E(NR_RRC, "CellGroupConfig or SpCellConfig not found. Handover aborted.\n");
return;
}
ue_p->StatusRrc = NR_RRC_HO_EXECUTION;
ue_p->handover_info.source_assoc_id = du->assoc_id;
ue_p->handover_info.source_rnti = ue_p->rnti;
ue_p->handover_info.target_assoc_id = target_du->assoc_id;
ue_p->handover_info.target_rnti = get_new_rnti(rrc);
// ReconfigurationWithSync
if (ue_p->masterCellGroup->spCellConfig->reconfigurationWithSync == NULL) {
ue_p->masterCellGroup->spCellConfig->reconfigurationWithSync =
calloc(1, sizeof(*ue_p->masterCellGroup->spCellConfig->reconfigurationWithSync));
}
NR_ReconfigurationWithSync_t *reconfigurationWithSync = ue_p->masterCellGroup->spCellConfig->reconfigurationWithSync;
reconfigurationWithSync->newUE_Identity = ue_p->handover_info.target_rnti;
reconfigurationWithSync->t304 = NR_ReconfigurationWithSync__t304_ms2000;
reconfigurationWithSync->rach_ConfigDedicated = NULL;
reconfigurationWithSync->ext1 = NULL;
if (ue_p->masterCellGroup->spCellConfig->reconfigurationWithSync->rach_ConfigDedicated == NULL) {
ue_p->masterCellGroup->spCellConfig->reconfigurationWithSync->rach_ConfigDedicated =
calloc(1, sizeof(struct NR_ReconfigurationWithSync__rach_ConfigDedicated));
}
struct NR_ReconfigurationWithSync__rach_ConfigDedicated *rach_ConfigDedicated =
ue_p->masterCellGroup->spCellConfig->reconfigurationWithSync->rach_ConfigDedicated;
rach_ConfigDedicated->present = NR_ReconfigurationWithSync__rach_ConfigDedicated_PR_uplink;
if (rach_ConfigDedicated->choice.uplink == NULL) {
rach_ConfigDedicated->choice.uplink = calloc(1, sizeof(struct NR_RACH_ConfigDedicated));
}
rach_ConfigDedicated->choice.uplink->ra_Prioritization = NULL;
rach_ConfigDedicated->choice.uplink->ext1 = NULL;
if (rach_ConfigDedicated->choice.uplink->cfra == NULL) {
rach_ConfigDedicated->choice.uplink->cfra = calloc(1, sizeof(struct NR_CFRA));
}
struct NR_CFRA *cfra = rach_ConfigDedicated->choice.uplink->cfra;
if (cfra->occasions == NULL) {
cfra->occasions = calloc(1, sizeof(struct NR_CFRA__occasions));
}
memcpy(&reconfigurationWithSync->rach_ConfigDedicated->choice.uplink->cfra->occasions->rach_ConfigGeneric,
&du->sib1->servingCellConfigCommon->uplinkConfigCommon->initialUplinkBWP.rach_ConfigCommon->choice.setup->rach_ConfigGeneric,
sizeof(NR_RACH_ConfigGeneric_t));
if (cfra->occasions->ssb_perRACH_Occasion == NULL) {
cfra->occasions->ssb_perRACH_Occasion = calloc(1, sizeof(long));
}
*cfra->occasions->ssb_perRACH_Occasion = NR_CFRA__occasions__ssb_perRACH_Occasion_one;
cfra->resources.present = NR_CFRA__resources_PR_ssb;
if (cfra->resources.choice.ssb == NULL) {
cfra->resources.choice.ssb = calloc(1, sizeof(struct NR_CFRA__resources__ssb));
}
cfra->resources.choice.ssb->ra_ssb_OccasionMaskIndex = 0;
int n_ssb = 0;
uint64_t bitmap = get_ssb_bitmap_from_SIB1(du->sib1); // TODO: Is this right?
struct NR_CFRA_SSB_Resource *ssbElem[64];
for (int i = 0; i < 64; i++) {
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 - (taus() % 64);
ASN_SEQUENCE_ADD(&cfra->resources.choice.ssb->ssb_ResourceList.list, ssbElem[n_ssb]);
n_ssb++;
}
}
cu_to_du_rrc_information_t cu2du = {0};
cu2du.ie_extensions = calloc(1, sizeof(protocol_extension_container_t));
cu2du.ie_extensions->cell_group_config = calloc(1, 4096);
asn_enc_rval_t enc_rval =
uper_encode_to_buffer(&asn_DEF_NR_CellGroupConfig, NULL, ue_p->masterCellGroup, cu2du.ie_extensions->cell_group_config, 4096);
AssertFatal(enc_rval.encoded > 0,
"ASN1 NR_CellGroupConfig encoding failed (%s, %jd)!\n",
enc_rval.failed_type->name,
enc_rval.encoded);
cu2du.ie_extensions->cell_group_config_length = (enc_rval.encoded + 7) >> 3;
// SRBs
f1ap_srb_to_be_setup_t srbs[2] = {{.srb_id = 1, .lcid = 1}, {.srb_id = 2, .lcid = 2}};
// The callback will fill the UE context setup request and forward it
f1_ue_data_t ue_data = cu_get_f1_ue_data(ue_p->rrc_ue_id);
f1ap_served_cell_info_t *cell_info = &target_du->setup_req->cell[0].info;
RETURN_IF_INVALID_ASSOC_ID(ue_data);
f1ap_ue_context_setup_t ue_context_setup_req = {
.gNB_CU_ue_id = ue_p->rrc_ue_id,
.gNB_DU_ue_id = reconfigurationWithSync->newUE_Identity,
.plmn.mcc = cell_info->plmn.mcc,
.plmn.mnc = cell_info->plmn.mnc,
.plmn.mnc_digit_length = cell_info->plmn.mnc_digit_length,
.nr_cellid = cell_info->nr_cellid,
.servCellId = 0, // TODO: correct value?
.srbs_to_be_setup_length = 2,
.srbs_to_be_setup = srbs,
.drbs_to_be_setup_length = 1,
.drbs_to_be_setup = (f1ap_drb_to_be_setup_t *)&rrc->drbs[0],
.cu_to_du_rrc_information = &cu2du,
};
rrc->mac_rrc.ue_context_setup_request(ue_p->handover_info.target_assoc_id, &ue_context_setup_req);
}
void nr_rrc_update_ho_timer(gNB_RRC_INST *rrc)
{
rrc_gNB_ue_context_t *ue_context_p = NULL;
// Cast is necessary to eliminate warning "discards const qualifier
RB_FOREACH (ue_context_p, rrc_nr_ue_tree_s, &((gNB_RRC_INST *)rrc)->rrc_ue_head) {
gNB_RRC_UE_t *ue_p = &ue_context_p->ue_context;
if (ue_p->handover_info.location_ho_timer_active) {
nr_rrc_du_container_t *du = get_du_for_ue(rrc, ue_p->rrc_ue_id);
const f1ap_setup_req_t *sr = du->setup_req;
LOG_W(NR_RRC, "[DU %lx] LOCATION-BASED TRIGGER TIMER = %2i\n", sr->gNB_DU_id, ue_p->handover_info.location_ho_timer);
ue_p->handover_info.location_ho_timer--;
if (ue_p->handover_info.location_ho_timer == 0) {
ue_p->handover_info.location_ho_timer_active = false;
nr_HO_trigger(rrc, ue_context_p, du);
}
} else {
ue_p->handover_info.location_ho_timer_active = true;
ue_p->handover_info.location_ho_timer = rrc->location_ho_trigger;
}
}
}
void openair_rrc_gNB_configuration(gNB_RRC_INST *rrc, gNB_RrcConfigurationReq *configuration)
{
AssertFatal(rrc != NULL, "RC.nrrrc not initialized!");
@@ -536,7 +701,7 @@ void rrc_gNB_generate_dedicatedRRCReconfiguration(const protocol_ctxt_t *const c
NR_CellGroupConfig_t *cellGroupConfig = ue_p->masterCellGroup;
const nr_rrc_du_container_t *du = get_du_for_ue(rrc, ue_p->rrc_ue_id);
nr_rrc_du_container_t *du = get_du_for_ue(rrc, ue_p->rrc_ue_id);
DevAssert(du != NULL);
f1ap_served_cell_info_t *cell_info = &du->setup_req->cell[0].info;
NR_MeasConfig_t *measconfig = NULL;
@@ -591,7 +756,43 @@ void rrc_gNB_generate_dedicatedRRCReconfiguration(const protocol_ctxt_t *const c
ctxt_pP->module_id,
DCCH);
nr_rrc_transfer_protected_rrc_message(rrc, ue_p, DCCH, buffer, size);
if (ue_p->StatusRrc == NR_RRC_HO_EXECUTION) {
f1_ue_data_t ue_data = cu_get_f1_ue_data(ue_p->rrc_ue_id);
uint8_t rrc_container[RRC_BUF_SIZE] = {0};
f1ap_dl_rrc_message_t dl_rrc = {.gNB_CU_ue_id = ue_p->rrc_ue_id, .gNB_DU_ue_id = ue_data.secondary_ue, .srb_id = DCCH, .rrc_container = rrc_container};
deliver_dl_rrc_message_data_t data = {.rrc = rrc, .dl_rrc = &dl_rrc, .assoc_id = ue_data.du_assoc_id};
nr_pdcp_data_req_srb(ue_p->rrc_ue_id,
DCCH,
rrc_gNB_mui++,
size,
(unsigned char *const)buffer,
nr_rrc_prepare_protected_rrc_message,
&data);
uint8_t ho_buffer[RRC_BUF_SIZE] = {0};
int16_t ho_size = do_NR_HandoverCommand(ho_buffer, RRC_BUF_SIZE, data.dl_rrc->rrc_container, data.dl_rrc->rrc_container_length);
uint8_t transmission_action_indicator = 0;
RETURN_IF_INVALID_ASSOC_ID(ue_data);
f1ap_ue_context_modif_req_t ue_context_modif_req = {
.gNB_CU_ue_id = ue_p->rrc_ue_id,
.gNB_DU_ue_id = ue_data.secondary_ue,
.plmn.mcc = rrc->configuration.mcc[0],
.plmn.mnc = rrc->configuration.mnc[0],
.plmn.mnc_digit_length = rrc->configuration.mnc_digit_length[0],
.nr_cellid = rrc->nr_cellid,
.servCellId = 0, // TODO: correct value?
.ReconfigComplOutcome = RRCreconf_success,
.transmission_action_indicator = &transmission_action_indicator,
.rrc_container_length = ho_size,
.rrc_container = ho_buffer,
};
rrc->mac_rrc.ue_context_modification_request(ue_data.du_assoc_id, &ue_context_modif_req);
} else {
nr_rrc_transfer_protected_rrc_message(rrc, ue_p, DCCH, buffer, size);
}
}
//-----------------------------------------------------------------------------
@@ -1611,6 +1812,24 @@ static void handle_rrcReconfigurationComplete(const protocol_ctxt_t *const ctxt_
LOG_I(RRC, "UE %d: transaction %d still ongoing for action %d\n", UE->rrc_ue_id, i, UE->xids[i]);
}
}
if (UE->StatusRrc == NR_RRC_HO_EXECUTION) {
gNB_RRC_INST *rrc = RC.nrrrc[ctxt_pP->module_id];
f1_ue_data_t ue_data = cu_get_f1_ue_data(UE->rrc_ue_id);
RETURN_IF_INVALID_ASSOC_ID(ue_data);
f1ap_ue_context_release_cmd_t ue_context_release_cmd = {
.gNB_CU_ue_id = UE->rrc_ue_id,
.gNB_DU_ue_id = UE->handover_info.source_rnti,
.cause = F1AP_CAUSE_RADIO_NETWORK,
.cause_value = 10, // 10 = F1AP_CauseRadioNetwork_normal_release
.srb_id = DCCH,
};
rrc->mac_rrc.ue_context_release_command(UE->handover_info.source_assoc_id, &ue_context_release_cmd);
UE->rnti = UE->handover_info.target_rnti;
UE->StatusRrc = NR_RRC_CONNECTED;
memset(&UE->handover_info, 0, sizeof(UE->handover_info));
}
}
//-----------------------------------------------------------------------------
int rrc_gNB_decode_dcch(const protocol_ctxt_t *const ctxt_pP,
@@ -1989,7 +2208,8 @@ static void rrc_CU_process_ue_context_release_complete(MessageDef *msg_p)
return;
}
rrc_remove_ue(RC.nrrrc[0], ue_context_p);
if (complete->gNB_DU_ue_id == ue_context_p->ue_context.rnti)
rrc_remove_ue(RC.nrrrc[0], ue_context_p);
}
static void rrc_CU_process_ue_context_modification_response(MessageDef *msg_p, instance_t instance)
@@ -2025,6 +2245,15 @@ static void rrc_CU_process_ue_context_modification_response(MessageDef *msg_p, i
rrc_gNB_generate_dedicatedRRCReconfiguration(&ctxt, ue_context_p);
}
// Update with new RNTI, and update secondary UE association
if (UE->StatusRrc == NR_RRC_HO_EXECUTION) {
f1_ue_data_t ue_data = cu_get_f1_ue_data(UE->rrc_ue_id);
ue_data.secondary_ue = UE->handover_info.target_rnti;
ue_data.du_assoc_id = UE->handover_info.target_assoc_id;
cu_remove_f1_ue_data(UE->rrc_ue_id);
cu_add_f1_ue_data(UE->rrc_ue_id, &ue_data);
}
}
static void rrc_CU_process_ue_modification_required(MessageDef *msg_p)
@@ -2135,14 +2364,13 @@ void rrc_gNB_process_e1_bearer_context_setup_resp(e1ap_bearer_setup_resp_t *resp
}
/* Instruction towards the DU for DRB configuration and tunnel creation */
f1ap_drb_to_be_setup_t drbs[32]; // maximum DRB can be 32
int nb_drb = 0;
for (int p = 0; p < resp->numPDUSessions; ++p) {
rrc_pdu_session_param_t *RRC_pduSession = find_pduSession(UE, resp->pduSession[p].id, false);
DevAssert(RRC_pduSession);
for (int i = 0; i < resp->pduSession[p].numDRBSetup; i++) {
DRB_nGRAN_setup_t *drb_config = &resp->pduSession[p].DRBnGRanList[i];
f1ap_drb_to_be_setup_t *drb = &drbs[nb_drb];
f1ap_drb_to_be_setup_t *drb = &rrc->drbs[nb_drb];
drb->drb_id = resp->pduSession[p].DRBnGRanList[i].id;
drb->rlc_mode = rrc->configuration.um_on_default_drb ? RLC_MODE_UM : RLC_MODE_AM;
drb->up_ul_tnl[0].tl_address = drb_config->UpParamList[0].tlAddress;
@@ -2186,9 +2414,9 @@ void rrc_gNB_process_e1_bearer_context_setup_resp(e1ap_bearer_setup_resp_t *resp
AssertFatal(UE->as_security_active, "logic bug: security should be active when activating DRBs\n");
if (!UE->f1_ue_context_active)
rrc_gNB_generate_UeContextSetupRequest(rrc, ue_context_p, nb_drb, drbs);
rrc_gNB_generate_UeContextSetupRequest(rrc, ue_context_p, nb_drb, rrc->drbs);
else
rrc_gNB_generate_UeContextModificationRequest(rrc, ue_context_p, nb_drb, drbs, 0, NULL);
rrc_gNB_generate_UeContextModificationRequest(rrc, ue_context_p, nb_drb, rrc->drbs, 0, NULL);
}
/**
@@ -2344,7 +2572,14 @@ void *rrc_gnb_task(void *args_p) {
/* timer to write stats to file */
timer_setup(1, 0, TASK_RRC_GNB, 0, TIMER_PERIODIC, NULL, &stats_timer_id);
}
gNB_RRC_INST *rrc = RC.nrrrc[0];
long ho_timer_id = 2;
if (rrc->node_type == ngran_gNB_CU && rrc->location_ho_trigger > 0) {
// Timer to location-based handover trigger
timer_setup(1, 0, TASK_RRC_GNB, 0, TIMER_PERIODIC, NULL, &ho_timer_id);
}
itti_mark_task_ready(TASK_RRC_GNB);
LOG_I(NR_RRC,"Entering main loop of NR_RRC message task\n");
@@ -2370,8 +2605,11 @@ void *rrc_gnb_task(void *args_p) {
case TIMER_HAS_EXPIRED:
/* only this one handled for now */
DevAssert(TIMER_HAS_EXPIRED(msg_p).timer_id == stats_timer_id);
write_rrc_stats(RC.nrrrc[0]);
DevAssert(TIMER_HAS_EXPIRED(msg_p).timer_id == stats_timer_id || TIMER_HAS_EXPIRED(msg_p).timer_id == ho_timer_id);
if (TIMER_HAS_EXPIRED(msg_p).timer_id == stats_timer_id)
write_rrc_stats(rrc);
else if (TIMER_HAS_EXPIRED(msg_p).timer_id == ho_timer_id)
nr_rrc_update_ho_timer(rrc);
break;
case F1AP_INITIAL_UL_RRC_MESSAGE:

View File

@@ -517,3 +517,31 @@ void dump_du_info(const gNB_RRC_INST *rrc, FILE *f)
}
}
}
nr_rrc_du_container_t *find_target_du(gNB_RRC_INST *rrc, sctp_assoc_t source_assoc_id)
{
nr_rrc_du_container_t *target_du = NULL;
nr_rrc_du_container_t *it = NULL;
bool next_du = false;
RB_FOREACH (it, rrc_du_tree, &rrc->dus) {
if(next_du == false && source_assoc_id != it->assoc_id) {
continue;
} else if (source_assoc_id == it->assoc_id) {
next_du = true;
} else {
target_du = it;
break;
}
}
if (target_du == NULL) {
RB_FOREACH (it, rrc_du_tree, &rrc->dus) {
if (source_assoc_id == it->assoc_id) {
continue;
} else {
target_du = it;
break;
}
}
}
return target_du;
}

View File

@@ -48,4 +48,5 @@ int get_dl_band(const struct f1ap_served_cell_info_t *cell_info);
int get_ssb_scs(const struct f1ap_served_cell_info_t *cell_info);
int get_ssb_arfcn(const struct nr_rrc_du_container_t *du);
struct nr_rrc_du_container_t *find_target_du(struct gNB_RRC_INST_s *rrc, sctp_assoc_t source_assoc_id);
#endif /* RRC_GNB_DU_H_ */

View File

@@ -843,6 +843,15 @@ void nr_rrc_cellgroup_configuration(NR_UE_RRC_INST_t *rrc, NR_CellGroupConfig_t
if (get_DRB_status(rrc, i) == RB_SUSPENDED)
set_DRB_status(rrc, i, RB_ESTABLISHED);
}
if (cellGroupConfig->rlc_BearerToAddModList != NULL) {
for (int i = 0; i < cellGroupConfig->rlc_BearerToAddModList->list.count; i++) {
NR_RLC_BearerConfig_t *rlc_bearer = cellGroupConfig->rlc_BearerToAddModList->list.array[i];
NR_LogicalChannelIdentity_t lcid = rlc_bearer->logicalChannelIdentity;
if (rrc->active_RLC_entity[lcid]) {
nr_rlc_reestablish_entity(rrc->ue_id, lcid);
}
}
}
// TODO reset MAC
}
nr_rrc_handle_SetupRelease_RLF_TimersAndConstants(rrc, spCellConfig->rlf_TimersAndConstants);

View File

@@ -0,0 +1,75 @@
Active_gNBs = ( "cu-rfsim");
# Asn1_verbosity, choice in: none, info, annoying
Asn1_verbosity = "none";
Num_Threads_PUSCH = 8;
gNBs =
(
{
////////// Identification parameters:
gNB_ID = 0xe00;
gNB_name = "cu-rfsim";
// Tracking area code, 0x0000 and 0xfffe are reserved values
tracking_area_code = 1;
plmn_list = ({ mcc = 001; mnc = 01; mnc_length = 2; snssaiList = ({ sst = 1; }) });
nr_cellid = 12345678L;
location_ho_trigger = 600; # in seconds
tr_s_preference = "f1";
local_s_if_name = "lo";
local_s_address = "127.0.0.3";
remote_s_address = "0.0.0.0"; # multiple DUs
local_s_portc = 501;
local_s_portd = 2152;
remote_s_portc = 500;
remote_s_portd = 2152;
# ------- SCTP definitions
SCTP :
{
# Number of streams to use in input/output
SCTP_INSTREAMS = 2;
SCTP_OUTSTREAMS = 2;
};
////////// AMF parameters:
amf_ip_address = ({ ipv4 = "192.168.70.132"; });
NETWORK_INTERFACES :
{
GNB_IPV4_ADDRESS_FOR_NG_AMF = "192.168.70.129/24";
GNB_IPV4_ADDRESS_FOR_NGU = "192.168.70.129/24";
GNB_PORT_FOR_S1U = 2152; # Spec 2152
};
}
);
security = {
# preferred ciphering algorithms
# the first one of the list that an UE supports in chosen
# valid values: nea0, nea1, nea2, nea3
ciphering_algorithms = ( "nea0" );
# preferred integrity algorithms
# the first one of the list that an UE supports in chosen
# valid values: nia0, nia1, nia2, nia3
integrity_algorithms = ( "nia2", "nia0" );
# setting 'drb_ciphering' to "no" disables ciphering for DRBs, no matter
# what 'ciphering_algorithms' configures; same thing for 'drb_integrity'
drb_ciphering = "yes";
drb_integrity = "no";
};
log_config : {
global_log_level = "info";
pdcp_log_level = "info";
rrc_log_level = "info";
f1ap_log_level = "info";
ngap_log_level = "info";
};

View File

@@ -0,0 +1,235 @@
Active_gNBs = ( "du-rfsim");
# Asn1_verbosity, choice in: none, info, annoying
Asn1_verbosity = "none";
gNBs =
(
{
////////// Identification parameters:
gNB_ID = 0xe00;
gNB_DU_ID = 0xe00;
gNB_name = "du-rfsim";
// Tracking area code, 0x0000 and 0xfffe are reserved values
tracking_area_code = 1;
plmn_list = ({ mcc = 001; mnc = 01; mnc_length = 2; snssaiList = ({ sst = 1; }) });
nr_cellid = 12345678L;
////////// Physical parameters:
min_rxtxtime = 4;
sib1_tda = 15;
servingCellConfigCommon = (
{
#spCellConfigCommon
physCellId = 0;
# downlinkConfigCommon
#frequencyInfoDL
# this is 3600 MHz + 43 PRBs@30kHz SCS (same as initial BWP)
absoluteFrequencySSB = 430610;
dl_frequencyBand = 66;
# this is 3600 MHz
dl_absoluteFrequencyPointA = 430000;
#scs-SpecificCarrierList
dl_offstToCarrier = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
dl_subcarrierSpacing = 0;
dl_carrierBandwidth = 25;
#initialDownlinkBWP
#genericParameters
# this is RBstart=27,L=48 (275*(L-1))+RBstart
initialDLBWPlocationAndBandwidth = 6600; # 6366 12925 12956 28875 12952
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
initialDLBWPsubcarrierSpacing = 0;
#pdcch-ConfigCommon
initialDLBWPcontrolResourceSetZero = 0;
initialDLBWPsearchSpaceZero = 0;
#uplinkConfigCommon
#frequencyInfoUL
ul_frequencyBand = 66;
# this is 1750 MHz
ul_absoluteFrequencyPointA = 350000;
#scs-SpecificCarrierList
ul_offstToCarrier = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
ul_subcarrierSpacing = 0;
ul_carrierBandwidth = 25;
pMax = 20;
#initialUplinkBWP
#genericParameters
initialULBWPlocationAndBandwidth = 6600;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
initialULBWPsubcarrierSpacing = 0;
#rach-ConfigCommon
#rach-ConfigGeneric
prach_ConfigurationIndex = 98;
#prach_msg1_FDM
#0 = one, 1=two, 2=four, 3=eight
prach_msg1_FDM = 0;
prach_msg1_FrequencyStart = 0;
zeroCorrelationZoneConfig = 13;
preambleReceivedTargetPower = -96;
#preamblTransMax (0...10) = (3,4,5,6,7,8,10,20,50,100,200)
preambleTransMax = 6;
#powerRampingStep
# 0=dB0,1=dB2,2=dB4,3=dB6
powerRampingStep = 1;
#ra_ReponseWindow
#1,2,4,8,10,20,40,80
ra_ResponseWindow = 4;
#ssb_perRACH_OccasionAndCB_PreamblesPerSSB_PR
#1=oneeighth,2=onefourth,3=half,4=one,5=two,6=four,7=eight,8=sixteen
ssb_perRACH_OccasionAndCB_PreamblesPerSSB_PR = 4;
#oneHalf (0..15) 4,8,12,16,...60,64
ssb_perRACH_OccasionAndCB_PreamblesPerSSB = 15;
#ra_ContentionResolutionTimer
#(0..7) 8,16,24,32,40,48,56,64
ra_ContentionResolutionTimer = 7;
rsrp_ThresholdSSB = 19;
#prach-RootSequenceIndex_PR
#1 = 839, 2 = 139
prach_RootSequenceIndex_PR = 2;
prach_RootSequenceIndex = 1;
# SCS for msg1, can only be 15 for 30 kHz < 6 GHz, takes precendence over the one derived from prach-ConfigIndex
#
msg1_SubcarrierSpacing = 0,
# restrictedSetConfig
# 0=unrestricted, 1=restricted type A, 2=restricted type B
restrictedSetConfig = 0,
msg3_DeltaPreamble = 1;
p0_NominalWithGrant =-90;
# pucch-ConfigCommon setup :
# pucchGroupHopping
# 0 = neither, 1= group hopping, 2=sequence hopping
pucchGroupHopping = 0;
hoppingId = 40;
p0_nominal = -90;
# ssb_PositionsInBurs_BitmapPR
# 1=short, 2=medium, 3=long
ssb_PositionsInBurst_PR = 2;
ssb_PositionsInBurst_Bitmap = 1;
# ssb_periodicityServingCell
# 0 = ms5, 1=ms10, 2=ms20, 3=ms40, 4=ms80, 5=ms160, 6=spare2, 7=spare1
ssb_periodicityServingCell = 2;
# dmrs_TypeA_position
# 0 = pos2, 1 = pos3
dmrs_TypeA_Position = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
subcarrierSpacing = 0;
#tdd-UL-DL-ConfigurationCommon
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
referenceSubcarrierSpacing = 0;
# pattern1
# dl_UL_TransmissionPeriodicity
# 0=ms0p5, 1=ms0p625, 2=ms1, 3=ms1p25, 4=ms2, 5=ms2p5, 6=ms5, 7=ms10
dl_UL_TransmissionPeriodicity = 6;
nrofDownlinkSlots = 7;
nrofDownlinkSymbols = 6;
nrofUplinkSlots = 2;
nrofUplinkSymbols = 4;
ssPBCH_BlockPower = -25;
}
);
# ------- SCTP definitions
SCTP :
{
# Number of streams to use in input/output
SCTP_INSTREAMS = 2;
SCTP_OUTSTREAMS = 2;
};
}
);
MACRLCs = (
{
num_cc = 1;
tr_s_preference = "local_L1";
tr_n_preference = "f1";
local_n_if_name = "lo";
local_n_address = "127.0.0.4";
remote_n_address = "127.0.0.3";
local_n_portc = 500;
local_n_portd = 2152;
remote_n_portc = 501;
remote_n_portd = 2152;
pusch_FailureThres = 1000;
}
);
L1s = (
{
num_cc = 1;
tr_n_preference = "local_mac";
prach_dtx_threshold = 200;
pucch0_dtx_threshold = 150;
ofdm_offset_divisor = 8; #set this to UINT_MAX for offset 0
}
);
RUs = (
{
local_rf = "yes"
nb_tx = 1
nb_rx = 1
att_tx = 0
att_rx = 0;
bands = [66];
max_pdschReferenceSignalPower = -27;
max_rxgain = 114;
eNB_instances = [0];
#beamforming 1x4 matrix:
bf_weights = [0x00007fff, 0x0000, 0x0000, 0x0000];
clock_src = "internal";
}
);
THREAD_STRUCT = (
{
#three config for level of parallelism "PARALLEL_SINGLE_THREAD", "PARALLEL_RU_L1_SPLIT", or "PARALLEL_RU_L1_TRX_SPLIT"
parallel_config = "PARALLEL_SINGLE_THREAD";
#two option for worker "WORKER_DISABLE" or "WORKER_ENABLE"
worker_config = "WORKER_ENABLE";
}
);
rfsimulator: {
serveraddr = "server";
serverport = 4043;
options = (); #("saviq"); or/and "chanmod"
modelname = "AWGN";
IQfile = "/tmp/rfsimulator.iqs"
}
log_config :
{
global_log_level = "info";
hw_log_level = "info";
nr_phy_log_level = "info";
nr_mac_log_level = "info";
rlc_log_level = "info";
pdcp_log_level = "info";
rrc_log_level = "info";
f1ap_log_level = "info";
ngap_log_level = "debug";
};

View File

@@ -0,0 +1,235 @@
Active_gNBs = ( "du-rfsim");
# Asn1_verbosity, choice in: none, info, annoying
Asn1_verbosity = "none";
gNBs =
(
{
////////// Identification parameters:
gNB_ID = 0xe00;
gNB_DU_ID = 0xe01;
gNB_name = "du-rfsim";
// Tracking area code, 0x0000 and 0xfffe are reserved values
tracking_area_code = 1;
plmn_list = ({ mcc = 001; mnc = 01; mnc_length = 2; snssaiList = ({ sst = 1; }) });
nr_cellid = 11111111L;
////////// Physical parameters:
min_rxtxtime = 4;
sib1_tda = 15;
servingCellConfigCommon = (
{
#spCellConfigCommon
physCellId = 1;
# downlinkConfigCommon
#frequencyInfoDL
# this is 3600 MHz + 43 PRBs@30kHz SCS (same as initial BWP)
absoluteFrequencySSB = 435610;
dl_frequencyBand = 66;
# this is 3600 MHz
dl_absoluteFrequencyPointA = 435000;
#scs-SpecificCarrierList
dl_offstToCarrier = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
dl_subcarrierSpacing = 0;
dl_carrierBandwidth = 25;
#initialDownlinkBWP
#genericParameters
# this is RBstart=27,L=48 (275*(L-1))+RBstart
initialDLBWPlocationAndBandwidth = 6600; # 6366 12925 12956 28875 12952
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
initialDLBWPsubcarrierSpacing = 0;
#pdcch-ConfigCommon
initialDLBWPcontrolResourceSetZero = 0;
initialDLBWPsearchSpaceZero = 0;
#uplinkConfigCommon
#frequencyInfoUL
ul_frequencyBand = 66;
# this is 1750 MHz
ul_absoluteFrequencyPointA = 355000;
#scs-SpecificCarrierList
ul_offstToCarrier = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
ul_subcarrierSpacing = 0;
ul_carrierBandwidth = 25;
pMax = 20;
#initialUplinkBWP
#genericParameters
initialULBWPlocationAndBandwidth = 6600;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
initialULBWPsubcarrierSpacing = 0;
#rach-ConfigCommon
#rach-ConfigGeneric
prach_ConfigurationIndex = 98;
#prach_msg1_FDM
#0 = one, 1=two, 2=four, 3=eight
prach_msg1_FDM = 0;
prach_msg1_FrequencyStart = 0;
zeroCorrelationZoneConfig = 13;
preambleReceivedTargetPower = -96;
#preamblTransMax (0...10) = (3,4,5,6,7,8,10,20,50,100,200)
preambleTransMax = 6;
#powerRampingStep
# 0=dB0,1=dB2,2=dB4,3=dB6
powerRampingStep = 1;
#ra_ReponseWindow
#1,2,4,8,10,20,40,80
ra_ResponseWindow = 4;
#ssb_perRACH_OccasionAndCB_PreamblesPerSSB_PR
#1=oneeighth,2=onefourth,3=half,4=one,5=two,6=four,7=eight,8=sixteen
ssb_perRACH_OccasionAndCB_PreamblesPerSSB_PR = 4;
#oneHalf (0..15) 4,8,12,16,...60,64
ssb_perRACH_OccasionAndCB_PreamblesPerSSB = 15;
#ra_ContentionResolutionTimer
#(0..7) 8,16,24,32,40,48,56,64
ra_ContentionResolutionTimer = 7;
rsrp_ThresholdSSB = 19;
#prach-RootSequenceIndex_PR
#1 = 839, 2 = 139
prach_RootSequenceIndex_PR = 2;
prach_RootSequenceIndex = 1;
# SCS for msg1, can only be 15 for 30 kHz < 6 GHz, takes precendence over the one derived from prach-ConfigIndex
#
msg1_SubcarrierSpacing = 0,
# restrictedSetConfig
# 0=unrestricted, 1=restricted type A, 2=restricted type B
restrictedSetConfig = 0,
msg3_DeltaPreamble = 1;
p0_NominalWithGrant =-90;
# pucch-ConfigCommon setup :
# pucchGroupHopping
# 0 = neither, 1= group hopping, 2=sequence hopping
pucchGroupHopping = 0;
hoppingId = 40;
p0_nominal = -90;
# ssb_PositionsInBurs_BitmapPR
# 1=short, 2=medium, 3=long
ssb_PositionsInBurst_PR = 2;
ssb_PositionsInBurst_Bitmap = 1;
# ssb_periodicityServingCell
# 0 = ms5, 1=ms10, 2=ms20, 3=ms40, 4=ms80, 5=ms160, 6=spare2, 7=spare1
ssb_periodicityServingCell = 2;
# dmrs_TypeA_position
# 0 = pos2, 1 = pos3
dmrs_TypeA_Position = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
subcarrierSpacing = 0;
#tdd-UL-DL-ConfigurationCommon
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
referenceSubcarrierSpacing = 0;
# pattern1
# dl_UL_TransmissionPeriodicity
# 0=ms0p5, 1=ms0p625, 2=ms1, 3=ms1p25, 4=ms2, 5=ms2p5, 6=ms5, 7=ms10
dl_UL_TransmissionPeriodicity = 6;
nrofDownlinkSlots = 7;
nrofDownlinkSymbols = 6;
nrofUplinkSlots = 2;
nrofUplinkSymbols = 4;
ssPBCH_BlockPower = -25;
}
);
# ------- SCTP definitions
SCTP :
{
# Number of streams to use in input/output
SCTP_INSTREAMS = 2;
SCTP_OUTSTREAMS = 2;
};
}
);
MACRLCs = (
{
num_cc = 1;
tr_s_preference = "local_L1";
tr_n_preference = "f1";
local_n_if_name = "lo";
local_n_address = "127.0.0.5";
remote_n_address = "127.0.0.3";
local_n_portc = 500;
local_n_portd = 2152;
remote_n_portc = 501;
remote_n_portd = 2152;
pusch_FailureThres = 1000;
}
);
L1s = (
{
num_cc = 1;
tr_n_preference = "local_mac";
prach_dtx_threshold = 200;
pucch0_dtx_threshold = 150;
ofdm_offset_divisor = 8; #set this to UINT_MAX for offset 0
}
);
RUs = (
{
local_rf = "yes"
nb_tx = 1
nb_rx = 1
att_tx = 0
att_rx = 0;
bands = [66];
max_pdschReferenceSignalPower = -27;
max_rxgain = 114;
eNB_instances = [0];
#beamforming 1x4 matrix:
bf_weights = [0x00007fff, 0x0000, 0x0000, 0x0000];
clock_src = "internal";
}
);
THREAD_STRUCT = (
{
#three config for level of parallelism "PARALLEL_SINGLE_THREAD", "PARALLEL_RU_L1_SPLIT", or "PARALLEL_RU_L1_TRX_SPLIT"
parallel_config = "PARALLEL_SINGLE_THREAD";
#two option for worker "WORKER_DISABLE" or "WORKER_ENABLE"
worker_config = "WORKER_ENABLE";
}
);
rfsimulator: {
serveraddr = "server";
serverport = 4043;
options = (); #("saviq"); or/and "chanmod"
modelname = "AWGN";
IQfile = "/tmp/rfsimulator.iqs"
}
log_config :
{
global_log_level = "info";
hw_log_level = "info";
nr_phy_log_level = "info";
nr_mac_log_level = "info";
rlc_log_level = "info";
pdcp_log_level = "info";
rrc_log_level = "info";
f1ap_log_level = "info";
ngap_log_level = "debug";
};

View File

@@ -0,0 +1,232 @@
Active_gNBs = ( "du-rfsim");
# Asn1_verbosity, choice in: none, info, annoying
Asn1_verbosity = "none";
gNBs =
(
{
////////// Identification parameters:
gNB_ID = 0xe00;
gNB_DU_ID = 0xe00;
gNB_name = "du-rfsim";
// Tracking area code, 0x0000 and 0xfffe are reserved values
tracking_area_code = 1;
plmn_list = ({ mcc = 001; mnc = 01; mnc_length = 2; snssaiList = ({ sst = 1; }) });
nr_cellid = 12345678L;
////////// Physical parameters:
min_rxtxtime = 4;
servingCellConfigCommon = (
{
#spCellConfigCommon
physCellId = 0;
# downlinkConfigCommon
#frequencyInfoDL
# this is 3600 MHz + 43 PRBs@30kHz SCS (same as initial BWP)
absoluteFrequencySSB = 630048;
dl_frequencyBand = 78;
# this is 3600 MHz
dl_absoluteFrequencyPointA = 628776;
#scs-SpecificCarrierList
dl_offstToCarrier = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
dl_subcarrierSpacing = 1;
dl_carrierBandwidth = 106;
#initialDownlinkBWP
#genericParameters
# this is RBstart=27,L=48 (275*(L-1))+RBstart
initialDLBWPlocationAndBandwidth = 28875; # 6366 12925 12956 28875 12952
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
initialDLBWPsubcarrierSpacing = 1;
#pdcch-ConfigCommon
initialDLBWPcontrolResourceSetZero = 12;
initialDLBWPsearchSpaceZero = 0;
#uplinkConfigCommon
#frequencyInfoUL
ul_frequencyBand = 78;
#scs-SpecificCarrierList
ul_offstToCarrier = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
ul_subcarrierSpacing = 1;
ul_carrierBandwidth = 106;
pMax = 20;
#initialUplinkBWP
#genericParameters
initialULBWPlocationAndBandwidth = 28875;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
initialULBWPsubcarrierSpacing = 1;
#rach-ConfigCommon
#rach-ConfigGeneric
prach_ConfigurationIndex = 98;
#prach_msg1_FDM
#0 = one, 1=two, 2=four, 3=eight
prach_msg1_FDM = 0;
prach_msg1_FrequencyStart = 0;
zeroCorrelationZoneConfig = 13;
preambleReceivedTargetPower = -96;
#preamblTransMax (0...10) = (3,4,5,6,7,8,10,20,50,100,200)
preambleTransMax = 6;
#powerRampingStep
# 0=dB0,1=dB2,2=dB4,3=dB6
powerRampingStep = 1;
#ra_ReponseWindow
#1,2,4,8,10,20,40,80
ra_ResponseWindow = 4;
#ssb_perRACH_OccasionAndCB_PreamblesPerSSB_PR
#1=oneeighth,2=onefourth,3=half,4=one,5=two,6=four,7=eight,8=sixteen
ssb_perRACH_OccasionAndCB_PreamblesPerSSB_PR = 4;
#oneHalf (0..15) 4,8,12,16,...60,64
ssb_perRACH_OccasionAndCB_PreamblesPerSSB = 14;
#ra_ContentionResolutionTimer
#(0..7) 8,16,24,32,40,48,56,64
ra_ContentionResolutionTimer = 7;
rsrp_ThresholdSSB = 19;
#prach-RootSequenceIndex_PR
#1 = 839, 2 = 139
prach_RootSequenceIndex_PR = 2;
prach_RootSequenceIndex = 1;
# SCS for msg1, can only be 15 for 30 kHz < 6 GHz, takes precendence over the one derived from prach-ConfigIndex
#
msg1_SubcarrierSpacing = 1,
# restrictedSetConfig
# 0=unrestricted, 1=restricted type A, 2=restricted type B
restrictedSetConfig = 0,
msg3_DeltaPreamble = 1;
p0_NominalWithGrant =-90;
# pucch-ConfigCommon setup :
# pucchGroupHopping
# 0 = neither, 1= group hopping, 2=sequence hopping
pucchGroupHopping = 0;
hoppingId = 40;
p0_nominal = -90;
# ssb_PositionsInBurs_BitmapPR
# 1=short, 2=medium, 3=long
ssb_PositionsInBurst_PR = 2;
ssb_PositionsInBurst_Bitmap = 1;
# ssb_periodicityServingCell
# 0 = ms5, 1=ms10, 2=ms20, 3=ms40, 4=ms80, 5=ms160, 6=spare2, 7=spare1
ssb_periodicityServingCell = 2;
# dmrs_TypeA_position
# 0 = pos2, 1 = pos3
dmrs_TypeA_Position = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
subcarrierSpacing = 1;
#tdd-UL-DL-ConfigurationCommon
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
referenceSubcarrierSpacing = 1;
# pattern1
# dl_UL_TransmissionPeriodicity
# 0=ms0p5, 1=ms0p625, 2=ms1, 3=ms1p25, 4=ms2, 5=ms2p5, 6=ms5, 7=ms10
dl_UL_TransmissionPeriodicity = 6;
nrofDownlinkSlots = 7;
nrofDownlinkSymbols = 6;
nrofUplinkSlots = 2;
nrofUplinkSymbols = 4;
ssPBCH_BlockPower = -25;
}
);
# ------- SCTP definitions
SCTP :
{
# Number of streams to use in input/output
SCTP_INSTREAMS = 2;
SCTP_OUTSTREAMS = 2;
};
}
);
MACRLCs = (
{
num_cc = 1;
tr_s_preference = "local_L1";
tr_n_preference = "f1";
local_n_if_name = "lo";
local_n_address = "127.0.0.4";
remote_n_address = "127.0.0.3";
local_n_portc = 500;
local_n_portd = 2152;
remote_n_portc = 501;
remote_n_portd = 2152;
pusch_FailureThres = 1000;
}
);
L1s = (
{
num_cc = 1;
tr_n_preference = "local_mac";
prach_dtx_threshold = 200;
pucch0_dtx_threshold = 150;
ofdm_offset_divisor = 8; #set this to UINT_MAX for offset 0
}
);
RUs = (
{
local_rf = "yes"
nb_tx = 1
nb_rx = 1
att_tx = 0
att_rx = 0;
bands = [78];
max_pdschReferenceSignalPower = -27;
max_rxgain = 114;
eNB_instances = [0];
#beamforming 1x4 matrix:
bf_weights = [0x00007fff, 0x0000, 0x0000, 0x0000];
clock_src = "internal";
}
);
THREAD_STRUCT = (
{
#three config for level of parallelism "PARALLEL_SINGLE_THREAD", "PARALLEL_RU_L1_SPLIT", or "PARALLEL_RU_L1_TRX_SPLIT"
parallel_config = "PARALLEL_SINGLE_THREAD";
#two option for worker "WORKER_DISABLE" or "WORKER_ENABLE"
worker_config = "WORKER_ENABLE";
}
);
rfsimulator: {
serveraddr = "server";
serverport = 4043;
options = (); #("saviq"); or/and "chanmod"
modelname = "AWGN";
IQfile = "/tmp/rfsimulator.iqs"
}
log_config :
{
global_log_level = "info";
hw_log_level = "info";
nr_phy_log_level = "info";
nr_mac_log_level = "info";
rlc_log_level = "info";
pdcp_log_level = "info";
rrc_log_level = "info";
f1ap_log_level = "info";
ngap_log_level = "debug";
};

View File

@@ -0,0 +1,232 @@
Active_gNBs = ( "du-rfsim");
# Asn1_verbosity, choice in: none, info, annoying
Asn1_verbosity = "none";
gNBs =
(
{
////////// Identification parameters:
gNB_ID = 0xe00;
gNB_DU_ID = 0xe01;
gNB_name = "du-rfsim";
// Tracking area code, 0x0000 and 0xfffe are reserved values
tracking_area_code = 1;
plmn_list = ({ mcc = 001; mnc = 01; mnc_length = 2; snssaiList = ({ sst = 1; }) });
nr_cellid = 11111111L;
////////// Physical parameters:
min_rxtxtime = 4;
servingCellConfigCommon = (
{
#spCellConfigCommon
physCellId = 1;
# downlinkConfigCommon
#frequencyInfoDL
# this is 3600 MHz + 43 PRBs@30kHz SCS (same as initial BWP)
absoluteFrequencySSB = 643296;
dl_frequencyBand = 78;
# this is 3600 MHz
dl_absoluteFrequencyPointA = 642024;
#scs-SpecificCarrierList
dl_offstToCarrier = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
dl_subcarrierSpacing = 1;
dl_carrierBandwidth = 106;
#initialDownlinkBWP
#genericParameters
# this is RBstart=27,L=48 (275*(L-1))+RBstart
initialDLBWPlocationAndBandwidth = 28875; # 6366 12925 12956 28875 12952
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
initialDLBWPsubcarrierSpacing = 1;
#pdcch-ConfigCommon
initialDLBWPcontrolResourceSetZero = 12;
initialDLBWPsearchSpaceZero = 0;
#uplinkConfigCommon
#frequencyInfoUL
ul_frequencyBand = 78;
#scs-SpecificCarrierList
ul_offstToCarrier = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
ul_subcarrierSpacing = 1;
ul_carrierBandwidth = 106;
pMax = 20;
#initialUplinkBWP
#genericParameters
initialULBWPlocationAndBandwidth = 28875;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
initialULBWPsubcarrierSpacing = 1;
#rach-ConfigCommon
#rach-ConfigGeneric
prach_ConfigurationIndex = 98;
#prach_msg1_FDM
#0 = one, 1=two, 2=four, 3=eight
prach_msg1_FDM = 0;
prach_msg1_FrequencyStart = 0;
zeroCorrelationZoneConfig = 13;
preambleReceivedTargetPower = -96;
#preamblTransMax (0...10) = (3,4,5,6,7,8,10,20,50,100,200)
preambleTransMax = 6;
#powerRampingStep
# 0=dB0,1=dB2,2=dB4,3=dB6
powerRampingStep = 1;
#ra_ReponseWindow
#1,2,4,8,10,20,40,80
ra_ResponseWindow = 4;
#ssb_perRACH_OccasionAndCB_PreamblesPerSSB_PR
#1=oneeighth,2=onefourth,3=half,4=one,5=two,6=four,7=eight,8=sixteen
ssb_perRACH_OccasionAndCB_PreamblesPerSSB_PR = 4;
#oneHalf (0..15) 4,8,12,16,...60,64
ssb_perRACH_OccasionAndCB_PreamblesPerSSB = 14;
#ra_ContentionResolutionTimer
#(0..7) 8,16,24,32,40,48,56,64
ra_ContentionResolutionTimer = 7;
rsrp_ThresholdSSB = 19;
#prach-RootSequenceIndex_PR
#1 = 839, 2 = 139
prach_RootSequenceIndex_PR = 2;
prach_RootSequenceIndex = 1;
# SCS for msg1, can only be 15 for 30 kHz < 6 GHz, takes precendence over the one derived from prach-ConfigIndex
#
msg1_SubcarrierSpacing = 1,
# restrictedSetConfig
# 0=unrestricted, 1=restricted type A, 2=restricted type B
restrictedSetConfig = 0,
msg3_DeltaPreamble = 1;
p0_NominalWithGrant =-90;
# pucch-ConfigCommon setup :
# pucchGroupHopping
# 0 = neither, 1= group hopping, 2=sequence hopping
pucchGroupHopping = 0;
hoppingId = 40;
p0_nominal = -90;
# ssb_PositionsInBurs_BitmapPR
# 1=short, 2=medium, 3=long
ssb_PositionsInBurst_PR = 2;
ssb_PositionsInBurst_Bitmap = 3;
# ssb_periodicityServingCell
# 0 = ms5, 1=ms10, 2=ms20, 3=ms40, 4=ms80, 5=ms160, 6=spare2, 7=spare1
ssb_periodicityServingCell = 2;
# dmrs_TypeA_position
# 0 = pos2, 1 = pos3
dmrs_TypeA_Position = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
subcarrierSpacing = 1;
#tdd-UL-DL-ConfigurationCommon
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
referenceSubcarrierSpacing = 1;
# pattern1
# dl_UL_TransmissionPeriodicity
# 0=ms0p5, 1=ms0p625, 2=ms1, 3=ms1p25, 4=ms2, 5=ms2p5, 6=ms5, 7=ms10
dl_UL_TransmissionPeriodicity = 6;
nrofDownlinkSlots = 7;
nrofDownlinkSymbols = 6;
nrofUplinkSlots = 2;
nrofUplinkSymbols = 4;
ssPBCH_BlockPower = -25;
}
);
# ------- SCTP definitions
SCTP :
{
# Number of streams to use in input/output
SCTP_INSTREAMS = 2;
SCTP_OUTSTREAMS = 2;
};
}
);
MACRLCs = (
{
num_cc = 1;
tr_s_preference = "local_L1";
tr_n_preference = "f1";
local_n_if_name = "lo";
local_n_address = "127.0.0.5";
remote_n_address = "127.0.0.3";
local_n_portc = 500;
local_n_portd = 2152;
remote_n_portc = 501;
remote_n_portd = 2152;
pusch_FailureThres = 1000;
}
);
L1s = (
{
num_cc = 1;
tr_n_preference = "local_mac";
prach_dtx_threshold = 200;
pucch0_dtx_threshold = 150;
ofdm_offset_divisor = 8; #set this to UINT_MAX for offset 0
}
);
RUs = (
{
local_rf = "yes"
nb_tx = 1
nb_rx = 1
att_tx = 0
att_rx = 0;
bands = [78];
max_pdschReferenceSignalPower = -27;
max_rxgain = 114;
eNB_instances = [0];
#beamforming 1x4 matrix:
bf_weights = [0x00007fff, 0x0000, 0x0000, 0x0000];
clock_src = "internal";
}
);
THREAD_STRUCT = (
{
#three config for level of parallelism "PARALLEL_SINGLE_THREAD", "PARALLEL_RU_L1_SPLIT", or "PARALLEL_RU_L1_TRX_SPLIT"
parallel_config = "PARALLEL_SINGLE_THREAD";
#two option for worker "WORKER_DISABLE" or "WORKER_ENABLE"
worker_config = "WORKER_ENABLE";
}
);
rfsimulator: {
serveraddr = "server";
serverport = 4043;
options = (); #("saviq"); or/and "chanmod"
modelname = "AWGN";
IQfile = "/tmp/rfsimulator.iqs"
}
log_config :
{
global_log_level = "info";
hw_log_level = "info";
nr_phy_log_level = "info";
nr_mac_log_level = "info";
rlc_log_level = "info";
pdcp_log_level = "info";
rrc_log_level = "info";
f1ap_log_level = "info";
ngap_log_level = "debug";
};