mirror of
https://gitlab.eurecom.fr/oai/openairinterface5g.git
synced 2026-07-13 04:30:28 +00:00
Add PUCCH power control T traces
This commit is contained in:
@@ -217,6 +217,10 @@ ID = GNB_MAC_PUSCH_POWER_CONTROL
|
||||
DESC = NR MAC PUSCH power control-related data
|
||||
GROUP = ALL:MAC:GNB:CSV
|
||||
FORMAT = int,rnti : int,frame : int,slot : int,snrx10 : int,phr : int,tpc : int,tb_size : int,txpower_calc : int,rbSize : int,mcs : int,rssi
|
||||
ID = GNB_MAC_PUCCH_POWER_CONTROL
|
||||
DESC = NR MAC PUCCH power control-related data
|
||||
GROUP = ALL:MAC:GNB:CSV
|
||||
FORMAT = int,rnti : int,frame : int,slot : int,snrx10 : int,tpc : int,rssi
|
||||
ID = GNB_MAC_DL_RAR_PDU_WITH_DATA
|
||||
DESC = NR MAC downlink PDU for RAR
|
||||
GROUP = ALL:MAC:GNB:WIRESHARK
|
||||
|
||||
@@ -936,6 +936,14 @@ void handle_nr_uci_pucch_0_1(module_id_t mod_id, frame_t frame, slot_t slot, con
|
||||
} else
|
||||
sched_ctrl->tpc1 = 1;
|
||||
sched_ctrl->tpc1 = nr_limit_tpc(sched_ctrl->tpc1, uci_01->rssi, rssi_threshold);
|
||||
|
||||
T(T_GNB_MAC_PUCCH_POWER_CONTROL,
|
||||
T_INT(uci_01->rnti),
|
||||
T_INT(frame),
|
||||
T_INT(slot),
|
||||
T_INT(sched_ctrl->pucch_snrx10),
|
||||
T_INT(sched_ctrl->tpc1),
|
||||
T_INT(uci_01->rssi));
|
||||
}
|
||||
|
||||
// check scheduling request result, confidence_level == 0 is good
|
||||
@@ -971,6 +979,14 @@ void handle_nr_uci_pucch_2_3_4(module_id_t mod_id, frame_t frame, slot_t slot, c
|
||||
sched_ctrl->pucch_snrx10 = uci_234->ul_cqi * 5 - 640;
|
||||
sched_ctrl->tpc1 = nr_get_tpc(nrmac->radio_config.pucch.target_snrx10, uci_234->ul_cqi, 30, 0);
|
||||
sched_ctrl->tpc1 = nr_limit_tpc(sched_ctrl->tpc1, uci_234->rssi, rssi_threshold);
|
||||
|
||||
T(T_GNB_MAC_PUCCH_POWER_CONTROL,
|
||||
T_INT(uci_234->rnti),
|
||||
T_INT(frame),
|
||||
T_INT(slot),
|
||||
T_INT(sched_ctrl->pucch_snrx10),
|
||||
T_INT(sched_ctrl->tpc1),
|
||||
T_INT(uci_234->rssi));
|
||||
}
|
||||
|
||||
// TODO: handle SR
|
||||
|
||||
@@ -55,6 +55,14 @@ a `&`. In that case, it's important to run the `nr-softmodem` at second
|
||||
position, which will receive signals and stop the `csv` tracer when stopping
|
||||
the main process.
|
||||
|
||||
The script might also be used to print PUCCH SNR. This can be achieved by only
|
||||
recording the relevant fields with the `csv` tracer for trace
|
||||
`GNB_MAC_PUCCH_POWER_CONTROL
|
||||
|
||||
./common/utils/T/tracer/record -d ../common/utils/T/T_messages.txt -OFF -on GNB_MAC_PUSCH_POWER_CONTROL -on GNB_MAC_PUCCH_POWER_CONTROL -o /tmp/record.raw
|
||||
|
||||
Use the `replay` tracer and `csv` to separate into PUSCH and PUCCH traces.
|
||||
|
||||
After recovering the `pusch.csv` file, you could plot it with a script.
|
||||
|
||||
./plot-power-control.gp.sh /tmp/pusch.csv
|
||||
|
||||
Reference in New Issue
Block a user