adding --rrc_config_path command line option to UE
This commit is contained in:
@@ -33,10 +33,10 @@
|
||||
#include "defs.h"
|
||||
#include "rrc_proto.h"
|
||||
|
||||
int nr_l3_init_ue(void){
|
||||
int nr_l3_init_ue(char* rrc_config_path){
|
||||
//LOG_I(RRC, "[MAIN] NR UE MAC initialization...\n");
|
||||
|
||||
openair_rrc_top_init_ue_nr();
|
||||
openair_rrc_top_init_ue_nr(rrc_config_path);
|
||||
|
||||
return 0;
|
||||
|
||||
|
||||
@@ -259,7 +259,7 @@ void process_nsa_message(NR_UE_RRC_INST_t *rrc, nsa_message_t nsa_message_type,
|
||||
|
||||
}
|
||||
|
||||
int8_t openair_rrc_top_init_ue_nr(void){
|
||||
int8_t openair_rrc_top_init_ue_nr(char* rrc_config_path){
|
||||
|
||||
if(NB_NR_UE_INST > 0){
|
||||
NR_UE_rrc_inst = (NR_UE_RRC_INST_t *)malloc(NB_NR_UE_INST * sizeof(NR_UE_RRC_INST_t));
|
||||
@@ -324,12 +324,21 @@ int8_t openair_rrc_top_init_ue_nr(void){
|
||||
if (phy_test==1) {
|
||||
// read in files for RRCReconfiguration and RBconfig
|
||||
FILE *fd;
|
||||
fd = fopen("reconfig.raw","r");
|
||||
char filename[1024];
|
||||
if (rrc_config_path)
|
||||
sprintf(filename,"%s/reconfig.raw",rrc_config_path);
|
||||
else
|
||||
sprintf(filename,"reconfig.raw");
|
||||
fd = fopen(filename,"r");
|
||||
char buffer[1024];
|
||||
int msg_len=fread(buffer,1,1024,fd);
|
||||
fclose(fd);
|
||||
process_nsa_message(NR_UE_rrc_inst, nr_SecondaryCellGroupConfig_r15, buffer,msg_len);
|
||||
fd = fopen("rbconfig.raw","r");
|
||||
if (rrc_config_path)
|
||||
sprintf(filename,"%s/rbconfig.raw",rrc_config_path);
|
||||
else
|
||||
sprintf(filename,"rbconfig.raw");
|
||||
fd = fopen(filename,"r");
|
||||
msg_len=fread(buffer,1,1024,fd);
|
||||
fclose(fd);
|
||||
process_nsa_message(NR_UE_rrc_inst, nr_RadioBearerConfigX_r15, buffer,msg_len);
|
||||
|
||||
@@ -43,14 +43,14 @@
|
||||
// main_rrc.c
|
||||
//
|
||||
/**\brief Layer 3 initialization*/
|
||||
int nr_l3_init_ue(void);
|
||||
int nr_l3_init_ue(char*);
|
||||
|
||||
//
|
||||
// UE_rrc.c
|
||||
//
|
||||
|
||||
/**\brief Initial the top level RRC structure instance*/
|
||||
int8_t openair_rrc_top_init_ue_nr(void);
|
||||
int8_t openair_rrc_top_init_ue_nr(char*);
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user