From f701c02fdd0a676a29d1300e7c85e15572a182f9 Mon Sep 17 00:00:00 2001 From: WEI-TAI CHEN Date: Wed, 27 Jun 2018 01:53:37 -0700 Subject: [PATCH] Add Log for NR --- openair2/RRC/NR/MESSAGES/asn1_msg.c | 2 +- openair2/RRC/NR/rrc_gNB.c | 2 +- openair2/UTIL/LOG/log.c | 32 +++++++++++++++++++ .../CONF/gnb.band78.tm1.106PRB.usrpx300.conf | 2 +- 4 files changed, 35 insertions(+), 3 deletions(-) diff --git a/openair2/RRC/NR/MESSAGES/asn1_msg.c b/openair2/RRC/NR/MESSAGES/asn1_msg.c index 88c8935b63..a0f3e92e62 100644 --- a/openair2/RRC/NR/MESSAGES/asn1_msg.c +++ b/openair2/RRC/NR/MESSAGES/asn1_msg.c @@ -297,7 +297,7 @@ void do_SERVINGCELLCONFIGCOMMON(uint8_t Mod_id, (*servingcellconfigcommon)->frequencyInfoDL = CALLOC(1,sizeof(struct NR_FrequencyInfoDL)); (*servingcellconfigcommon)->initialDownlinkBWP = CALLOC(1,sizeof(struct NR_BWP_DownlinkCommon)); (*servingcellconfigcommon)->uplinkConfigCommon = CALLOC(1,sizeof(struct NR_UplinkConfigCommon)); - //(*servingcellconfigcommon)->supplementaryUplinkConfig = CALLOC(1,sizeof(struct NR_UplinkConfigCommon)); + //(*servingcellconfigcommon)->supplementaryUplinkConfig = CALLOC(1,sizeof(struct NR_UplinkConfigCommon)); (*servingcellconfigcommon)->ssb_PositionsInBurst = CALLOC(1,sizeof(struct NR_ServingCellConfigCommon__ssb_PositionsInBurst)); (*servingcellconfigcommon)->ssb_periodicityServingCell = CALLOC(1,sizeof(long)); //(*servingcellconfigcommon)->lte_CRS_ToMatchAround = CALLOC(1,sizeof(struct NR_SetupRelease_RateMatchPatternLTE_CRS)); diff --git a/openair2/RRC/NR/rrc_gNB.c b/openair2/RRC/NR/rrc_gNB.c index 21eb1769c7..37b6ccb961 100644 --- a/openair2/RRC/NR/rrc_gNB.c +++ b/openair2/RRC/NR/rrc_gNB.c @@ -296,7 +296,7 @@ void* rrc_gnb_task(void* args_p){ msg_name_p = ITTI_MSG_NAME(msg_p); instance = ITTI_MSG_INSTANCE(msg_p); - LOG_I(RRC,"Received message %s\n",msg_name_p); + LOG_I(NR_RRC,"Received message %s\n",msg_name_p); switch (ITTI_MSG_ID(msg_p)) { case TERMINATE_MESSAGE: diff --git a/openair2/UTIL/LOG/log.c b/openair2/UTIL/LOG/log.c index ff6a5cd573..a131c82931 100644 --- a/openair2/UTIL/LOG/log.c +++ b/openair2/UTIL/LOG/log.c @@ -172,6 +172,14 @@ int logInit (void) g_log->log_component[PHY].filelog = 0; g_log->log_component[PHY].filelog_name = "/tmp/phy.log"; + g_log->log_component[NR_PHY].name = "NR_PHY"; + g_log->log_component[NR_PHY].level = LOG_EMERG; + g_log->log_component[NR_PHY].flag = LOG_MED; + g_log->log_component[NR_PHY].interval = 1; + g_log->log_component[NR_PHY].fd = 0; + g_log->log_component[NR_PHY].filelog = 0; + g_log->log_component[NR_PHY].filelog_name = "/tmp/nrphy.log"; + g_log->log_component[MAC].name = "MAC"; g_log->log_component[MAC].level = LOG_EMERG; g_log->log_component[MAC].flag = LOG_MED; @@ -180,6 +188,14 @@ int logInit (void) g_log->log_component[MAC].filelog = 0; g_log->log_component[MAC].filelog_name = "/tmp/mac.log"; + g_log->log_component[NR_MAC].name = "NR_MAC"; + g_log->log_component[NR_MAC].level = LOG_EMERG; + g_log->log_component[NR_MAC].flag = LOG_MED; + g_log->log_component[NR_MAC].interval = 1; + g_log->log_component[NR_MAC].fd = 0; + g_log->log_component[NR_MAC].filelog = 0; + g_log->log_component[NR_MAC].filelog_name = "/tmp/nrmac.log"; + g_log->log_component[OPT].name = "OPT"; g_log->log_component[OPT].level = LOG_EMERG; g_log->log_component[OPT].flag = LOG_MED; @@ -212,6 +228,14 @@ int logInit (void) g_log->log_component[RRC].filelog = 0; g_log->log_component[RRC].filelog_name = "/tmp/rrc.log"; + g_log->log_component[NR_RRC].name = "NR_RRC"; + g_log->log_component[NR_RRC].level = LOG_TRACE; + g_log->log_component[NR_RRC].flag = LOG_MED; + g_log->log_component[NR_RRC].interval = 1; + g_log->log_component[NR_RRC].fd = 0; + g_log->log_component[NR_RRC].filelog = 0; + g_log->log_component[NR_RRC].filelog_name = "/tmp/nrrrc.log"; + g_log->log_component[EMU].name = "EMU"; g_log->log_component[EMU].level = LOG_EMERG; g_log->log_component[EMU].flag = LOG_MED; @@ -364,6 +388,14 @@ int logInit (void) g_log->log_component[ENB_APP].filelog = 0; g_log->log_component[ENB_APP].filelog_name = ""; + g_log->log_component[GNB_APP].name = "GNB_APP"; + g_log->log_component[GNB_APP].level = LOG_EMERG; + g_log->log_component[GNB_APP].flag = LOG_MED; + g_log->log_component[GNB_APP].interval = 1; + g_log->log_component[GNB_APP].fd = 0; + g_log->log_component[GNB_APP].filelog = 0; + g_log->log_component[GNB_APP].filelog_name = ""; + g_log->log_component[FLEXRAN_AGENT].name = "FLEXRAN_AGENT"; g_log->log_component[FLEXRAN_AGENT].level = LOG_DEBUG; g_log->log_component[FLEXRAN_AGENT].flag = LOG_MED; diff --git a/targets/PROJECTS/GENERIC-LTE-EPC/CONF/gnb.band78.tm1.106PRB.usrpx300.conf b/targets/PROJECTS/GENERIC-LTE-EPC/CONF/gnb.band78.tm1.106PRB.usrpx300.conf index 0a4875276a..c9f5640763 100644 --- a/targets/PROJECTS/GENERIC-LTE-EPC/CONF/gnb.band78.tm1.106PRB.usrpx300.conf +++ b/targets/PROJECTS/GENERIC-LTE-EPC/CONF/gnb.band78.tm1.106PRB.usrpx300.conf @@ -8,7 +8,7 @@ gNBs = ////////// Identification parameters: gNB_ID = 0xe00; - cell_type = "CELL_MACRO_ENB"; + cell_type = "CELL_MACRO_GNB"; gNB_name = "gNB-Eurecom-5GNRBox";