From 1cb14c3d9cb4e8fa288557c04b2530a925eb952f Mon Sep 17 00:00:00 2001 From: Gabriele Perrone Date: Wed, 1 Apr 2020 13:26:26 +0200 Subject: [PATCH 1/2] Update README.md --- targets/ARCH/rfsimulator/README.md | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/targets/ARCH/rfsimulator/README.md b/targets/ARCH/rfsimulator/README.md index e3ce219d73..ce2a4c9616 100644 --- a/targets/ARCH/rfsimulator/README.md +++ b/targets/ARCH/rfsimulator/README.md @@ -3,6 +3,12 @@ This is an RF simulator that allows to test OAI without an RF board. It replaces As much as possible, it works like an RF board, but not in real-time: It can run faster than real-time if there is enough CPU, or slower (it is CPU-bound instead of real-time RF sampling-bound). +It can be run either in: + +- "noS1" mode: the generated IP traffic is sent and received between gNB and UE IP tunnel interfaces ("oaitun") by applications like ping and iperf +- "phy-test" mode: random UL and DL traffic is generated at every scheduling opportunity + + # build ## From [build_oai](../../../doc/BUILD.md) script @@ -84,16 +90,19 @@ make rfsimulator ### Launch gNB in one window ```bash -sudo RFSIMULATOR=server ./nr-softmodem -O ../../../targets/PROJECTS/GENERIC-LTE-EPC/CONF/gnb.band78.tm1.106PRB.usrpn300.conf --parallel-config PARALLEL_SINGLE_THREAD +sudo RFSIMULATOR=server ./nr-softmodem -O ../../../targets/PROJECTS/GENERIC-LTE-EPC/CONF/gnb.band78.tm1.106PRB.usrpn300.conf --parallel-config PARALLEL_SINGLE_THREAD --rfsim --phy-test ``` ### Launch UE in another window ```bash -sudo RFSIMULATOR=127.0.0.1 ./nr-uesoftmodem --numerology 1 -r 106 -C 3510000000 +sudo RFSIMULATOR= ./nr-uesoftmodem --rfsim --phy-test --rrc_config_path ../../../ci-scripts/rrc-files ``` +Note: +1. can be 127.0.0.1 if both gNB and nrUE executables run on the same host, OR the IP interface address of the remote host running the gNB executable, if the gNB and nrUE run on separate hosts +2. the --rrc_config_path parameter can be omitted (but not necessarily) if the gNB and nrUE run on the same host, in which case the gNB provides the nrUE with the necessary rrc configuration +3. to enable the noS1 mode --noS1 and --nokrnmod 1 options should be added to the command line -Of course, set the gNB machine IP address if the UE and the gNB are not on the same machine. In the UE, you can add `-d` option to get the softscope. From 36bf56d4108ff2cca3850a8a2d5e85711a9c3784 Mon Sep 17 00:00:00 2001 From: Gabriele Perrone Date: Wed, 1 Apr 2020 14:59:09 +0200 Subject: [PATCH 2/2] Update README.md --- targets/ARCH/rfsimulator/README.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/targets/ARCH/rfsimulator/README.md b/targets/ARCH/rfsimulator/README.md index ce2a4c9616..a4b030af85 100644 --- a/targets/ARCH/rfsimulator/README.md +++ b/targets/ARCH/rfsimulator/README.md @@ -106,6 +106,24 @@ Note: In the UE, you can add `-d` option to get the softscope. +### Testing IP traffic (ping and iperf) + +``` +ping -I oaitun_enb1 10.0.1.2 (from gNB mchine) +ping -I oaitun_ue1 10.0.1.1 (from nrUE mchine) +``` + +```iperf (Downlink): +Server nrUE machine: iperf -s -i 1 -u -B 10.0.1.2 +Client gNB machine: iperf -c 10.0.1.2 -u -b 0.1M --bind 10.0.1.1 +``` + +```iperf (Uplink): +Server gNB machine: iperf -s -i 1 -u -B 10.0.1.1 +Client nrUE machine: iperf -c 10.0.1.1 -u -b 0.1M --bind 10.0.1.2 +Note: iperf tests cannot be performed only when running gNB and nrUE on separate hosts. +``` + ### Store and replay You can store emitted I/Q samples. If you set the option `saviq`, the simulator will write all the I/Q samples into this file. Then, you can replay with the executable `replay_node`.