1) Experiment Overview
This experiment emulates a complete 5G Standalone (SA) setup with a gNB/Core (LW1) and a single UE node (ARPN1), which collects IQ samples. The gNB starts near LW1 and moves along a predefined trajectory. This setup runs in EMULATION and is useful for validating coverage, mobility, and channel characteristics using IQ data. This experiment can be run in EMULATION or TESTBED modes. This manual specifically concerns EMULATION mode.
Ubuntu version 22.04
OAI 5G SA
UHD version 4.3
I. Configuring the gNB
Navigate to the radio scripts directory
$ cd /root/Profiles/ProfileScripts/Radio
Now copy the script to run the OAI gNB and 5G core network:
$ cp Samples/startOpen5GS-OAI-gNB.sh ./startRadio.sh
To ensure it runs during the experiment:
$ nano /root/startexperiment.sh
(This opens the master script. You must uncomment the call to `startRadio.sh`.)
Scroll down and uncomment this line:
# ./Radio/startRadio.sh
On (E-VM 2) We will clone down iq collection script to use in the following and compile the code
$ cd /root/Profiles/SDR_control/
$ git clone https://github.com/cueltschey/aerpaw-iq-collection
$ cd aerpaw-iq-collection
$ mkdir build && cd build
$ cmake ..
$ make -j$(nproc)
navigate to the script folder:
$ cd /root/Profiles/ProfileScripts/Radio
Copy the sample UE script to the standard file:
$ cp Samples/startIQCollection5G.sh startRadio.sh
Enable it in the experiment launch sequence:
$ nano /root/startexperiment.sh
Uncomment the line:
# ./Radio/startRadio.sh
Now set the UAV's flight control script:
$ cd /root/Profiles/ProfileScripts/Vehicle
$ cp Samples/startPreplannedTrajectory.sh startVehicle.sh
$ nano startVehicle.sh
Edit the following line in `startVehicle.sh` to reference the plan file of you choosing. You can also make your own flight path if you desire:
export MISSION=$PROFILE_DIR"/vehicle_control/PreplannedTrajectory/Missions/lw1-to-lw2.plan"
Uncomment startVehicle.sh from /root/startexperiment.sh
# startVehicle.sh
Once every script is in place and `startexperiment.sh` is configured, use the following commands to start and monitor the experiment.
Start the experiment on both E-VMs:
$ /root/startexperiment.sh
To monitor the experiment (on the gNB side) run tail -f on some of the results files:
$ tail -f /root/Results/<timestamp>_radio_gnb_log.txt
This will print logs as they are added, allowing you to see if the gNB has started correctly.
run the log2csv script on the output of the vehicle:
$ python3 /root/Profiles/PostProcessing/log2csv.py /root/Results/<timestamp>_vehicleOut.txt -m vehicleOut -o vehicle.csv
next we run the CSV merge script to combine the two resulting csv files based on their timestamps:
$ python3 /root/Profiles/PostProcessing/csvMerge/csvMerge.py vehicle.csv /root/Results/collected_csi.csv --output merged_result.csv
Finally this script will create a kml file that can be viewed in Google Earth:
$ python3 /root/Profiles/PostProcessing/akmlGen.py merged_result.csv --colormap jet_r --output result.kml --target rsrp_dB
To plot frequency domain of IQ:
$ python3 plot_iq_freq.py --sample_rate 23.04e6 --skip 1000 --samples 10000 /root/Results/collected_iq.fc32
To plot RSRP over time:
$ python3 plot_timeseries.py --y_data rsrp_dB --plot_label RSRP /root/Results/collected_csi.csv
to plot a 3D topology spectrogram
$ python3 plot_spectrogram_topo.py --sample_rate 23.04e6 --samples 10000 /root/Results/collected_iq.fc32
The following graphs are various representations of the collected IQ and the CSI metrics gathered from the PBCH after processing using AERPAW scripts.