create a trace group for nr rach
This commit is contained in:
committed by
Robert Schmidt
parent
180f83d196
commit
4f39ba8f51
@@ -168,8 +168,9 @@ static const char *const flag_name[] = {FOREACH_FLAG(FLAG_TEXT) ""};
|
||||
COMP_DEF(GNB_APP, log) \
|
||||
COMP_DEF(NR_RRC, log) \
|
||||
COMP_DEF(NR_MAC, log) \
|
||||
COMP_DEF(NR_MAC_DCI, log) \
|
||||
COMP_DEF(NR_PHY_DCI, log) \
|
||||
COMP_DEF(NR_MAC_DCI, log) \
|
||||
COMP_DEF(NR_PHY_DCI, log) \
|
||||
COMP_DEF(NR_PHY_RACH, log) \
|
||||
COMP_DEF(NR_PHY, log) \
|
||||
COMP_DEF(LOADER, log) \
|
||||
COMP_DEF(ASN1, log) \
|
||||
|
||||
@@ -519,6 +519,27 @@ ID = LEGACY_NR_PHY_TRACE
|
||||
GROUP = ALL:LEGACY_NR_PHY:LEGACY_GROUP_TRACE:LEGACY
|
||||
FORMAT = string,log
|
||||
|
||||
ID = LEGACY_NR_PHY_RACH_INFO
|
||||
DESC = NR_PHY_RACH legacy logs - info level
|
||||
GROUP = ALL:LEGACY_NR_PHY_RACH:LEGACY_GROUP_INFO:LEGACY
|
||||
FORMAT = string,log
|
||||
ID = LEGACY_NR_PHY_RACH_ERROR
|
||||
DESC = NR_PHY_RACH legacy logs - error level
|
||||
GROUP = ALL:LEGACY_NR_PHY_RACH:LEGACY_GROUP_ERROR:LEGACY
|
||||
FORMAT = string,log
|
||||
ID = LEGACY_NR_PHY_RACH_WARNING
|
||||
DESC = NR_PHY_RACH legacy logs - warning level
|
||||
GROUP = ALL:LEGACY_NR_PHY_RACH:LEGACY_GROUP_WARNING:LEGACY
|
||||
FORMAT = string,log
|
||||
ID = LEGACY_NR_PHY_RACH_DEBUG
|
||||
DESC = NR_PHY_RACH legacy logs - debug level
|
||||
GROUP = ALL:LEGACY_NR_PHY_RACH:LEGACY_GROUP_DEBUG:LEGACY
|
||||
FORMAT = string,log
|
||||
ID = LEGACY_NR_PHY_RACH_TRACE
|
||||
DESC = NR_PHY_RACH legacy logs - trace level
|
||||
GROUP = ALL:LEGACY_NR_PHY_RACH:LEGACY_GROUP_TRACE:LEGACY
|
||||
FORMAT = string,log
|
||||
|
||||
ID = LEGACY_S1AP_INFO
|
||||
DESC = S1AP legacy logs - info level
|
||||
GROUP = ALL:LEGACY_S1AP:LEGACY_GROUP_INFO:LEGACY
|
||||
|
||||
+1
-1
@@ -1219,7 +1219,7 @@ void *ru_thread(void *param)
|
||||
T_BUFFER(&ru->common.rxdata[0][fp->get_samples_slot_timestamp(proc->tti_rx - 1, fp, 0) /*-ru->N_TA_offset*/],
|
||||
(fp->get_samples_per_slot(proc->tti_rx - 1, fp) + fp->get_samples_per_slot(proc->tti_rx, fp)) * 4));
|
||||
int N_dur = get_nr_prach_duration(p->pdu.prach_format);
|
||||
|
||||
LOG_D(NR_PHY_RACH, "%d.%d try to decode %d occasions \n", frame, slot, p->pdu.num_prach_ocas);
|
||||
for (int prach_oc = 0; prach_oc < p->pdu.num_prach_ocas; prach_oc++) {
|
||||
int prachStartSymbol = p->pdu.prach_start_symbol + prach_oc * N_dur;
|
||||
int beam_id = p->beams[prach_oc];
|
||||
|
||||
@@ -46,6 +46,8 @@ void init_prach_list(prach_list_t *l)
|
||||
void free_nr_prach_entry(prach_list_t *l, prach_item_t *p)
|
||||
{
|
||||
pthread_mutex_lock(&l->prach_list_mutex);
|
||||
if (p->frame == -1)
|
||||
LOG_E(NR_PHY_RACH, "Freeing a not allocated prach entry\n");
|
||||
*p = (prach_item_t){.frame = -1, .slot = -1, .num_slots = -1};
|
||||
pthread_mutex_unlock(&l->prach_list_mutex);
|
||||
}
|
||||
@@ -421,7 +423,7 @@ void rx_nr_prach(PHY_VARS_gNB *gNB,
|
||||
const int prach_fmt = prach_pdu->prach_format;
|
||||
const int N_ZC = prach_sequence_length == 0 ? 839 : 139;
|
||||
|
||||
LOG_D(PHY,
|
||||
LOG_D(NR_PHY_RACH,
|
||||
"L1 PRACH RX: rooSequenceIndex %d, numRootSeqeuences %d, NCS %d, N_ZC %d, format %d \n",
|
||||
rootSequenceIndex,
|
||||
numrootSequenceIndex,
|
||||
@@ -550,7 +552,12 @@ void rx_nr_prach(PHY_VARS_gNB *gNB,
|
||||
en);
|
||||
}
|
||||
|
||||
LOG_D(PHY,"PRACH RX preamble_index %d, preamble_offset %d\n",preamble_index,preamble_offset);
|
||||
LOG_D(NR_PHY_RACH,
|
||||
"PRACH RX preamble_index %d, preamble_offset %d, preamb shift %d new dft %d\n",
|
||||
preamble_index,
|
||||
preamble_offset,
|
||||
preamble_shift,
|
||||
new_dft);
|
||||
|
||||
if (new_dft) {
|
||||
new_dft = false;
|
||||
@@ -606,8 +613,8 @@ void rx_nr_prach(PHY_VARS_gNB *gNB,
|
||||
for (int i = 0; i < NCS2; i++) {
|
||||
int lev = prach_ifft[preamble_shift2 + i];
|
||||
int levdB = dB_fixed_times10(lev);
|
||||
if (levdB>*max_preamble_energy) {
|
||||
LOG_D(PHY,"preamble_index %d, delay %d en %d dB > %d dB\n",preamble_index,i,levdB,*max_preamble_energy);
|
||||
if (levdB > *max_preamble_energy || (levdB == *max_preamble_energy && *max_preamble_delay > i)) {
|
||||
LOG_D(NR_PHY_RACH, "preamble_index %d, delay %d en %d dB > %d dB\n", preamble_index, i, levdB, *max_preamble_energy);
|
||||
*max_preamble_energy = levdB;
|
||||
*max_preamble_delay = i; // Note: This has to be normalized to the 30.72 Ms/s sampling rate
|
||||
*max_preamble = preamble_index;
|
||||
|
||||
@@ -154,6 +154,7 @@ void nr_schedule_ul_tti_req(PHY_VARS_gNB *gNB, nfapi_nr_ul_tti_request_t *UL_tti
|
||||
UL_tti_req->SFN,
|
||||
UL_tti_req->Slot);
|
||||
nfapi_nr_prach_pdu_t *prach_pdu = &UL_tti_req->pdus_list[i].prach_pdu;
|
||||
LOG_D(NR_PHY_RACH, "Add prach decoding request for %d.%d\n", UL_tti_req->SFN, UL_tti_req->Slot);
|
||||
prach_item_t *prach = nr_fill_prach(gNB, UL_tti_req->SFN, UL_tti_req->Slot, prach_pdu);
|
||||
if (prach && (gNB->RU_list[0]->if_south == LOCAL_RF || gNB->RU_list[0]->if_south == REMOTE_IF5))
|
||||
nr_fill_prach_ru(gNB->RU_list[0], prach);
|
||||
|
||||
@@ -64,8 +64,8 @@ void L1_nr_prach_procedures(PHY_VARS_gNB *gNB, int frame, int slot, nfapi_nr_rac
|
||||
return;
|
||||
}
|
||||
|
||||
LOG_D(NR_PHY, "%d.%d Got prach entry\n", frame, slot);
|
||||
nfapi_nr_prach_pdu_t *prach_pdu = &prach_id->pdu;
|
||||
LOG_D(NR_PHY_RACH, "%d.%d, prachstart slot %d prach entry occas %d\n", frame, slot, prach_id->slot, prach_pdu->num_prach_ocas);
|
||||
const int prach_start_slot = prach_id->slot;
|
||||
int N_dur = get_nr_prach_duration(prach_pdu->prach_format);
|
||||
|
||||
@@ -137,7 +137,7 @@ void L1_nr_prach_procedures(PHY_VARS_gNB *gNB, int frame, int slot, nfapi_nr_rac
|
||||
gNB->prach_energy_counter++;
|
||||
} // if prach_id>0
|
||||
rach_ind->slot = prach_start_slot;
|
||||
LOG_D(NR_PHY, "Freeing PRACH entry\n");
|
||||
LOG_D(NR_PHY_RACH, "Freeing PRACH entry\n");
|
||||
free_nr_prach_entry(&gNB->prach_list, prach_id);
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_PHY_ENB_PRACH_RX,0);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user