this article introduce install and configure srslte enb epc on ubuntu 16.04

1. install uhd

ubuntu 16.04 apt-get have uhd package but it is old version which may have problem working with new version srslte.

if you are from China, I suggest you change apt-get source to other. I use 清华大学 source which work fine for me, open /etc/apt/sources.list and replace all the content as below:

# deb cdrom:[Ubuntu 16.04 LTS _Xenial Xerus_ - Release amd64 (20160420.1)]/ xenial main restricted
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial main restricted
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates main restricted
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial universe
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates universe
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial multiverse
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates multiverse
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security main restricted
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security universe
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security multiverse

run the command below one by one:

sudo apt-get remove -y uhd
sudo apt-get remove libuhd-dev libuhd003 uhd-host -y
sudo apt-add-repository --remove "deb http://files.ettus.com/binaries/uhd/repo/uhd/ubuntu/trusty trusty main"
sudo add-apt-repository ppa:ettusresearch/uhd -y
sudo apt-get update
sudo apt-get -y --allow-unauthenticated install python python-tk libboost-all-dev libusb-1.0-0-dev
sudo apt-get -y --allow-unauthenticated install libuhd-dev libuhd003 uhd-host

download usrp firmware:

sudo uhd_images_downloader

 

2. install the required package for srslte:

sudo apt-get install cmake libfftw3-dev libmbedtls-dev libboost-program-options-dev libconfig++-dev libsctp-dev

3. download and compile srslte:

git clone https://github.com/srsLTE/srsLTE.git
cd srsLTE
mkdir build
cd build
cmake ../
make
make test
sudo make install
sudo ldconfig

4. configure epc and enb:

enb:

cp srsenb/enb.conf.example srsenb/enb.conf
cp srsenb/rr.conf.example srsenb/rr.conf
cp srsenb/sib.conf.example srsenb/sib.conf
cp srsenb/drb.conf.example srsenb/drb.conf

epc:

cp srsepc/epc.conf.example srsepc/epc.conf
cp srsepc/user_db.csv.example srsepc/user_db.csv

the default value of the conf file should be work.

5.write sim card and configure hss

use a blank lte usim card and a sim card writer and download sim card write software from GRSIMWrite 3.10.rar (2 MB). open the sim card write software

write imsi, ki, opc as you want. and click the "same with lte" button on the "GSM Parameter" part. finally click "Write Card" button.

open user_db.csv file add line in below way, (imsi), (ki), (opc) should be copy from the sim card write software.

ue3,mil,(imsi),(ki),opc,(opc),8000,000000001f24,7,dynamic

in my case it is:

ue3,mil,208920000008856,7DBAB53F6569B7588734007D6C5CE783,opc,4DDB98237B1F6B3E64D74BF85B51BF76,8000,000000001f24,7,dynamic

6. run srslte and connect ue

run epc:

cd srsLTE/srsepc
sudo srsepc epc.conf

run enb:

cd srsLTE/srsenb
sudo srsenb enb.conf

insert the written usim card to a phone then search network manually. the phone should be able to find your lte network.

7. install low latency kernel

just run:

sudo apt-get install linux-lowlatency 
sudo apt-get install linux-image-`uname -r | cut -d- -f1-2`-lowlatency 
sudo apt-get install linux-headers-`uname -r | cut -d- -f1-2`-lowlatency

 8. connect ue to internet

cd srsLTE/srsepc
sudo ./srsepc_if_masq.sh enp1s0

which enp1s0 is the network interface on pc. you need to change it to your network interface name.