Commit 9c21ceac authored by Rohit Gupta's avatar Rohit Gupta

Merge branch 'develop' into bugfix-96-Fix-build-script-for-16.04-installation-v3

parents cdb182c1 566fd451
This diff is collapsed.
...@@ -33,6 +33,7 @@ ...@@ -33,6 +33,7 @@
import time import time
import serial import serial
import os import os
from socket import AF_INET
from pyroute2 import IPRoute from pyroute2 import IPRoute
import sys import sys
import re import re
...@@ -62,7 +63,7 @@ def find_open_port(): ...@@ -62,7 +63,7 @@ def find_open_port():
while True: while True:
if os.path.exists(serial_port) == True: if os.path.exists(serial_port) == True:
return serial_port return serial_port
for port in range(2,100): for port in range(0,100):
serial_port_tmp = '/dev/ttyUSB'+str(port) serial_port_tmp = '/dev/ttyUSB'+str(port)
if os.path.exists(serial_port_tmp) == True: if os.path.exists(serial_port_tmp) == True:
print 'New Serial Port : ' + serial_port_tmp print 'New Serial Port : ' + serial_port_tmp
...@@ -97,11 +98,12 @@ signal.signal(signal.SIGINT, signal_handler) ...@@ -97,11 +98,12 @@ signal.signal(signal.SIGINT, signal_handler)
#ser.isOpen() #ser.isOpen()
class pppThread (threading.Thread): class pppThread (threading.Thread):
def __init__(self, threadID, name, counter): def __init__(self, threadID, name, counter,port):
threading.Thread.__init__(self) threading.Thread.__init__(self)
self.threadID = threadID self.threadID = threadID
self.name = name self.name = name
self.counter = counter self.counter = counter
self.port=port
def run(self): def run(self):
print "Starting " + self.name print "Starting " + self.name
#Here we keep running pppd thread in indefinite loop as this script terminates sometimes #Here we keep running pppd thread in indefinite loop as this script terminates sometimes
...@@ -111,6 +113,10 @@ class pppThread (threading.Thread): ...@@ -111,6 +113,10 @@ class pppThread (threading.Thread):
print "Starting wvdial now..." print "Starting wvdial now..."
print 'exit_flag = ' + str(exit_flag) print 'exit_flag = ' + str(exit_flag)
send_command('AT+CGATT=1','OK', 300) send_command('AT+CGATT=1','OK', 300)
#Now we do search and replace on wvdial config file
cmd="sed -i \"s%Modem = .*%Modem = " + self.port + "%g\" " + bandrich_ppd_config
os.system(cmd)
os.system('wvdial -C ' + bandrich_ppd_config + '' ) os.system('wvdial -C ' + bandrich_ppd_config + '' )
if exit_flag == 1: if exit_flag == 1:
print "Exit flag set to true. Exiting pppThread now" print "Exit flag set to true. Exiting pppThread now"
...@@ -146,6 +152,7 @@ def send_command (cmd, response, timeout): ...@@ -146,6 +152,7 @@ def send_command (cmd, response, timeout):
def start_ue () : def start_ue () :
#print 'Enter your commands below.\r\nInsert "exit" to leave the application.' #print 'Enter your commands below.\r\nInsert "exit" to leave the application.'
global serial_port
timeout=60 #timeout in seconds timeout=60 #timeout in seconds
send_command('AT', 'OK' , timeout) send_command('AT', 'OK' , timeout)
send_command('AT+CFUN=1' , 'OK' , timeout) send_command('AT+CFUN=1' , 'OK' , timeout)
...@@ -153,23 +160,33 @@ def start_ue () : ...@@ -153,23 +160,33 @@ def start_ue () :
send_command('AT+CGATT=1','OK', 300) send_command('AT+CGATT=1','OK', 300)
#os.system('wvdial -C ' + bandrich_ppd_config + ' &' ) #os.system('wvdial -C ' + bandrich_ppd_config + ' &' )
thread_ppp = pppThread(1, "ppp_thread", 1) thread_ppp = pppThread(1, "ppp_thread", 1,port=serial_port)
thread_ppp.start() thread_ppp.start()
iface='ppp0' #iface='ppp0'
while 1: while 1:
time.sleep ( 2) time.sleep ( 2)
iface=''
#Now we check if ppp0 interface is up and running #Now we check if ppp0 interface is up and running
try: try:
if exit_flag == 1: if exit_flag == 1:
break break
cmd="ifconfig -a | sed 's/[ \t].*//;/^$/d' | grep ppp"
status, out = commands.getstatusoutput(cmd)
iface=out
ip = IPRoute() ip = IPRoute()
idx = ip.link_lookup(ifname=iface)[0] idx = ip.link_lookup(ifname=iface)[0]
os.system ('route add ' + gw + ' ppp0') print "iface = " + iface
print " Setting route now..."
#os.system("status=1; while [ \"$status\" -ne \"0\" ]; do route add -host " + gw + ' ' + iface + " ; status=$? ;sleep 1; echo \"status = $status\" ; sleep 2; done ")
os.system ('route add -host ' + gw + ' ' + iface + ' 2> /dev/null')
#ip.route('add', dst=gw, oif=iface)
os.system('sleep 5') os.system('sleep 5')
os.system ('ping ' + gw) #print "Starting ping now..."
break os.system ('ping -c 1 ' + gw)
#break
except Exception, e: except Exception, e:
error = ' Interface ' + iface + 'does not exist...' error = ' Interface ' + iface + 'does not exist...'
error = error + ' In function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e) error = error + ' In function: ' + sys._getframe().f_code.co_name + ': *** Caught exception: ' + str(e.__class__) + " : " + str( e)
...@@ -206,6 +223,7 @@ def reset_ue(): ...@@ -206,6 +223,7 @@ def reset_ue():
os.system(cmd + " ; sleep 15" ) os.system(cmd + " ; sleep 15" )
cmd = "sudo sh -c \"echo 1 > " + usb_dir + "/authorized\"" cmd = "sudo sh -c \"echo 1 > " + usb_dir + "/authorized\""
os.system(cmd + " ; sleep 30" ) os.system(cmd + " ; sleep 30" )
find_open_port()
stop_ue() stop_ue()
i=1 i=1
...@@ -213,14 +231,17 @@ gw='192.172.0.1' ...@@ -213,14 +231,17 @@ gw='192.172.0.1'
while i < len(sys.argv): while i < len(sys.argv):
arg=sys.argv[i] arg=sys.argv[i]
if arg == '--start-ue' : if arg == '--start-ue' :
print "Turning on UE..."
find_open_port() find_open_port()
print 'Using Serial port : ' + serial_port print 'Using Serial port : ' + serial_port
start_ue() start_ue()
elif arg == '--stop-ue' : elif arg == '--stop-ue' :
print "Turning off UE..."
find_open_port() find_open_port()
print 'Using Serial port : ' + serial_port print 'Using Serial port : ' + serial_port
stop_ue() stop_ue()
elif arg == '--reset-ue' : elif arg == '--reset-ue' :
print "Resetting UE..."
find_open_port() find_open_port()
reset_ue() reset_ue()
elif arg == '-gw' : elif arg == '-gw' :
......
#!/usr/bin/python
#******************************************************************************
# OpenAirInterface
# Copyright(c) 1999 - 2014 Eurecom
# OpenAirInterface is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# OpenAirInterface is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with OpenAirInterface.The full GNU General Public License is
# included in this distribution in the file called "COPYING". If not,
# see <http://www.gnu.org/licenses/>.
# Contact Information
# OpenAirInterface Admin: openair_admin@eurecom.fr
# OpenAirInterface Tech : openair_tech@eurecom.fr
# OpenAirInterface Dev : openair4g-devel@lists.eurecom.fr
# Address : Eurecom, Campus SophiaTech, 450 Route des Chappes, CS 50193 - 06904 Biot Sophia Antipolis cedex, FRANCE
# *******************************************************************************/
# \author Navid Nikaein, Rohit Gupta
import time
import serial
import os
from pyroute2 import IPRoute
import sys
import re
import threading
import signal
import traceback
import os
import commands
# configure the serial connections (the parameters differs on the device you are connecting to)
#First we find an open port to work with
serial_port=''
openair_dir = os.environ.get('OPENAIR_DIR')
if openair_dir == None:
print "Error getting OPENAIR_DIR environment variable"
sys.exit(1)
sys.path.append(os.path.expandvars('$OPENAIR_DIR/cmake_targets/autotests/tools/'))
from lib_autotest import *
#Stop the USB BUS of USRPB210
def stop_usrpb210():
stringIdBandrich='National Instruments Corp.'
status, out = commands.getstatusoutput('lsusb | grep -i \'' + stringIdBandrich + '\'')
if (out == '') :
print "USRP B210 not found. Exiting now..."
sys.exit()
p=re.compile('Bus\s*(\w+)\s*Device\s*(\w+):\s*ID\s*(\w+):(\w+)')
res=p.findall(out)
BusId=res[0][0]
DeviceId=res[0][1]
VendorId=res[0][2]
ProductId=res[0][3]
usb_dir= find_usb_path(VendorId, ProductId)
print "USRP B210 found in..." + usb_dir
cmd = "sudo sh -c \"echo 0 > " + usb_dir + "/authorized\""
os.system(cmd)
#Start the USB bus of USRP B210
def start_usrpb210():
stringIdBandrich='National Instruments Corp.'
status, out = commands.getstatusoutput('lsusb | grep -i \'' + stringIdBandrich + '\'')
if (out == '') :
print "USRP B210 not found. Exiting now..."
sys.exit()
p=re.compile('Bus\s*(\w+)\s*Device\s*(\w+):\s*ID\s*(\w+):(\w+)')
res=p.findall(out)
BusId=res[0][0]
DeviceId=res[0][1]
VendorId=res[0][2]
ProductId=res[0][3]
usb_dir= find_usb_path(VendorId, ProductId)
print "USRP B210 found in..." + usb_dir
cmd = "sudo sh -c \"echo 1 > " + usb_dir + "/authorized\""
os.system(cmd)
i=1
while i < len(sys.argv):
arg=sys.argv[i]
if arg == '--start-usrpb210' :
start_usrpb210()
elif arg == '--stop-usrpb210' :
stop_usrpb210()
elif arg == '-h' :
print "--stop-usrpb210: Stop the USRP B210. It cannot be found in uhd_find_devices"
print "--start-usrpb210: Start the USRP B210. It can now be found in uhd_find_devices"
else :
print " Script called with wrong arguments, arg = " + arg
sys.exit()
i = i +1
...@@ -265,7 +265,25 @@ check_install_additional_tools (){ ...@@ -265,7 +265,25 @@ check_install_additional_tools (){
valgrind \ valgrind \
vlan \ vlan \
ctags \ ctags \
ntpdate ntpdate \
iperf3 \
android-tools-adb
$SUDO pip install paramiko
$SUDO pip install pyroute2
$SUDO rm -fr /opt/ssh
$SUDO git clone https://gist.github.com/2190472.git /opt/ssh
log_netiface=$OPENAIR_DIR/cmake_targets/log/netiface_install_log.txt
echo_info "Installing Netinterfaces package. The logfile for installation is in $log_netiface"
(
$SUDO rm -fr /tmp/netifaces-0.10.4.tar.gz /tmp/netifaces
wget -P /tmp https://pypi.python.org/packages/18/fa/dd13d4910aea339c0bb87d2b3838d8fd923c11869b1f6e741dbd0ff3bc00/netifaces-0.10.4.tar.gz
tar -xzvf /tmp/netifaces-0.10.4.tar.gz -C /tmp
cd /tmp/netifaces-0.10.4
$SUDO python setup.py install
cd -
) >& $log_netiface
} }
check_install_oai_software() { check_install_oai_software() {
...@@ -350,8 +368,7 @@ check_install_oai_software() { ...@@ -350,8 +368,7 @@ check_install_oai_software() {
python-numpy \ python-numpy \
sshpass \ sshpass \
libxslt1-dev \ libxslt1-dev \
android-tools-adb \ android-tools-adb
iperf3
$SUDO update-alternatives --set liblapack.so /usr/lib/atlas-base/atlas/liblapack.so $SUDO update-alternatives --set liblapack.so /usr/lib/atlas-base/atlas/liblapack.so
...@@ -360,11 +377,7 @@ check_install_oai_software() { ...@@ -360,11 +377,7 @@ check_install_oai_software() {
install_nettle_from_source install_nettle_from_source
install_gnutls_from_source install_gnutls_from_source
$SUDO pip install paramiko
$SUDO pip install pyroute2
install_asn1c_from_source install_asn1c_from_source
$SUDO rm -fr /opt/ssh
$SUDO git clone https://gist.github.com/2190472.git /opt/ssh
} }
install_asn1c_from_source(){ install_asn1c_from_source(){
...@@ -372,14 +385,12 @@ install_asn1c_from_source(){ ...@@ -372,14 +385,12 @@ install_asn1c_from_source(){
echo_info "\nInstalling ASN1. The log file for ASN1 installation is here: $asn1_install_log " echo_info "\nInstalling ASN1. The log file for ASN1 installation is here: $asn1_install_log "
( (
$SUDO rm -rf /tmp/asn1c-r1516 $SUDO rm -rf /tmp/asn1c-r1516
mkdir -p /tmp/asn1c-r1516 svn co https://github.com/vlm/asn1c/trunk /tmp/asn1c-r1516 -r 1516
cd /tmp/asn1c-r1516 cd /tmp/asn1c-r1516
rm -rf /tmp/asn1c-r1516/* patch -p0 < $OPENAIR_DIR/openair3/S1AP/MESSAGES/ASN1/asn1cpatch.p0
svn co https://github.com/vlm/asn1c/trunk /tmp/asn1c-r1516 -r 1516 > /tmp/log_compile_asn1c patch -p0 < $OPENAIR_DIR/openair3/S1AP/MESSAGES/ASN1/asn1cpatch_2.p0
patch -p0 < $OPENAIR_DIR/openair3/S1AP/MESSAGES/ASN1/asn1cpatch.p0 >> /tmp/log_compile_asn1c patch -p0 < $OPENAIR_DIR/openair2/RRC/LITE/MESSAGES/asn1c/asn1cpatch.p0
patch -p0 < $OPENAIR_DIR/openair3/S1AP/MESSAGES/ASN1/asn1cpatch_2.p0 >> /tmp/log_compile_asn1c patch -p0 < $OPENAIR_DIR/openair3/S1AP/MESSAGES/ASN1/asn1cpatch_3.p0
patch -p0 < $OPENAIR_DIR/openair2/RRC/LITE/MESSAGES/asn1c/asn1cpatch.p0 >> /tmp/log_compile_asn1c
patch -p0 < $OPENAIR_DIR/openair3/S1AP/MESSAGES/ASN1/asn1cpatch_3.p0 >> /tmp/log_compile_asn1c
./configure ./configure
make -j`nproc` make -j`nproc`
$SUDO make install $SUDO make install
......
...@@ -29,10 +29,10 @@ typedef struct { ...@@ -29,10 +29,10 @@ typedef struct {
#define T_SHM_FILENAME "/T_shm_segment" #define T_SHM_FILENAME "/T_shm_segment"
/* number of VCD functions (to be kept up to date! see in T_messages.txt) */ /* number of VCD functions (to be kept up to date! see in T_messages.txt) */
#define VCD_NUM_FUNCTIONS 139 #define VCD_NUM_FUNCTIONS 146
/* number of VCD variables (to be kept up to date! see in T_messages.txt) */ /* number of VCD variables (to be kept up to date! see in T_messages.txt) */
#define VCD_NUM_VARIABLES 45 #define VCD_NUM_VARIABLES 99
/* first VCD function (to be kept up to date! see in T_messages.txt) */ /* first VCD function (to be kept up to date! see in T_messages.txt) */
#define VCD_FIRST_FUNCTION ((uintptr_t)T_VCD_FUNCTION_RT_SLEEP) #define VCD_FIRST_FUNCTION ((uintptr_t)T_VCD_FUNCTION_RT_SLEEP)
......
This diff is collapsed.
...@@ -9,7 +9,7 @@ int main(void) ...@@ -9,7 +9,7 @@ int main(void)
T_connect_to_tracer("127.0.0.1", 2020); T_connect_to_tracer("127.0.0.1", 2020);
while (1) { while (1) {
getchar(); getchar();
T(T_PUCCH_1AB_IQ, T_INT(0), T_INT(0), T_INT(frame), T_INT(0), T_INT(0), T_INT(0)); T(T_ENB_PHY_PUCCH_1AB_IQ, T_INT(0), T_INT(0), T_INT(frame), T_INT(0), T_INT(0), T_INT(0));
frame++; frame++;
} }
return 0; return 0;
......
...@@ -129,7 +129,7 @@ static void enb_main_gui(enb_gui *e, gui *g, event_handler *h, void *database) ...@@ -129,7 +129,7 @@ static void enb_main_gui(enb_gui *e, gui *g, event_handler *h, void *database)
widget_add_child(g, line, input_signal_plot, -1); widget_add_child(g, line, input_signal_plot, -1);
xy_plot_set_range(g, input_signal_plot, 0, 7680*10, 20, 70); xy_plot_set_range(g, input_signal_plot, 0, 7680*10, 20, 70);
input_signal_log = new_framelog(h, database, input_signal_log = new_framelog(h, database,
"ENB_INPUT_SIGNAL", "subframe", "rxdata"); "ENB_PHY_INPUT_SIGNAL", "subframe", "rxdata");
/* a skip value of 10 means to process 1 frame over 10, that is /* a skip value of 10 means to process 1 frame over 10, that is
* more or less 10 frames per second * more or less 10 frames per second
*/ */
...@@ -151,40 +151,40 @@ static void enb_main_gui(enb_gui *e, gui *g, event_handler *h, void *database) ...@@ -151,40 +151,40 @@ static void enb_main_gui(enb_gui *e, gui *g, event_handler *h, void *database)
new_color(g, i==0 || i==4 ? "#aaf" : "#eee")); new_color(g, i==0 || i==4 ? "#aaf" : "#eee"));
timeview = new_view_time(3600, 10, g, timeline_plot); timeview = new_view_time(3600, 10, g, timeline_plot);
/* DL tick logging */ /* DL tick logging */
timelog = new_timelog(h, database, "ENB_DL_TICK"); timelog = new_timelog(h, database, "ENB_PHY_DL_TICK");
subview = new_subview_time(timeview, 0, new_color(g, "#77c"), 3600*1000); subview = new_subview_time(timeview, 0, new_color(g, "#77c"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
/* DL DCI logging */ /* DL DCI logging */
timelog = new_timelog(h, database, "ENB_DLSCH_UE_DCI"); timelog = new_timelog(h, database, "ENB_PHY_DLSCH_UE_DCI");
subview = new_subview_time(timeview, 1, new_color(g, "#228"), 3600*1000); subview = new_subview_time(timeview, 1, new_color(g, "#228"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
/* DL ACK */ /* DL ACK */
timelog = new_timelog(h, database, "ENB_DLSCH_UE_ACK"); timelog = new_timelog(h, database, "ENB_PHY_DLSCH_UE_ACK");
subview = new_subview_time(timeview, 2, new_color(g, "#282"), 3600*1000); subview = new_subview_time(timeview, 2, new_color(g, "#282"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
/* DL NACK */ /* DL NACK */
timelog = new_timelog(h, database, "ENB_DLSCH_UE_NACK"); timelog = new_timelog(h, database, "ENB_PHY_DLSCH_UE_NACK");
subview = new_subview_time(timeview, 3, new_color(g, "#f22"), 3600*1000); subview = new_subview_time(timeview, 3, new_color(g, "#f22"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
/* UL tick logging */ /* UL tick logging */
timelog = new_timelog(h, database, "ENB_UL_TICK"); timelog = new_timelog(h, database, "ENB_PHY_UL_TICK");
subview = new_subview_time(timeview, 4, new_color(g, "#77c"), 3600*1000); subview = new_subview_time(timeview, 4, new_color(g, "#77c"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
/* UL DCI logging */ /* UL DCI logging */
timelog = new_timelog(h, database, "ENB_ULSCH_UE_DCI"); timelog = new_timelog(h, database, "ENB_PHY_ULSCH_UE_DCI");
subview = new_subview_time(timeview, 5, new_color(g, "#228"), 3600*1000); subview = new_subview_time(timeview, 5, new_color(g, "#228"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
/* UL retransmission without DCI logging */ /* UL retransmission without DCI logging */
timelog = new_timelog(h, database, "ENB_ULSCH_UE_NO_DCI_RETRANSMISSION"); timelog = new_timelog(h,database,"ENB_PHY_ULSCH_UE_NO_DCI_RETRANSMISSION");
subview = new_subview_time(timeview, 5, new_color(g, "#f22"), 3600*1000); subview = new_subview_time(timeview, 5, new_color(g, "#f22"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
/* UL ACK */ /* UL ACK */
timelog = new_timelog(h, database, "ENB_ULSCH_UE_ACK"); timelog = new_timelog(h, database, "ENB_PHY_ULSCH_UE_ACK");
subview = new_subview_time(timeview, 6, new_color(g, "#282"), 3600*1000); subview = new_subview_time(timeview, 6, new_color(g, "#282"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
/* UL NACK */ /* UL NACK */
timelog = new_timelog(h, database, "ENB_ULSCH_UE_NACK"); timelog = new_timelog(h, database, "ENB_PHY_ULSCH_UE_NACK");
subview = new_subview_time(timeview, 7, new_color(g, "#f22"), 3600*1000); subview = new_subview_time(timeview, 7, new_color(g, "#f22"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
...@@ -212,72 +212,73 @@ static void enb_main_gui(enb_gui *e, gui *g, event_handler *h, void *database) ...@@ -212,72 +212,73 @@ static void enb_main_gui(enb_gui *e, gui *g, event_handler *h, void *database)
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
/* DL harq pids */ /* DL harq pids */
for (i = 0; i < 8; i++) { for (i = 0; i < 8; i++) {
timelog = new_ticklog(h, database, "ENB_DLSCH_UE_DCI", timelog = new_ticklog(h, database, "ENB_PHY_DLSCH_UE_DCI",
"frame", "subframe"); "frame", "subframe");
subview = new_subview_ticktime(timeview, i+1, subview = new_subview_ticktime(timeview, i+1,
new_color(g,"#55f"), 3600*1000); new_color(g,"#55f"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
logger_set_filter(timelog, logger_set_filter(timelog,
ticktime_filter(database, "ENB_DLSCH_UE_DCI", i)); ticktime_filter(database, "ENB_PHY_DLSCH_UE_DCI", i));
} }
/* DL ACK */ /* DL ACK */
for (i = 0; i < 8; i++) { for (i = 0; i < 8; i++) {
timelog = new_ticklog(h, database, "ENB_DLSCH_UE_ACK", timelog = new_ticklog(h, database, "ENB_PHY_DLSCH_UE_ACK",
"frame", "subframe"); "frame", "subframe");
subview = new_subview_ticktime(timeview, i+1, subview = new_subview_ticktime(timeview, i+1,
new_color(g,"#282"), 3600*1000); new_color(g,"#282"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
logger_set_filter(timelog, logger_set_filter(timelog,
ticktime_filter(database, "ENB_DLSCH_UE_ACK", i)); ticktime_filter(database, "ENB_PHY_DLSCH_UE_ACK", i));
} }
/* DL NACK */ /* DL NACK */
for (i = 0; i < 8; i++) { for (i = 0; i < 8; i++) {
timelog = new_ticklog(h, database, "ENB_DLSCH_UE_NACK", timelog = new_ticklog(h, database, "ENB_PHY_DLSCH_UE_NACK",
"frame", "subframe"); "frame", "subframe");
subview = new_subview_ticktime(timeview, i+1, subview = new_subview_ticktime(timeview, i+1,
new_color(g,"#f22"), 3600*1000); new_color(g,"#f22"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
logger_set_filter(timelog, logger_set_filter(timelog,
ticktime_filter(database, "ENB_DLSCH_UE_NACK", i)); ticktime_filter(database, "ENB_PHY_DLSCH_UE_NACK", i));
} }
/* UL harq pids */ /* UL harq pids */
for (i = 0; i < 8; i++) { for (i = 0; i < 8; i++) {
/* first transmission */ /* first transmission */
timelog = new_ticklog(h, database, "ENB_ULSCH_UE_DCI", timelog = new_ticklog(h, database, "ENB_PHY_ULSCH_UE_DCI",
"frame", "subframe"); "frame", "subframe");
subview = new_subview_ticktime(timeview, i+9+1, subview = new_subview_ticktime(timeview, i+9+1,
new_color(g,"#55f"), 3600*1000); new_color(g,"#55f"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
logger_set_filter(timelog, logger_set_filter(timelog,
ticktime_filter(database, "ENB_ULSCH_UE_DCI", i)); ticktime_filter(database, "ENB_PHY_ULSCH_UE_DCI", i));
/* retransmission */ /* retransmission */
timelog = new_ticklog(h, database, "ENB_ULSCH_UE_NO_DCI_RETRANSMISSION", timelog = new_ticklog(h, database,
"frame", "subframe"); "ENB_PHY_ULSCH_UE_NO_DCI_RETRANSMISSION", "frame", "subframe");
subview = new_subview_ticktime(timeview, i+9+1, subview = new_subview_ticktime(timeview, i+9+1,
new_color(g,"#99f"), 3600*1000); new_color(g,"#99f"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
logger_set_filter(timelog, logger_set_filter(timelog,
ticktime_filter(database, "ENB_ULSCH_UE_NO_DCI_RETRANSMISSION", i)); ticktime_filter(database,
"ENB_PHY_ULSCH_UE_NO_DCI_RETRANSMISSION", i));
} }
/* UL ACK */ /* UL ACK */
for (i = 0; i < 8; i++) { for (i = 0; i < 8; i++) {
timelog = new_ticklog(h, database, "ENB_ULSCH_UE_ACK", timelog = new_ticklog(h, database, "ENB_PHY_ULSCH_UE_ACK",
"frame", "subframe"); "frame", "subframe");
subview = new_subview_ticktime(timeview, i+9+1, subview = new_subview_ticktime(timeview, i+9+1,
new_color(g,"#282"), 3600*1000); new_color(g,"#282"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
logger_set_filter(timelog, logger_set_filter(timelog,
ticktime_filter(database, "ENB_ULSCH_UE_ACK", i)); ticktime_filter(database, "ENB_PHY_ULSCH_UE_ACK", i));
} }
/* UL NACK */ /* UL NACK */
for (i = 0; i < 8; i++) { for (i = 0; i < 8; i++) {
timelog = new_ticklog(h, database, "ENB_ULSCH_UE_NACK", timelog = new_ticklog(h, database, "ENB_PHY_ULSCH_UE_NACK",
"frame", "subframe"); "frame", "subframe");
subview = new_subview_ticktime(timeview, i+9+1, subview = new_subview_ticktime(timeview, i+9+1,
new_color(g,"#f22"), 3600*1000); new_color(g,"#f22"), 3600*1000);
logger_add_view(timelog, subview); logger_add_view(timelog, subview);
logger_set_filter(timelog, logger_set_filter(timelog,
ticktime_filter(database, "ENB_ULSCH_UE_NACK", i)); ticktime_filter(database, "ENB_PHY_ULSCH_UE_NACK", i));
} }
/* phy/mac/rlc/pdcp/rrc textlog */ /* phy/mac/rlc/pdcp/rrc textlog */
...@@ -446,30 +447,30 @@ int main(int n, char **v) ...@@ -446,30 +447,30 @@ int main(int n, char **v)
free(desc); free(desc);
} }
on_off(database, "ENB_INPUT_SIGNAL", is_on, 1); on_off(database, "ENB_PHY_INPUT_SIGNAL", is_on, 1);
on_off(database, "ENB_DL_TICK", is_on, 1); on_off(database, "ENB_PHY_DL_TICK", is_on, 1);
on_off(database, "ENB_DLSCH_UE_DCI", is_on, 1); on_off(database, "ENB_PHY_DLSCH_UE_DCI", is_on, 1);
on_off(database, "ENB_DLSCH_UE_ACK", is_on, 1); on_off(database, "ENB_PHY_DLSCH_UE_ACK", is_on, 1);
on_off(database, "ENB_DLSCH_UE_NACK", is_on, 1); on_off(database, "ENB_PHY_DLSCH_UE_NACK", is_on, 1);
on_off(database, "ENB_UL_TICK", is_on, 1); on_off(database, "ENB_PHY_UL_TICK", is_on, 1);
on_off(database, "ENB_ULSCH_UE_DCI", is_on, 1); on_off(database, "ENB_PHY_ULSCH_UE_DCI", is_on, 1);
on_off(database, "ENB_ULSCH_UE_NO_DCI_RETRANSMISSION", is_on, 1); on_off(database, "ENB_PHY_ULSCH_UE_NO_DCI_RETRANSMISSION", is_on, 1);
on_off(database, "ENB_ULSCH_UE_ACK", is_on, 1); on_off(database, "ENB_PHY_ULSCH_UE_ACK", is_on, 1);
on_off(database, "ENB_ULSCH_UE_NACK", is_on, 1); on_off(database, "ENB_PHY_ULSCH_UE_NACK", is_on, 1);
on_off(database, "ENB_MASTER_TICK", is_on, 1); on_off(database, "ENB_MASTER_TICK", is_on, 1);
on_off(database, "LEGACY_RRC_INFO", is_on, 1); on_off(database, "LEGACY_RRC_INFO", is_on, 1);
on_off(database, "LEGACY_RRC_ERROR", is_on, 1); on_off(database, "LEGACY_RRC_ERROR", is_on, 1);
on_off(database, "LEGACY_RRC_WARNING", is_on, 1); on_off(database, "LEGACY_RRC_WARNING", is_on, 1);
view_add_log(eg.phyview, "ENB_DLSCH_UE_DCI", h, database, is_on); view_add_log(eg.phyview, "ENB_PHY_DLSCH_UE_DCI", h, database, is_on);
view_add_log(eg.phyview, "ENB_DLSCH_UE_ACK", h, database, is_on); view_add_log(eg.phyview, "ENB_PHY_DLSCH_UE_ACK", h, database, is_on);
view_add_log(eg.phyview, "ENB_DLSCH_UE_NACK", h, database, is_on); view_add_log(eg.phyview, "ENB_PHY_DLSCH_UE_NACK", h, database, is_on);
view_add_log(eg.phyview, "ENB_ULSCH_UE_DCI", h, database, is_on); view_add_log(eg.phyview, "ENB_PHY_ULSCH_UE_DCI", h, database, is_on);
view_add_log(eg.phyview, "ENB_ULSCH_UE_NO_DCI_RETRANSMISSION", view_add_log(eg.phyview, "ENB_PHY_ULSCH_UE_NO_DCI_RETRANSMISSION",
h, database, is_on); h, database, is_on);
view_add_log(eg.phyview, "ENB_ULSCH_UE_ACK", h, database, is_on); view_add_log(eg.phyview, "ENB_PHY_ULSCH_UE_ACK", h, database, is_on);
view_add_log(eg.phyview, "ENB_ULSCH_UE_NACK", h, database, is_on); view_add_log(eg.phyview, "ENB_PHY_ULSCH_UE_NACK", h, database, is_on);
view_add_log(eg.macview, "ENB_MAC_UE_DL_SDU", h, database, is_on); view_add_log(eg.macview, "ENB_MAC_UE_DL_SDU", h, database, is_on);
view_add_log(eg.macview, "ENB_MAC_UE_UL_SCHEDULE", h, database, is_on); view_add_log(eg.macview, "ENB_MAC_UE_UL_SCHEDULE", h, database, is_on);
......
...@@ -159,7 +159,7 @@ int main(int n, char **v) ...@@ -159,7 +159,7 @@ int main(int n, char **v)
char *name, *desc; char *name, *desc;
database_get_generic_description(database, i, &name, &desc); database_get_generic_description(database, i, &name, &desc);
textlog = new_textlog(h, database, name, desc); textlog = new_textlog(h, database, name, desc);
// "ENB_UL_CHANNEL_ESTIMATE", // "ENB_PHY_UL_CHANNEL_ESTIMATE",
// "ev: {} eNB_id [eNB_ID] frame [frame] subframe [subframe]"); // "ev: {} eNB_id [eNB_ID] frame [frame] subframe [subframe]");
logger_add_view(textlog, out); logger_add_view(textlog, out);
free(name); free(name);
......