Lab 9: Amarisoft NR intra Frequency Handover
This experiment showcases an example of running handover procedure on top of a 5G Standalone (SA) network using Amarisoft (AMR) gNBs, AMR CN, FlexRIC as the Near-RT RIC and Quectel model as an COTS UE. Additionally, an instruction to apply handover API via both terminal command line and xApp from public xApp SDK repository.
Prerequisites​
It is required to have the following components:
- 2 SDR-50 or 1 SDR-100
- Amarisoft license
- A Quectel model
Introduction​
apiVersion: athena.trirematics.io/v1
kind: Network
metadata:
name: handover
namespace: trirematics
spec:
slices:
- plmn: "00101"
dnn: internet
network-mode: IPv4
service-type: eMBB
differentiator: 0x000000
ipv4-range: 12.2.1.0/24
ipv6-range: 2001:db8:1::/64
access:
- name: gnb1
stack: 5g-sa
model: amarisoft/ran-e2
identity:
an-id: 30
tracking-area: 1
radio:
device: amr-sdr50
antenna:
tx-gain: "90.0"
rx-gain: "60.0"
cells:
- band: n78
arfcn: 637344
bandwidth: 20MHz
subcarrier-spacing: 30kHz
tdd-config:
period: 5ms
dl-slots: 7
dl-symbols: 6
ul-slots: 2
ul-symbols: 4
groups:
- kind: hog
name: handover-group
- band: n41
arfcn: 518190
bandwidth: 20MHz
subcarrier-spacing: 30kHz
tdd-config:
period: 5ms
dl-slots: 7
dl-symbols: 6
ul-slots: 2
ul-symbols: 4
groups:
- kind: hog
name: handover-group
core-networks:
- amr-cn.handover
controller: flexric.handover
scheduling:
nodeSelector:
kubernetes.io/hostname: moto
annotations:
extras.t9s.io/ssb-bitmap: "10000000"
core:
- name: amr-cn
stack: 5g-sa
model: amarisoft/basic-cn
profiles:
- debug
identity:
region: 128
cn-group: 4
cn-id: 5
edge:
- name: flexric
stack: 4g-5g
model: mosaic5g/flexric
dns:
ipv4:
default: 8.8.8.8
secondary: 8.8.4.4
---
apiVersion: athena.trirematics.io/v1
kind: Terminal
metadata:
name: quectel-001
namespace: trirematics
spec:
vendor: amr
stack: 5g-sa
model: terminal/quectel
target-cores:
- amr-cn.handover
identity:
imsi: "001010000000012"
pin: "1234"
opc: "0xC42449363BBAD02B66D16BC975D77CC1"
key: "0xfec86ba6eb707ed08905757b1bb44b8f"
sqn: "0xff9bb4000001"
slice:
dnn: internet
network-mode: IPv4
service-type: eMBB
differentiator: 0x000000
radio:
bands:
- n78
- n41
readiness-check:
method: ping
target: google-ip
Deployment​
- To run up the network
brc install network open-ran-ho-intra.yaml
- To check the network
brc observe
- Wait until all the Elements other than the UE are in the
STATUS
set to1/1 Y
state.
Handover via command line​
Example of handover API on gNB terminal
handover
Syntax: handover RAN_UE_ID pci [arfcn]
Start a handover to physical cell 'pci', using the optional DL E-ARFCN or SSB NR-ARFCN 'arfcn'.
Handover API requires 3 parameters RAN_UE_ID
, pci
and optional arfcn
.
- To use the API, user goes to interactive terminal of amarisoft RAN
brc cic amr-ran.gnb1.handover --follow ran
- To get
RAN_UE_ID
, typeue
on the terminal
(enb) ue
RAN_UE_ID CN_UE_ID Cell RNTI
- To get
pci
andarfcn
, type cell on the terminal
(enb) cell
cell
[gnb0012346] PLMN=00101 gNB_ID=0x12346
Cell RAT BAND TAC dl_arfcn pci prach_seq dl_gain ul_dis plmn
- Apply the handover command with the following command above.
For more information on these command line, please visit Amarisoft website on section 11.
Handover via xApp​
As provided, xApp SDK supports handover xApp in path /src/usr/python3/ho.py
.
# Example of ho.py
import sys
import xapp_usr_sdk as xapp
xapp.init(sys.argv)
nodes = xapp.e2_nodes(xapp.HAND_OVER_USE_CASE_e)
assert(len(nodes) > 0 and len(nodes) < 3 and "Needed at least 1 or 2 E2 nodes to handover")
sum_ue = 0
for idx in range(len(nodes)):
sum_ue += len(nodes[idx].ue_ho)
assert(sum_ue > 0 and "At least one UE needed")
idx = 0 if len(nodes[0].ue_ho) > 0 else 1
n = nodes[idx].node
ue = nodes[idx].ue_ho[0].ue
ho_pci = nodes[idx].ue_ho[0].nghbr_cell[0].target_pci
ho_ssb = nodes[idx].ue_ho[0].nghbr_cell[0].target_ssb_nr_arfcn
xapp.hand_over(n, ue, ho_pci, ho_ssb)
Similar to Amarisoft's handover command line, our handover xApp automatically extracts the UE ID, PCI, and ARFCN of the UE.
This information is used by the ho.py
script, which enables users to move the UE back and forth between two cells, by running the command multiple times.
Simple step by step to interact xApp with the cluster
-
Build the project following
README.md
file -
Bind flexric IP with xApp
cd xapp_sdk/conf/
python3 update_conf.py
# It should show this
# Select the RIC to configure:
# 1) flexric.flexric.handover (10.244.2.46)
# Choice [1-1]: 1
# No entries found for Database.
# Skipping database IP update.
# Config 'xapp.yaml' updated: ip_ric=10.244.2.46, ip_xapp=10.244.0.158
- Run the xApp
cd build/src/usr/python3
python3 mntr.py ../../../conf/xapp.yaml