enb: add basic TDD config option
this patch adds the basic notion of FDD and TDD duplexing modes to the eNB object. So far we've always assume FDD. Since only Amarisoft eNB supports TDD, the required config template changes, etc. are only applied there. The patch also adds a scenario to enable the default TDD config. Change-Id: I37216b5bfdf527d221913283b6c41d3c8fd6b500
This commit is contained in:
parent
66c054288b
commit
d0682bad0f
|
@ -30,6 +30,9 @@ def on_register_schemas():
|
|||
'gtp_bind_addr': schema.IPV4,
|
||||
'id': schema.UINT,
|
||||
'num_prb': schema.UINT,
|
||||
'duplex': schema.STR,
|
||||
'tdd_uldl_config': schema.UINT,
|
||||
'tdd_special_subframe_pattern': schema.UINT,
|
||||
'transmission_mode': schema.LTE_TRANSMISSION_MODE,
|
||||
'tx_gain': schema.UINT,
|
||||
'rx_gain': schema.UINT,
|
||||
|
@ -83,6 +86,7 @@ class eNodeB(log.Origin, metaclass=ABCMeta):
|
|||
self.set_name('%s_%s' % (name, self._run_node.run_addr()))
|
||||
self._txmode = 0
|
||||
self._id = None
|
||||
self._duplex = None
|
||||
self._num_prb = 0
|
||||
self._num_cells = None
|
||||
self._epc = None
|
||||
|
@ -144,6 +148,8 @@ class eNodeB(log.Origin, metaclass=ABCMeta):
|
|||
config.overlay(values, dict(enb=self._conf))
|
||||
self._id = int(values['enb'].get('id', None))
|
||||
assert self._id is not None
|
||||
self._duplex = values['enb'].get('duplex', None)
|
||||
assert self._duplex
|
||||
self._num_prb = int(values['enb'].get('num_prb', None))
|
||||
assert self._num_prb
|
||||
self._txmode = int(values['enb'].get('transmission_mode', None))
|
||||
|
|
|
@ -263,6 +263,12 @@ class AmarisoftENB(enb.eNodeB):
|
|||
return rfemu_obj
|
||||
|
||||
def ue_max_rate(self, downlink=True, num_carriers=1):
|
||||
if self._duplex == 'fdd':
|
||||
return self.ue_max_rate_fdd(downlink, num_carriers)
|
||||
else:
|
||||
return self.ue_max_rate_tdd(downlink, num_carriers)
|
||||
|
||||
def ue_max_rate_fdd(self, downlink, num_carriers):
|
||||
# The max rate for a single UE per PRB configuration in TM1 with MCS 28 QAM64
|
||||
max_phy_rate_tm1_dl = { 6 : 3.2e6,
|
||||
15 : 9.2e6,
|
||||
|
@ -299,4 +305,19 @@ class AmarisoftENB(enb.eNodeB):
|
|||
|
||||
return max_rate
|
||||
|
||||
def ue_max_rate_tdd(self, downlink, num_carriers):
|
||||
# Max rate calculation for TDD depends on the acutal TDD configuration
|
||||
# See: https://www.sharetechnote.com/html/Handbook_LTE_ThroughputCalculationExample_TDD.html
|
||||
# and https://i0.wp.com/www.techtrained.com/wp-content/uploads/2017/09/Blog_Post_1_TDD_Max_Throughput_Theoretical.jpg
|
||||
max_phy_rate_tdd_uldl_config0_sp0 = { 6 : 1.5e6,
|
||||
15 : 3.7e6,
|
||||
25 : 6.1e6,
|
||||
50 : 12.2e6,
|
||||
75 : 18.4e6,
|
||||
100 : 54.5e6 }
|
||||
if downlink:
|
||||
max_rate = max_phy_rate_tdd_uldl_config0_sp0[self.num_prb()]
|
||||
else:
|
||||
return 1e6 # dummy value, we need to replace that later
|
||||
|
||||
# vim: expandtab tabstop=4 shiftwidth=4
|
||||
|
|
|
@ -100,6 +100,11 @@
|
|||
"${'{0:03}'.format(int(enb.mcc))}${'{0:02}'.format(int(enb.mnc))}",
|
||||
],
|
||||
|
||||
% if enb.get('duplex') == "tdd":
|
||||
uldl_config: ${enb.tdd_uldl_config},
|
||||
sp_config: ${enb.tdd_special_subframe_pattern},
|
||||
% endif
|
||||
|
||||
% if int(enb.get('transmission_mode')) == 1:
|
||||
n_antenna_dl: 1, /* number of DL antennas */
|
||||
n_antenna_ul: 1, /* number of UL antennas */
|
||||
|
@ -180,7 +185,10 @@
|
|||
/* TDD ack/nack feedback mode when a rel 10 UE is detected. It
|
||||
can be "bundling", "multiplexing", "cs" or "pucch3". By
|
||||
default is it the same as tdd_ack_nack_feedback_mode. */
|
||||
% if enb.get('duplex') == "tdd":
|
||||
tdd_ack_nack_feedback_mode: "bundling",
|
||||
// tdd_ack_nack_feedback_mode_r10: "cs",
|
||||
% endif
|
||||
|
||||
/* number of PUCCH 1b CS resources. It determines
|
||||
the maximum number of UEs that can be scheduled in one TTI
|
||||
|
|
|
@ -110,6 +110,7 @@ enb:
|
|||
id: 0x19B
|
||||
mcc: 901
|
||||
mnc: 70
|
||||
duplex: fdd
|
||||
transmission_mode: 1
|
||||
num_cells: 1
|
||||
inactivity_timer: 20000
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
# TDD cell
|
||||
modifiers:
|
||||
enb:
|
||||
- duplex: tdd
|
||||
tdd_uldl_config: 0
|
||||
tdd_special_subframe_pattern: 4
|
||||
cell_list:
|
||||
- cell_id: 0x01
|
||||
pci: 0x01
|
||||
dl_earfcn: 40620
|
||||
rf_port: 0
|
||||
scell_list: []
|
||||
ncell_list: []
|
Loading…
Reference in New Issue