Commit a8b14786 authored by mlysenko's avatar mlysenko Committed by Jerome Peraldi

Bugz #128623 - Run TTCN + gNB + OAI UE + Proxy without VT on HW setup

parent aeb1ef85
# Sequans USRP N310 Setup
This document describes how to connect the USRP N310 device and build the software and run gNB.
## 1 N310 Connection Options
The N310 comes with 4 ports that can be used for connection to the PC.
Note that some ports can be used for device management only while others for data streaming only.
* USB Console port implements 2 serial interfaces that can be used for device management only:
1. The Linux console of the ARM CPU.
2. The console of the STM32. For example, it can be used to reboot the device remotely.
The baud rate is 115200 for both interfaces. This example shows how to connect to the Linux console (`if00` interface):
$ ls /dev/serial/by-id
usb-Silicon_Labs_CP2105_Dual_USB_to_UART_Bridge_Controller_007F6CB5-if00-port0
usb-Silicon_Labs_CP2105_Dual_USB_to_UART_Bridge_Controller_007F6CB5-if01-port0
$ sudo screen /dev/serial/by-id/usb-Silicon_Labs_CP2105_Dual_USB_to_UART_Bridge_Controller_007F6CB5-if00-port0 115200
* Ethernet port provides access to the Linux console via SSH. Can be used as a management port only.
User `root`, no password.
* SFP0 can be used as a data port. The port speed depends on the variant of the FPGA firmware
(1Gb for the HG variant or 10Gb for the XG).
* SFP1 is a 10 Gb port and can be used as a data port.
Default network configuration:
| Interface | Configuration | Configuration File | Configuration File (old image ver.) |
|-----------|---------------|------------------------------|-------------------------------------|
| eth0 | dhcp | `/data/network/eth0.network` | `/etc/systemd/network/eth0.network` |
| sfp0 | 192.168.10.2 | `/data/network/sfp0.network` | `/etc/systemd/network/sfp0.network` |
| sfp1 | 192.168.20.2 | `/data/network/sfp1.network` | `/etc/systemd/network/sfp1.network` |
## 2 Connect N310
In current setup we use 10Gb SFP1 port that is connected to the `enp1s0f0` 10Gb interface of the lab PC.
1. Insert the 10Gb copper adapter to the SFP1 port and connect the port to the PC via Cat6e ethernet cable.
2. Configure the static IP address on the interface connected to the N310:
sudo ip addr add 192.168.20.1/24 dev enp1s0f0
2. Try to ping N310:
ping 192.168.20.2
## 3 Build and Install UHD Driver
UHD is a USRP host driver. We'll need its apps to update N310 firmware and libraries to build gNB.
1. Install required packages.
sudo apt install -y libboost-all-dev libusb-1.0-0-dev doxygen python3-docutils python3-mako python3-numpy python3-requests python3-ruamel.yaml python3-setuptools cmake build-essential
2. Download sources.
git clone https://github.com/EttusResearch/uhd.git ~/uhd -b v4.3.0.0
Current version is 4.3.0.0.
3. Build and install UHD.
cd ~/uhd/host
mkdir build
cd build
cmake ../
make -j
sudo make install
sudo ldconfig
4. Check if UHD can find N310.
$ uhd_find_devices
[INFO] [UHD] linux; GNU C++ version 9.4.0; Boost_107100; UHD_4.3.0.HEAD-0-g1f8fd345
--------------------------------------------------
-- UHD Device 0
--------------------------------------------------
Device Address:
serial: 327B212
addr: 192.168.10.2
claimed: False
mgmt_addr: 192.168.10.2
product: n310
type: n3xx
## 4 Update N310 Image.
It's important to update the USRP image so that it matches the UHD driver version.
The image contains the embedded Linux file system.
The easiest way is to update the file system via Mender.
1. Download image.
The `uhd_images_downloader` will download the version that matches the currently installed UHD.
sudo uhd_images_downloader -t mender -t n3xx --yes -v
If the command fails, the image can be downloaded manually.
Check the `uhd_images_downloader` output and find the following lines:
[INFO] Using base URL: https://files.ettus.com/binaries/cache/
...
[DEBUG] URLs to download:
n3xx/meta-ettus-v4.3.0.0/n3xx_common_mender_default-v4.3.0.0.zip
Combine those URLs:
wget https://files.ettus.com/binaries/cache/n3xx/meta-ettus-v4.3.0.0/n3xx_common_mender_default-v4.3.0.0.zip
unzip n3xx_common_mender_default-v4.3.0.0.zip
2. Copy image to N310.
Images downloaded with `uhd_images_downloader` are located in `/usr/local/share/uhd/images/`.
scp n3xx_common_mender_default-v4.3.0.0.zip root@192.168.10.2:/home/root
3. SSH into N310 and run the installation procedure.
ssh root@192.168.10.2
Note, command examples that must be executed on N310 contain `root@ni-n3xx-327B212:~#` prompt.
The installation is tricky because it depends on what Mender version is currently installed on N310.
First, try modern version:
root@ni-n3xx-327B212:~# mender install /home/root/usrp_n3xx_fs.mender
If it didn't work, try to run Mender using old-style command line arguments:
root@ni-n3xx-327B212:~# mender -rootfs /home/root/usrp_n3xx_fs.mender -f
4. Reboot and Validate the Installation.
root@ni-n3xx-327B212:~# reboot
After device booted, check the version:
root@ni-n3xx-327B212:~# uhd_config_info --version
root@ni-n3xx-327B212:~# cat /etc/mender/artifact_info
Mender uses A+B partitioning scheme, where one partition is active and another one is used for update.
After upgrade, the next boot runs from the newly-updated partition once.
However, we need to let Mender know that upgraded FS work fine. Otherwise, it will fall back to
the previous version after reboot:
root@ni-n3xx-327B212:~# mender -commit
## 5 Update FPGA firmware
1. Download FPGA firmware.
sudo uhd_images_downloader -t n310_fpga -v
If download failes, use the same workaround as for image downloading and unzip files to UHD inventory location.
wget https://files.ettus.com/binaries/cache/n3xx/uhd-dd757ac/n3xx_n310_fpga_default-gdd757ac.zip
sudo unzip n3xx_n310_fpga_default-gdd757ac.zip -d /usr/local/share/uhd/images
2. Update FPGA firmware
uhd_image_loader --args type=n3xx,addr=ni-n3xx-<Device_serial_addr>
where `<Device_serial_addr>` is the serial address of the USRP, which can be obtained by running `uhd_find_devices`.
## 6 Build gNB with USRP support
1. Install `lttng`.
sudo apt-add-repository ppa:lttng/stable-2.13
sudo apt update
sudo apt install -y lttng-tools lttng-modules-dkms liblttng-ust-dev
2. Obtain sources and install required packages.
git clone https://gitlab-shared.sequans.com/sequans/system/ttcn/firecell_sequansrd -b Latest_3GPP_FRD_299
cd firecell_sequansrd
./FirecellRD/components/RAN/cmake_targets/build_oai -I
If build fails while installing ASN1 because `gitlab.eurecom.fr` is inaccessible,
configure git to use gitlab-shared.sequans.com instead:
git config --global url.https://gitlab-shared.sequans.com/sequans/system/ttcn/asn1c.insteadof https://gitlab.eurecom.fr/oai/asn1c.git
3. Build gNB.
cd FirecellRD/components/RAN
. oaienv
cd cmake_targets
./build_oai -I
./build_oai -w USRP --ninja --nrUE --gNB --build-lib all -c
## 7 Run gNB
1. Run gNB (from the OAI dir):
./cmake_targets/ran_build/build/nr-softmodem -O ci-scripts/conf_files/gNB.N78.fr1.40MHz.N310.conf --sa --usrp-tx-thread-config 1 --log_config.global_log_options wall_clock
2. *Opional step, for Fibocom UE only*. Connect to the AT port:
Add `udev` rule for the Fibocom modem to prevent the ModemManager to interfere with the AT console.
Create the `/etc/udev/rules.d/99-fibocom.rules` file with following content:
ATTRS{idVendor}=="0403" ATTRS{idProduct}=="6010", ENV{ID_MM_DEVICE_IGNORE}="1"
Reload the rules:
sudo udevadm control --reload-rules
If the above method doesn't help, try to stop `ModemManager` or even to disable it:
sudo systemctl stop ModemManager
sudo systemctl disable ModemManager
Connect to the AT console:
sudo minicom -D /dev/serial/by-id/usb-Fibocom_Fibocom_FM160_Modem_SN:5033FA31_5033fa31-if02-port0
Check that band n78 is enabled
at+gtact?
+GTACT: 14,,,5078
OK
in the response we have:
- 14: enabled RATs, NR only.
- 5078: NR band n78
Set `cfun=1`:
at+cfun=1
OK
+SIM: Inserted
+C5GREG: 2
+CEREG: 2
+SIM READY
Check that 5G registration status changed from 0 to 2 (it may take up to half a minute):
at+c5greg?
+C5GREG: 2,2
OK
3. Check gNB log, it should contain the `UE State = NR_RRC_CONNECTED` message (at the end of the example below).
1692024360.127029 [NR_MAC] Frame.Slot 128.0
UE RNTI c723 (1) PH 49 dB PCMAX 21 dBm, average RSRP 0 (0 meas)
UE c723: CQI 0, RI 1, PMI (0,0)
UE c723: dlsch_rounds 178/27/27/27, dlsch_errors 27, pucch0_DTX 108, BLER 0.93539 MCS 6
UE c723: dlsch_total_bytes 20734
UE c723: ulsch_rounds 177/25/25/25, ulsch_DTX 100, ulsch_errors 25, BLER 0.92023 MCS 6
UE c723: ulsch_total_bytes_scheduled 19373, ulsch_total_bytes_received 17356
UE c723: LCID 1: 3 bytes TX
1692024360.749749 [NR_PHY] [gNB 0][RAPROC] Frame 189, slot 19 Initiating RA procedure with preamble 19, energy 46.6 dB (I0 78, thres 120), delay 7 start symbol 4 freq index 0
1692024360.749807 [MAC] UL_info[Frame 189, Slot 19] Calling initiate_ra_proc RACH:SFN/SLOT:189/19
1692024360.749814 [NR_MAC] Search for not existing rnti (ignore for RA): 37d2
1692024360.749816 [NR_MAC] [gNB 0][RAPROC] CC_id 0 Frame 189 Activating Msg2 generation in frame 190, slot 7 using RA rnti 10f SSB, new rnti 37d2 index 0 RA index 0
1692024360.750433 [NR_MAC] [gNB 0][RAPROC] CC_id 0 Frame 190, slotP 7: Generating RA-Msg2 DCI, rnti 0x10f, state 1, CoreSetType 2
1692024360.750449 [NR_MAC] [RAPROC] Msg3 slot 17: current slot 7 Msg3 frame 190 k2 7 Msg3_tda_id 3
1692024360.750456 [NR_MAC] [gNB 0][RAPROC] Frame 190, Subframe 7: rnti 37d2 RA state 2
1692024360.758679 [NR_MAC] Search for not existing rnti (ignore for RA): 37d2
1692024360.758684 [NR_MAC] Adding UE with rnti 0x37d2
1692024360.759265 [NR_MAC] [gNB 0][RAPROC] PUSCH with TC_RNTI 0x37d2 received correctly, adding UE MAC Context RNTI 0x37d2
1692024360.759271 [NR_MAC] [RAPROC] RA-Msg3 received (sdu_lenP 7)
1692024360.759275 [RLC] activated srb0 for UE with RNTI 0x37d2
1692024360.759279 [MAC] [RAPROC] Received SDU for CCCH length 6 for UE 37d2
1692024360.759344 [NR_MAC] Activating scheduling RA-Msg4 for TC_RNTI 0x37d2 (state 2)
1692024360.759346 [NR_MAC] Unexpected ULSCH HARQ PID 0 (have -1) for RNTI 0x37d2 (ignore this warning for RA)
1692024360.759353 [RRC] initial UL RRC message nr_cellid 0 does not match RRC's 12345678
1692024360.759379 [NR_RRC] Decoding CCCH: RNTI 37d2, inst 0, payload_size 6
1692024360.759655 [NR_RRC] rrc_gNB_generate_RRCSetup for RNTI 37d2
1692024360.759700 [PDCP] nr_pdcp_entity_set_security: rb_id=1 INT=0, CIP=0
1692024360.759737 [NR_MAC] Adding SchedulingRequestconfig
1692024360.759739 [NR_MAC] Adding BSR config
1692024360.759741 [NR_MAC] Adding TAG config
1692024360.759741 [NR_MAC] Adding PHR config
1692024360.759757 [RLC] /home/labo/dev/lmeyer/ttcn/openairinterface5g/openair2/LAYER2/nr_rlc/nr_rlc_oai_api.c:961:add_rlc_srb: added srb 1 to UE with RNTI 0x37d2
1692024360.759986 [NR_MAC] ( 191. 6) SRB0 has 136 bytes
1692024360.760019 [NR_MAC] Generate msg4, rnti: 37d2
1692024360.760022 [NR_MAC] Encoded RRCSetup Piggyback (136 + 2 bytes), mac_pdu_length 145
1692024360.764081 [NR_MAC] (UE RNTI 0x37d2) Received Ack of RA-Msg4. CBRA procedure succeeded!
1692024360.764089 [NR_MAC] (191.14) Activating RRC processing timer for UE 37d2 with 10 ms
1692024360.774173 [NR_MAC] (192.14) De-activating RRC processing timer for UE 37d2
1692024360.774260 [NR_MAC] Modified rnti 37d2 with CellGroup
1692024360.774263 [NR_MAC] Adding SchedulingRequestconfig
1692024360.774264 [NR_MAC] Adding BSR config
1692024360.774268 [NR_MAC] Adding TAG config
1692024360.774269 [NR_MAC] Adding PHR config
1692024360.918633 [PDCP] nr_pdcp_entity_recv_pdu: Entity security status(0): ciphering -1, integrity check -1
1692024360.918692 [PDCP] RLC => PDCP: rcvd_count=0, rcvd_sn=0: 00 00 10 00 05 df 80 10 5e 40 03 40 40 be 0a 7c 3f c0 00 04 00 00 04 65 cb 80 bc 1c 00 00 00 00 00
1692024360.918698 [PDCP] nr_pdcp_entity_recv_pdu: deciphering did not apply
1692024360.918813 [NR_RRC] [FRAME 00000][gNB][MOD 00][RNTI 37d2] RLC RB 01 --- RLC_DATA_IND 27 bytes (RRCSetupComplete) ---> RRC_gNB
1692024360.918821 [NR_RRC] [FRAME 00000][gNB][MOD 00][RNTI 37d2] [RAPROC] Logical Channel UL-DCCH, processing NR_RRCSetupComplete from UE (SRB1 Active)
1692024360.918826 [NR_RRC] [FRAME 00000][gNB][MOD 00][RNTI 37d2] UE State = NR_RRC_CONNECTED
1692024360.918833 [NGAP] No AMF is associated to the gNB
Active_gNBs = ( "gNB-OAI");
# Asn1_verbosity, choice in: none, info, annoying
Asn1_verbosity = "none";
gNBs = (
{
////////// Identification parameters:
gNB_ID = 0xe00;
gNB_name = "gNB-OAI";
// 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; sd = 1; }); });
nr_cellid = 12345678L;
# nr_cellid = 0L;
////////// Physical parameters:
ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts_XP = 1;
pusch_AntennaPorts = 1;
do_CSIRS = 0;
do_SRS = 0;
#ul_prbblacklist = "135,136,137,138"
pdcch_ConfigSIB1 = ({
controlResourceSetZero = 12;
searchSpaceZero = 10;
});
servingCellConfigCommon = (
{
# spCellConfigCommon
physCellId = 0;
# downlinkConfigCommon
# frequencyInfoDL
# this is 3300.60 MHz + 53*12*30e-3 MHz = 3954.72
absoluteFrequencySSB = 623424;#621312;
dl_frequencyBand = 78;
# this is 3900.60 MHz
dl_absoluteFrequencyPointA = 622152; #620040;
# scs-SpecificCarrierList
dl_offstToCarrier = 0;
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
dl_subcarrierSpacing = 1;
dl_carrierBandwidth = 106;
# initialDownlinkBWP
# genericParameters
initialDLBWPlocationAndBandwidth = 28875;
# 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 = 12;
preambleReceivedTargetPower = -90;
# 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 = 3;
# 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 = 1,
# restrictedSetConfig
# 0=unrestricted, 1=restricted type A, 2=restricted type B
restrictedSetConfig = 0,
msg3_DeltaPreamble = 1;
p0_NominalWithGrant =-90;
# pucch-ConfigCommon
# pucchGroupHopping
# 0 = neither, 1= group hopping, 2=sequence hopping
pucchGroupHopping = 0;
hoppingId = 40;
p0_nominal = -70;
# dmrs_TypeA_position
# 0 = pos2, 1 = pos3
dmrs_TypeA_Position = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
subcarrierSpacing = 1;
# 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;
#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;
};
////////// AMF parameters:
amf_ip_address = (
{
ipv4 = "192.168.70.132";
ipv6 = "192:168:30::17";
active = "yes";
preference = "ipv4";
}
);
NETWORK_INTERFACES :
{
GNB_INTERFACE_NAME_FOR_NG_AMF = "lo";
GNB_IPV4_ADDRESS_FOR_NG_AMF = "127.0.0.2";
GNB_INTERFACE_NAME_FOR_NGU = "lo";
GNB_IPV4_ADDRESS_FOR_NGU = "127.0.0.2";
#GNB_INTERFACE_NAME_FOR_NG_AMF = "enp6s0";
#GNB_IPV4_ADDRESS_FOR_NG_AMF = "10.87.0.21";
#GNB_INTERFACE_NAME_FOR_NGU = "enp6s0";
#GNB_IPV4_ADDRESS_FOR_NGU = "10.87.0.21";
GNB_PORT_FOR_S1U = 2152; # Spec 2152
}
}
);
# IP Address and port numbers for System Simulator
SSConfig = (
{
hostIp = "127.0.0.1"; #Host IP for System Simulator
Sys_port = 7777; #Port Number for System Simulator Sys Port
Sys_host = "127.0.0.1"; #Host for System Simulator SYS Port
Srb_port = 7778; #Port Number for System Simulator Srb Port
Srb_host = "127.0.0.1"; #Host for System Simulator SRB Port
Vng_port = 7779; #Port Number for System Simulator VNG Port
Vng_host = "127.0.0.1"; #Host for System Simulator VNG Port
# Vtp_port = 7780; #Port Number for System Simulator VTP Port
# Vtp_host = "/tmp/eNBVT.pipe"; #Host for System Simulator VTP Port
Drb_port = 7781; #Port Number for System Simulator DRB Port
Drb_host = "127.0.0.1"; #Host for System Simulator DRB Port
SSMode = 1; #SSMode: 0 - eNB , 1- SYS_PORT test , 2- Only SRB_PORT test
}
);
MACRLCs = (
{
num_cc = 1;
tr_s_preference = "local_L1";
tr_n_preference = "local_RRC";
pusch_TargetSNRx10 = 300;
pucch_TargetSNRx10 = 200;
pusch_FailureThres = 100;
ulsch_max_frame_inactivity = 10;
ul_max_mcs = 28;
#dl_harq_round_max = 1;
#ul_harq_round_max = 1;
}
);
L1s = (
{
num_cc = 1;
tr_n_preference = "local_mac";
prach_dtx_threshold = 120;
pucch0_dtx_threshold = 80;
}
);
RUs = (
{
local_rf = "yes"
nb_tx = 1;
nb_rx = 1;
att_tx = 0;
att_rx = 0;
bands = [78];
max_pdschReferenceSignalPower = -27;
max_rxgain = 75;
eNB_instances = [0];
##beamforming 1x2 matrix: 1 layer x 2 antennas
bf_weights = [0x00007fff, 0x0000];
#clock_src = "internal";
sdr_addrs = "mgmt_addr=192.168.20.2,addr=192.168.20.2,clock_source=internal,time_source=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";
};
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";
hw_log_level ="info";
phy_log_level ="info";
mac_log_level ="info";
rlc_log_level ="info";
pdcp_log_level ="info";
rrc_log_level ="info";
ngap_log_level ="debug";
f1ap_log_level ="info";
};
Active_gNBs = ( "gNB-OAI");
# Asn1_verbosity, choice in: none, info, annoying
Asn1_verbosity = "none";
gNBs = (
{
////////// Identification parameters:
gNB_ID = 0xe00;
gNB_name = "gNB-OAI";
// 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; sd = 1; }); });
nr_cellid = 12345678L;
////////// Physical parameters:
ssb_SubcarrierOffset = 0;
pdsch_AntennaPorts_XP = 1;
pusch_AntennaPorts = 1;
do_CSIRS = 0;
do_SRS = 0;
#ul_prbblacklist = "135,136,137,138"
pdcch_ConfigSIB1 = ({
controlResourceSetZero = 12;
searchSpaceZero = 10;
});
servingCellConfigCommon = (
{
# spCellConfigCommon
physCellId = 0;
# downlinkConfigCommon
# frequencyInfoDL
# this is 3300.60 MHz + 53*12*30e-3 MHz = 3954.72
absoluteFrequencySSB = 623424;#621312;
dl_frequencyBand = 78;
# this is 3900.60 MHz
dl_absoluteFrequencyPointA = 622152; #620040;
# scs-SpecificCarrierList
dl_offstToCarrier = 0;
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
dl_subcarrierSpacing = 1;
dl_carrierBandwidth = 106;
# initialDownlinkBWP
# genericParameters
initialDLBWPlocationAndBandwidth = 28875;
# 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 = 12;
preambleReceivedTargetPower = -90;
# 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 = 3;
# 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 = 1,
# restrictedSetConfig
# 0=unrestricted, 1=restricted type A, 2=restricted type B
restrictedSetConfig = 0,
msg3_DeltaPreamble = 1;
p0_NominalWithGrant =-90;
# pucch-ConfigCommon
# pucchGroupHopping
# 0 = neither, 1= group hopping, 2=sequence hopping
pucchGroupHopping = 0;
hoppingId = 40;
p0_nominal = -70;
# dmrs_TypeA_position
# 0 = pos2, 1 = pos3
dmrs_TypeA_Position = 0;
# subcarrierSpacing
# 0=kHz15, 1=kHz30, 2=kHz60, 3=kHz120
subcarrierSpacing = 1;
# 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;
#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;
};
////////// AMF parameters:
amf_ip_address = (
{
ipv4 = "192.168.70.132";
ipv6 = "192:168:30::17";
active = "yes";
preference = "ipv4";
}
);
NETWORK_INTERFACES :
{
GNB_INTERFACE_NAME_FOR_NG_AMF = "enp6s0";
GNB_IPV4_ADDRESS_FOR_NG_AMF = "10.87.0.21";
GNB_INTERFACE_NAME_FOR_NGU = "enp6s0";
GNB_IPV4_ADDRESS_FOR_NGU = "10.87.0.21";
GNB_PORT_FOR_S1U = 2152; # Spec 2152
}
}
);
MACRLCs = (
{
num_cc = 1;
tr_s_preference = "local_L1";
tr_n_preference = "local_RRC";
pusch_TargetSNRx10 = 300;
pucch_TargetSNRx10 = 200;
pusch_FailureThres = 100;
ulsch_max_frame_inactivity = 10;
ul_max_mcs = 28;
#dl_harq_round_max = 1;
#ul_harq_round_max = 1;
}
);
L1s = (
{
num_cc = 1;
tr_n_preference = "local_mac";
prach_dtx_threshold = 120;
pucch0_dtx_threshold = 80;
}
);
RUs = (
{
local_rf = "yes"
nb_tx = 1;
nb_rx = 1;
att_tx = 0;
att_rx = 0;
bands = [78];
max_pdschReferenceSignalPower = -27;
max_rxgain = 75;
eNB_instances = [0];
##beamforming 1x2 matrix: 1 layer x 2 antennas
bf_weights = [0x00007fff, 0x0000];
#clock_src = "internal";
sdr_addrs = "mgmt_addr=192.168.20.2,addr=192.168.20.2,clock_source=internal,time_source=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";
};
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";
hw_log_level ="info";
phy_log_level ="info";
mac_log_level ="info";
rlc_log_level ="info";
pdcp_log_level ="info";
rrc_log_level ="info";
ngap_log_level ="debug";
f1ap_log_level ="info";
};
......@@ -1368,7 +1368,9 @@ void fill_initial_cellGroupConfig(int uid,
cellGroupConfig->cellGroupId = 0;
if (RC.ss.mode >= SS_SOFTMODEM) {
/* Rlc Bearer Config */
/* TS38.331 9.2.1 Default SRB configurations */
if (RC.ss.mode == SS_SOFTMODEM) {
NR_RLC_BearerConfig_t * ss_rlc_BearerConfig = NULL;
/*SRB1 SS RLC_BearerConfig */
int rbIndex = 1;
......@@ -1391,7 +1393,8 @@ void fill_initial_cellGroupConfig(int uid,
cellGroupConfig->sCellToReleaseList = NULL;
return;
*/
}else {
} else {
/* We cover OAI native setup and TTCN SRB port "only" configuration */
/* Rlc Bearer Config */
/* TS38.331 9.2.1 Default SRB configurations */
cellGroupConfig->rlc_BearerToAddModList = calloc(1, sizeof(*cellGroupConfig->rlc_BearerToAddModList));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment