Commit ebb30df8 authored by Raphael Defosseux's avatar Raphael Defosseux

Merge remote-tracking branch 'origin/421-cdrx-for-lte' into develop_integration_2019_w17

parents 1fea702c 489726d0
...@@ -37,7 +37,7 @@ eNBs = ...@@ -37,7 +37,7 @@ eNBs =
nb_antennas_tx = 1; nb_antennas_tx = 1;
nb_antennas_rx = 1; nb_antennas_rx = 1;
tx_gain = 90; tx_gain = 90;
rx_gain = 125; rx_gain = 115;
prach_root = 0; prach_root = 0;
prach_config_index = 0; prach_config_index = 0;
prach_high_speed = "DISABLE"; prach_high_speed = "DISABLE";
...@@ -183,8 +183,8 @@ MACRLCs = ( ...@@ -183,8 +183,8 @@ MACRLCs = (
tr_s_preference = "local_L1"; tr_s_preference = "local_L1";
tr_n_preference = "local_RRC"; tr_n_preference = "local_RRC";
scheduler_mode = "fairRR"; scheduler_mode = "fairRR";
puSch10xSnr = 200; puSch10xSnr = 150;
puCch10xSnr = 200; puCch10xSnr = 150;
} }
); );
......
...@@ -183,8 +183,8 @@ MACRLCs = ( ...@@ -183,8 +183,8 @@ MACRLCs = (
tr_s_preference = "local_L1"; tr_s_preference = "local_L1";
tr_n_preference = "local_RRC"; tr_n_preference = "local_RRC";
scheduler_mode = "fairRR"; scheduler_mode = "fairRR";
puSch10xSnr = 200; puSch10xSnr = 150;
puCch10xSnr = 200; puCch10xSnr = 150;
} }
); );
...@@ -204,7 +204,7 @@ RUs = ( ...@@ -204,7 +204,7 @@ RUs = (
att_rx = 0; att_rx = 0;
bands = [38]; bands = [38];
max_pdschReferenceSignalPower = -27; max_pdschReferenceSignalPower = -27;
max_rxgain = 115; max_rxgain = 125;
eNB_instances = [0]; eNB_instances = [0];
} }
......
...@@ -37,7 +37,7 @@ eNBs = ...@@ -37,7 +37,7 @@ eNBs =
nb_antennas_tx = 1; nb_antennas_tx = 1;
nb_antennas_rx = 1; nb_antennas_rx = 1;
tx_gain = 90; tx_gain = 90;
rx_gain = 125; rx_gain = 120;
prach_root = 0; prach_root = 0;
prach_config_index = 0; prach_config_index = 0;
prach_high_speed = "DISABLE"; prach_high_speed = "DISABLE";
...@@ -183,8 +183,8 @@ MACRLCs = ( ...@@ -183,8 +183,8 @@ MACRLCs = (
tr_s_preference = "local_L1"; tr_s_preference = "local_L1";
tr_n_preference = "local_RRC"; tr_n_preference = "local_RRC";
scheduler_mode = "fairRR"; scheduler_mode = "fairRR";
puSch10xSnr = 200; puSch10xSnr = 150;
puCch10xSnr = 200; puCch10xSnr = 150;
} }
); );
...@@ -204,7 +204,7 @@ RUs = ( ...@@ -204,7 +204,7 @@ RUs = (
att_rx = 0; att_rx = 0;
bands = [38]; bands = [38];
max_pdschReferenceSignalPower = -27; max_pdschReferenceSignalPower = -27;
max_rxgain = 115; max_rxgain = 120;
eNB_instances = [0]; eNB_instances = [0];
} }
......
...@@ -94,6 +94,14 @@ eNBs = ...@@ -94,6 +94,14 @@ eNBs =
pcch_default_PagingCycle = 128; pcch_default_PagingCycle = 128;
pcch_nB = "oneT"; pcch_nB = "oneT";
drx_Config_present = "prSetup"; //"prSetup" "prRelease"
drx_onDurationTimer = "psf1"; // "psfX": X=1,2,3,4,5,6,8,10,20,30,40,50,60,80,100
drx_InactivityTimer = "psf1"; // "psfX": X=1,2,3,4,5,6,8,10,20,30,40,50,60,80,100,200,300,500,750,1280,1920,2560
drx_RetransmissionTimer = "psf1"; // "psfX": X=1,2,4,6,8,16,24,33
drx_longDrx_CycleStartOffset_present = "prSf128"; // "psfX": X=10,20,32,40,64,80,128,160,256,320,512,640,1024,1280,2048,2560
drx_longDrx_CycleStartOffset = 0; // X >= 0 && X < drx_longDrx_CycleStartOffset_present
drx_shortDrx_Cycle = "sf16"; // "sfX": X=2,5,8,10,16,20,32,40,64,80,128,160,256,320,512,640
drx_shortDrx_ShortCycleTimer = 3; // 1..16 integer. Total duration in short cycle = drx_shortDrx_Cycle*drx_shortDrx_ShortCycleTimer [subframe]
bcch_modificationPeriodCoeff = 2; bcch_modificationPeriodCoeff = 2;
ue_TimersAndConstants_t300 = 1000; ue_TimersAndConstants_t300 = 1000;
ue_TimersAndConstants_t301 = 1000; ue_TimersAndConstants_t301 = 1000;
......
...@@ -2137,6 +2137,7 @@ class SSHConnection(): ...@@ -2137,6 +2137,7 @@ class SSHConnection():
uciStatMsgCount = 0 uciStatMsgCount = 0
pdcpFailure = 0 pdcpFailure = 0
ulschFailure = 0 ulschFailure = 0
cdrxActivationMessageCount = 0
self.htmleNBFailureMsg = '' self.htmleNBFailureMsg = ''
for line in enb_log_file.readlines(): for line in enb_log_file.readlines():
if self.rruOptions != '': if self.rruOptions != '':
...@@ -2188,6 +2189,9 @@ class SSHConnection(): ...@@ -2188,6 +2189,9 @@ class SSHConnection():
result = re.search('LTE_RRCConnectionReestablishmentReject', str(line)) result = re.search('LTE_RRCConnectionReestablishmentReject', str(line))
if result is not None: if result is not None:
rrcReestablishReject += 1 rrcReestablishReject += 1
result = re.search('CDRX configuration activated after RRC Connection', str(line))
if result is not None:
cdrxActivationMessageCount += 1
result = re.search('uci->stat', str(line)) result = re.search('uci->stat', str(line))
if result is not None: if result is not None:
uciStatMsgCount += 1 uciStatMsgCount += 1
...@@ -2242,6 +2246,10 @@ class SSHConnection(): ...@@ -2242,6 +2246,10 @@ class SSHConnection():
rrcMsg = ' -- ' + str(rrcReestablishReject) + ' were rejected' rrcMsg = ' -- ' + str(rrcReestablishReject) + ' were rejected'
logging.debug('\u001B[1;30;43m ' + rrcMsg + ' \u001B[0m') logging.debug('\u001B[1;30;43m ' + rrcMsg + ' \u001B[0m')
self.htmleNBFailureMsg += rrcMsg + '\n' self.htmleNBFailureMsg += rrcMsg + '\n'
if cdrxActivationMessageCount > 0:
rrcMsg = 'eNB activated the CDRX Configuration for ' + str(cdrxActivationMessageCount) + ' time(s)'
logging.debug('\u001B[1;30;43m ' + rrcMsg + ' \u001B[0m')
self.htmleNBFailureMsg += rrcMsg + '\n'
if rachCanceledProcedure > 0: if rachCanceledProcedure > 0:
rachMsg = 'eNB cancelled ' + str(rachCanceledProcedure) + ' RA procedure(s)' rachMsg = 'eNB cancelled ' + str(rachCanceledProcedure) + ' RA procedure(s)'
logging.debug('\u001B[1;30;43m ' + rachMsg + ' \u001B[0m') logging.debug('\u001B[1;30;43m ' + rachMsg + ' \u001B[0m')
......
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
<htmlTabIcon>tasks</htmlTabIcon> <htmlTabIcon>tasks</htmlTabIcon>
<TestCaseRequestedList> <TestCaseRequestedList>
040101 040101
030104 040301 040501 040602 040601 040603 040642 040641 040643 040401 040201 030201 030104 040301 040501 040602 040601 040603 040604 040605 040642 040641 040643 040644 040645 040401 040201 030201
</TestCaseRequestedList> </TestCaseRequestedList>
<TestCaseExclusionList></TestCaseExclusionList> <TestCaseExclusionList></TestCaseExclusionList>
...@@ -92,6 +92,21 @@ ...@@ -92,6 +92,21 @@
<iperf_profile>unbalanced</iperf_profile> <iperf_profile>unbalanced</iperf_profile>
</testCase> </testCase>
<testCase id="040604">
<class>Iperf</class>
<desc>iperf (5MHz - DL/TCP)(30 sec)(single-ue profile)</desc>
<iperf_args>-t 30 -i 1 -fm</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>single-ue</iperf_profile>
</testCase>
<testCase id="040605">
<class>Iperf</class>
<desc>iperf (5MHz - DL/TCP)(30 sec)</desc>
<iperf_args>-t 30 -i 1 -fm</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
</testCase>
<testCase id="040641"> <testCase id="040641">
<class>Iperf</class> <class>Iperf</class>
<desc>iperf (5MHz - UL/2Mbps/UDP)(30 sec)(balanced)</desc> <desc>iperf (5MHz - UL/2Mbps/UDP)(30 sec)(balanced)</desc>
...@@ -116,4 +131,19 @@ ...@@ -116,4 +131,19 @@
<iperf_profile>unbalanced</iperf_profile> <iperf_profile>unbalanced</iperf_profile>
</testCase> </testCase>
<testCase id="040644">
<class>Iperf</class>
<desc>iperf (5MHz - UL/TCP)(30 sec)(single-ue)</desc>
<iperf_args>-t 30 -i 1 -fm -R</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>single-ue</iperf_profile>
</testCase>
<testCase id="040645">
<class>Iperf</class>
<desc>iperf (5MHz - UL/TCP)(30 sec)</desc>
<iperf_args>-t 30 -i 1 -fm -R</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
</testCase>
</testCaseList> </testCaseList>
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
<htmlTabIcon>tasks</htmlTabIcon> <htmlTabIcon>tasks</htmlTabIcon>
<TestCaseRequestedList> <TestCaseRequestedList>
040101 040101
030114 040301 040511 040612 040611 040613 040652 040651 040653 040401 040201 030201 030114 040301 040511 040612 040611 040613 040614 040615 040652 040651 040653 040654 040655 040401 040201 030201
</TestCaseRequestedList> </TestCaseRequestedList>
<TestCaseExclusionList></TestCaseExclusionList> <TestCaseExclusionList></TestCaseExclusionList>
...@@ -92,6 +92,21 @@ ...@@ -92,6 +92,21 @@
<iperf_profile>unbalanced</iperf_profile> <iperf_profile>unbalanced</iperf_profile>
</testCase> </testCase>
<testCase id="040614">
<class>Iperf</class>
<desc>iperf (10MHz - DL/TCP)(30 sec)(single-ue)</desc>
<iperf_args>-t 30 -i 1 -fm</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>single-ue</iperf_profile>
</testCase>
<testCase id="040615">
<class>Iperf</class>
<desc>iperf (10MHz - DL/TCP)(30 sec)</desc>
<iperf_args>-t 30 -i 1 -fm</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
</testCase>
<testCase id="040651"> <testCase id="040651">
<class>Iperf</class> <class>Iperf</class>
<desc>iperf (10MHz - UL/2Mbps/UDP)(30 sec)(balanced)</desc> <desc>iperf (10MHz - UL/2Mbps/UDP)(30 sec)(balanced)</desc>
...@@ -116,4 +131,19 @@ ...@@ -116,4 +131,19 @@
<iperf_profile>unbalanced</iperf_profile> <iperf_profile>unbalanced</iperf_profile>
</testCase> </testCase>
<testCase id="040654">
<class>Iperf</class>
<desc>iperf (10MHz - UL/TCP)(30 sec)(single-ue)</desc>
<iperf_args>-t 30 -i 1 -fm -R</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>single-ue</iperf_profile>
</testCase>
<testCase id="040655">
<class>Iperf</class>
<desc>iperf (10MHz - UL/TCP)(30 sec)</desc>
<iperf_args>-t 30 -i 1 -fm -R</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
</testCase>
</testCaseList> </testCaseList>
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
<htmlTabIcon>tasks</htmlTabIcon> <htmlTabIcon>tasks</htmlTabIcon>
<TestCaseRequestedList> <TestCaseRequestedList>
040101 040101
030124 040301 040521 040622 040621 040623 040662 040661 040663 040401 040201 030201 030124 040301 040521 040622 040621 040623 040624 040625 040662 040661 040663 040664 040665 040401 040201 030201
</TestCaseRequestedList> </TestCaseRequestedList>
<TestCaseExclusionList></TestCaseExclusionList> <TestCaseExclusionList></TestCaseExclusionList>
...@@ -92,6 +92,21 @@ ...@@ -92,6 +92,21 @@
<iperf_profile>unbalanced</iperf_profile> <iperf_profile>unbalanced</iperf_profile>
</testCase> </testCase>
<testCase id="040624">
<class>Iperf</class>
<desc>iperf (20MHz - DL/TCP)(30 sec)(single-ue)</desc>
<iperf_args>-t 30 -i 1 -fm</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>single-ue</iperf_profile>
</testCase>
<testCase id="040625">
<class>Iperf</class>
<desc>iperf (20MHz - DL/TCP)(30 sec)</desc>
<iperf_args>-t 30 -i 1 -fm</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
</testCase>
<testCase id="040661"> <testCase id="040661">
<class>Iperf</class> <class>Iperf</class>
<desc>iperf (20MHz - UL/2Mbps/UDP)(30 sec)(balanced)</desc> <desc>iperf (20MHz - UL/2Mbps/UDP)(30 sec)(balanced)</desc>
...@@ -116,4 +131,19 @@ ...@@ -116,4 +131,19 @@
<iperf_profile>unbalanced</iperf_profile> <iperf_profile>unbalanced</iperf_profile>
</testCase> </testCase>
<testCase id="040664">
<class>Iperf</class>
<desc>iperf (20MHz - UL/TCP)(30 sec)(single-ue)</desc>
<iperf_args>-t 30 -i 1 -fm -R</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
<iperf_profile>single-ue</iperf_profile>
</testCase>
<testCase id="040665">
<class>Iperf</class>
<desc>iperf (20MHz - UL/TCP)(30 sec)</desc>
<iperf_args>-t 30 -i 1 -fm -R</iperf_args>
<iperf_packetloss_threshold>50</iperf_packetloss_threshold>
</testCase>
</testCaseList> </testCaseList>
...@@ -189,7 +189,15 @@ const char* eurecomVariablesNames[] = { ...@@ -189,7 +189,15 @@ const char* eurecomVariablesNames[] = {
"ue0_trx_write_ns_missing", "ue0_trx_write_ns_missing",
"enb_thread_rxtx_CPUID", "enb_thread_rxtx_CPUID",
"ru_thread_CPUID", "ru_thread_CPUID",
"ru_thread_tx_CPUID" "ru_thread_tx_CPUID",
"ue0_on_duration_timer",
"ue0_drx_inactivity",
"ue0_drx_short_cycle",
"ue0_short_drx_cycle_number",
"ue0_drx_long_cycle",
"ue0_drx_retransmission_harq0",
"ue0_drx_active_time",
"ue0_drx_active_time_condition"
}; };
const char* eurecomFunctionsNames[] = { const char* eurecomFunctionsNames[] = {
......
...@@ -167,6 +167,14 @@ typedef enum { ...@@ -167,6 +167,14 @@ typedef enum {
VCD_SIGNAL_DUMPER_VARIABLES_CPUID_ENB_THREAD_RXTX, VCD_SIGNAL_DUMPER_VARIABLES_CPUID_ENB_THREAD_RXTX,
VCD_SIGNAL_DUMPER_VARIABLES_CPUID_RU_THREAD, VCD_SIGNAL_DUMPER_VARIABLES_CPUID_RU_THREAD,
VCD_SIGNAL_DUMPER_VARIABLES_CPUID_RU_THREAD_TX, VCD_SIGNAL_DUMPER_VARIABLES_CPUID_RU_THREAD_TX,
VCD_SIGNAL_DUMPER_VARIABLES_ON_DURATION_TIMER,
VCD_SIGNAL_DUMPER_VARIABLES_DRX_INACTIVITY,
VCD_SIGNAL_DUMPER_VARIABLES_DRX_SHORT_CYCLE,
VCD_SIGNAL_DUMPER_VARIABLES_SHORT_DRX_CYCLE_NUMBER,
VCD_SIGNAL_DUMPER_VARIABLES_DRX_LONG_CYCLE,
VCD_SIGNAL_DUMPER_VARIABLES_DRX_RETRANSMISSION_HARQ0,
VCD_SIGNAL_DUMPER_VARIABLES_DRX_ACTIVE_TIME,
VCD_SIGNAL_DUMPER_VARIABLES_DRX_ACTIVE_TIME_CONDITION,
VCD_SIGNAL_DUMPER_VARIABLES_END VCD_SIGNAL_DUMPER_VARIABLES_END
} vcd_signal_dump_variables; } vcd_signal_dump_variables;
......
...@@ -44,7 +44,7 @@ typedef struct { ...@@ -44,7 +44,7 @@ typedef struct {
#define VCD_NUM_FUNCTIONS 190 #define VCD_NUM_FUNCTIONS 190
/* 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 128 #define VCD_NUM_VARIABLES 136
/* 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)
......
...@@ -1676,6 +1676,46 @@ ID = VCD_VARIABLE_CPUID_RU_THREAD_TX ...@@ -1676,6 +1676,46 @@ ID = VCD_VARIABLE_CPUID_RU_THREAD_TX
GROUP = ALL:VCD:ENB:VCD_VARIABLE GROUP = ALL:VCD:ENB:VCD_VARIABLE
FORMAT = ulong,value FORMAT = ulong,value
VCD_NAME = ru_thread_tx_CPUID VCD_NAME = ru_thread_tx_CPUID
ID = VCD_VARIABLE_ON_DURATION_TIMER
DESC = VCD variable ON_DURATION_TIMER
GROUP = ALL:VCD:ENB:VCD_VARIABLE
FORMAT = ulong,value
VCD_NAME = ue0_on_duration_timer
ID = VCD_VARIABLE_DRX_INACTIVITY
DESC = VCD variable DRX_INACTIVITY
GROUP = ALL:VCD:ENB:VCD_VARIABLE
FORMAT = ulong,value
VCD_NAME = ue0_drx_inactivity
ID = VCD_VARIABLE_DRX_SHORT_CYCLE
DESC = VCD variable DRX_SHORT_CYCLE
GROUP = ALL:VCD:ENB:VCD_VARIABLE
FORMAT = ulong,value
VCD_NAME = ue0_drx_short_cycle
ID = VCD_VARIABLE_SHORT_DRX_CYCLE_NUMBER
DESC = VCD variable SHORT_DRX_CYCLE_NUMBER
GROUP = ALL:VCD:ENB:VCD_VARIABLE
FORMAT = ulong,value
VCD_NAME = ue0_short_drx_cycle_number
ID = VCD_VARIABLE_DRX_LONG_CYCLE
DESC = VCD variable DRX_LONG_CYCLE
GROUP = ALL:VCD:ENB:VCD_VARIABLE
FORMAT = ulong,value
VCD_NAME = ue0_drx_long_cycle
ID = VCD_VARIABLE_DRX_RETRANSMISSION_HARQ0
DESC = VCD variable DRX_RETRANSMISSION_HARQ0
GROUP = ALL:VCD:ENB:VCD_VARIABLE
FORMAT = ulong,value
VCD_NAME = ue0_drx_retransmission_harq0
ID = VCD_VARIABLE_DRX_ACTIVE_TIME
DESC = VCD variable DRX_ACTIVE_TIME
GROUP = ALL:VCD:ENB:VCD_VARIABLE
FORMAT = ulong,value
VCD_NAME = ue0_drx_active_time
ID = VCD_VARIABLE_DRX_ACTIVE_TIME_CONDITION
DESC = VCD variable DRX_ACTIVE_TIME_CONDITION
GROUP = ALL:VCD:ENB:VCD_VARIABLE
FORMAT = ulong,value
VCD_NAME = ue0_drx_active_time_condition
#functions #functions
......
...@@ -72,6 +72,7 @@ The MAC layer implements a subset of the **3GPP 36.321** release v8.6 in support ...@@ -72,6 +72,7 @@ The MAC layer implements a subset of the **3GPP 36.321** release v8.6 in support
- RLC interface (AM, UM) - RLC interface (AM, UM)
- UL power control - UL power control
- Link adaptation - Link adaptation
- Connected DRX (CDRX) support for FDD LTE UE. Compatible with R13 from 3GPP. Support for Cat-M1 UE comming soon.
## eNB RLC Layer ## ## eNB RLC Layer ##
......
...@@ -115,10 +115,10 @@ void init_mpdcch5ss1tab_normal_regular_subframe_evenNRBDL(PHY_VARS_eNB * eNB) ...@@ -115,10 +115,10 @@ void init_mpdcch5ss1tab_normal_regular_subframe_evenNRBDL(PHY_VARS_eNB * eNB)
for (k = 0; k < 72; k++) { for (k = 0; k < 72; k++) {
kmod = k % 12; kmod = k % 12;
if (((l != 5) && (l != 6) && (l != 12) && (l != 13)) || (kmod == 2) || (kmod == 3) || (kmod == 4) || (kmod == 7) || (kmod == 8) || (kmod == 9)) { if (((l != 5) && (l != 6) && (l != 12) && (l != 13)) || (kmod == 2) || (kmod == 3) || (kmod == 4) || (kmod == 7) || (kmod == 8) || (kmod == 9)) {
mpdcch5ss1tab[re] = (l * eNB->frame_parms.ofdm_symbol_size) + k; mpdcch5ss1tab[re] = (l * eNB->frame_parms.ofdm_symbol_size) + k;
re++; re++;
} else if ((kmod == 0) || (kmod == 5) || (kmod == 10)) { } else if ((kmod == 0) || (kmod == 5) || (kmod == 10)) {
mpdcch5ss1tab[re++] = (l * eNB->frame_parms.ofdm_symbol_size) + k; mpdcch5ss1tab[re++] = (l * eNB->frame_parms.ofdm_symbol_size) + k;
} }
} }
} }
......
...@@ -722,17 +722,13 @@ uint32_t rx_pucch(PHY_VARS_eNB *eNB, ...@@ -722,17 +722,13 @@ uint32_t rx_pucch(PHY_VARS_eNB *eNB,
#if (LTE_RRC_VERSION >= MAKE_VERSION(14, 0, 0)) #if (LTE_RRC_VERSION >= MAKE_VERSION(14, 0, 0))
,uint8_t br_flag ,uint8_t br_flag
#endif #endif
) )
//-----------------------------------------------------------------------------
{ {
static int first_call = 1;
LTE_eNB_COMMON *common_vars = &eNB->common_vars;
static int first_call=1; LTE_DL_FRAME_PARMS *frame_parms = &eNB->frame_parms;
LTE_eNB_COMMON *common_vars = &eNB->common_vars; int8_t sigma2_dB = max(eNB->measurements.n0_subband_power_tot_dB[0], eNB->measurements.n0_subband_power_tot_dB[eNB->frame_parms.N_RB_UL-1]);
LTE_DL_FRAME_PARMS *frame_parms = &eNB->frame_parms;
// PUCCH_CONFIG_DEDICATED *pucch_config_dedicated = &eNB->pucch_config_dedicated[UE_id];
int8_t sigma2_dB = max(eNB->measurements.n0_subband_power_tot_dB[0],
eNB->measurements.n0_subband_power_tot_dB[eNB->frame_parms.N_RB_UL-1]);
uint32_t u,v,n,aa; uint32_t u,v,n,aa;
uint32_t z[12*14]; uint32_t z[12*14];
...@@ -770,7 +766,7 @@ uint32_t rx_pucch(PHY_VARS_eNB *eNB, ...@@ -770,7 +766,7 @@ uint32_t rx_pucch(PHY_VARS_eNB *eNB,
uint16_t Ret = 0; uint16_t Ret = 0;
int16_t SubCarrierDeMapData[NB_ANTENNAS_RX][14][12][2]; //[Antenna][Symbol][Subcarrier][Complex] int16_t SubCarrierDeMapData[NB_ANTENNAS_RX][14][12][2]; //[Antenna][Symbol][Subcarrier][Complex]
int16_t CshData_fmt3[NB_ANTENNAS_RX][14][12][2]; //[Antenna][Symbol][Subcarrier][Complex] int16_t CshData_fmt3[NB_ANTENNAS_RX][14][12][2]; //[Antenna][Symbol][Subcarrier][Complex]
double delta_theta[NB_ANTENNAS_RX][12]; //[Antenna][Subcarrier][Complex] double delta_theta[NB_ANTENNAS_RX][12]; //[Antenna][Subcarrier][Complex]
int16_t ChestValue[NB_ANTENNAS_RX][2][12][2]; //[Antenna][Slot][Subcarrier][Complex] int16_t ChestValue[NB_ANTENNAS_RX][2][12][2]; //[Antenna][Slot][Subcarrier][Complex]
int16_t ChdetAfterValue_fmt3[NB_ANTENNAS_RX][14][12][2]; //[Antenna][Symbol][Subcarrier][Complex] int16_t ChdetAfterValue_fmt3[NB_ANTENNAS_RX][14][12][2]; //[Antenna][Symbol][Subcarrier][Complex]
int16_t RemoveFrqDev_fmt3[NB_ANTENNAS_RX][2][5][12][2]; //[Antenna][Slot][PUCCH_Symbol][Subcarrier][Complex] int16_t RemoveFrqDev_fmt3[NB_ANTENNAS_RX][2][5][12][2]; //[Antenna][Slot][PUCCH_Symbol][Subcarrier][Complex]
...@@ -779,7 +775,6 @@ uint32_t rx_pucch(PHY_VARS_eNB *eNB, ...@@ -779,7 +775,6 @@ uint32_t rx_pucch(PHY_VARS_eNB *eNB,
int16_t Fmt3xDataAvgSym[2][12][2]; //[Slot][Subcarrier][Complex] int16_t Fmt3xDataAvgSym[2][12][2]; //[Slot][Subcarrier][Complex]
int16_t IFFTOutData_Fmt3[2][12][2]; //[Slot][Subcarrier][Complex] int16_t IFFTOutData_Fmt3[2][12][2]; //[Slot][Subcarrier][Complex]
int16_t b[48]; //[bit] int16_t b[48]; //[bit]
//int16_t IP_CsData_allavg[NB_ANTENNAS_RX][12][4][2]; //[Antenna][Symbol][Nouse Cyclic Shift][Complex]
int16_t payload_entity = -1; int16_t payload_entity = -1;
int16_t Interpw; int16_t Interpw;
int16_t payload_max; int16_t payload_max;
......
...@@ -329,7 +329,7 @@ typedef struct { ...@@ -329,7 +329,7 @@ typedef struct {
uint8_t subframe; uint8_t subframe;
/// corresponding UE RNTI /// corresponding UE RNTI
uint16_t rnti; uint16_t rnti;
/// Type (SR,HARQ,CQI,HARQ_SR,HARQ_CQI,SR_CQI,HARQ_SR_CQI) /// Type (SR, HARQ, CQI, HARQ_SR, HARQ_CQI, SR_CQI, HARQ_SR_CQI)
UCI_type_t type; UCI_type_t type;
/// SRS active flag /// SRS active flag
uint8_t srs_active; uint8_t srs_active;
......
...@@ -573,7 +573,13 @@ void handle_uci_harq_information(PHY_VARS_eNB *eNB, LTE_eNB_UCI *uci,nfapi_ul_co ...@@ -573,7 +573,13 @@ void handle_uci_harq_information(PHY_VARS_eNB *eNB, LTE_eNB_UCI *uci,nfapi_ul_co
} }
} }
void handle_uci_sr_pdu(PHY_VARS_eNB *eNB,int UE_id,nfapi_ul_config_request_pdu_t *ul_config_pdu,uint16_t frame,uint8_t subframe,uint8_t srs_active) { void handle_uci_sr_pdu(PHY_VARS_eNB *eNB,
int UE_id,
nfapi_ul_config_request_pdu_t *ul_config_pdu,
uint16_t frame,
uint8_t subframe,
uint8_t srs_active)
{
LTE_eNB_UCI *uci = &eNB->uci_vars[UE_id]; LTE_eNB_UCI *uci = &eNB->uci_vars[UE_id];
if (NFAPI_MODE==NFAPI_MODE_VNF) return; if (NFAPI_MODE==NFAPI_MODE_VNF) return;
...@@ -594,7 +600,10 @@ void handle_uci_sr_pdu(PHY_VARS_eNB *eNB,int UE_id,nfapi_ul_config_request_pdu_t ...@@ -594,7 +600,10 @@ void handle_uci_sr_pdu(PHY_VARS_eNB *eNB,int UE_id,nfapi_ul_config_request_pdu_t
uci->total_repetitions = ul_config_pdu->uci_sr_pdu.ue_information.ue_information_rel13.total_number_of_repetitions; uci->total_repetitions = ul_config_pdu->uci_sr_pdu.ue_information.ue_information_rel13.total_number_of_repetitions;
#endif #endif
LOG_D(PHY,"Programming UCI SR rnti %x, pucch1_0 %d for (%d,%d)\n", LOG_D(PHY,"Programming UCI SR rnti %x, pucch1_0 %d for (%d,%d)\n",
uci->rnti,uci->n_pucch_1_0_sr[0],frame,subframe); uci->rnti,
uci->n_pucch_1_0_sr[0],
frame,
subframe);
} }
void handle_uci_sr_harq_pdu(PHY_VARS_eNB *eNB,int UE_id,nfapi_ul_config_request_pdu_t *ul_config_pdu,uint16_t frame,uint8_t subframe,uint8_t srs_active) { void handle_uci_sr_harq_pdu(PHY_VARS_eNB *eNB,int UE_id,nfapi_ul_config_request_pdu_t *ul_config_pdu,uint16_t frame,uint8_t subframe,uint8_t srs_active) {
......
This diff is collapsed.
...@@ -36,6 +36,7 @@ ...@@ -36,6 +36,7 @@
#include "LTE_SystemInformationBlockType2.h" #include "LTE_SystemInformationBlockType2.h"
#include "LTE_SL-OffsetIndicator-r12.h" #include "LTE_SL-OffsetIndicator-r12.h"
#include "LTE_SubframeBitmapSL-r12.h" #include "LTE_SubframeBitmapSL-r12.h"
#include "LTE_DRX-Config.h"
#include "LTE_SL-CP-Len-r12.h" #include "LTE_SL-CP-Len-r12.h"
#include "LTE_SL-PeriodComm-r12.h" #include "LTE_SL-PeriodComm-r12.h"
#include "LTE_SL-DiscResourcePool-r12.h" #include "LTE_SL-DiscResourcePool-r12.h"
...@@ -141,6 +142,14 @@ typedef struct RadioResourceConfig_s { ...@@ -141,6 +142,14 @@ typedef struct RadioResourceConfig_s {
long bcch_modificationPeriodCoeff; long bcch_modificationPeriodCoeff;
long pcch_defaultPagingCycle; long pcch_defaultPagingCycle;
long pcch_nB; long pcch_nB;
LTE_DRX_Config_PR drx_Config_present;
long drx_onDurationTimer;
long drx_InactivityTimer;
long drx_RetransmissionTimer;
LTE_DRX_Config__setup__longDRX_CycleStartOffset_PR drx_longDrx_CycleStartOffset_present;
long drx_longDrx_CycleStartOffset;
long drx_shortDrx_Cycle;
long drx_shortDrx_ShortCycleTimer;
long ue_TimersAndConstants_t300; long ue_TimersAndConstants_t300;
long ue_TimersAndConstants_t301; long ue_TimersAndConstants_t301;
long ue_TimersAndConstants_t310; long ue_TimersAndConstants_t310;
......
This diff is collapsed.
...@@ -932,8 +932,9 @@ void fill_eMTC_configuration(MessageDef *msg_p, ccparams_eMTC_t *eMTCconfig, in ...@@ -932,8 +932,9 @@ void fill_eMTC_configuration(MessageDef *msg_p, ccparams_eMTC_t *eMTCconfig, in
break; break;
} }
RRC_CONFIGURATION_REQ (msg_p).rar_HoppingConfig_r13[cc_idx][rachCEInfoIndex] = eMTCconfig->rar_HoppingConfig_r13; RRC_CONFIGURATION_REQ (msg_p).rar_HoppingConfig_r13[cc_idx][rachCEInfoIndex] = eMTCconfig->rar_HoppingConfig_r13;
AssertFatal(eMTCconfig->rar_HoppingConfig_r13 == 0 || eMTCconfig->rar_HoppingConfig_r13 == 1, AssertFatal(eMTCconfig->rar_HoppingConfig_r13 == 0 || eMTCconfig->rar_HoppingConfig_r13 == 1,
"illegal rar_HoppingConfig_r13 %d\n",eMTCconfig->rar_HoppingConfig_r13); "illegal rar_HoppingConfig_r13 %d\n",eMTCconfig->rar_HoppingConfig_r13);
} // end for loop (rach ce level info) } // end for loop (rach ce level info)
char rsrpRangeListPath[MAX_OPTNAME_SIZE * 2]; char rsrpRangeListPath[MAX_OPTNAME_SIZE * 2];
...@@ -1101,11 +1102,12 @@ void fill_eMTC_configuration(MessageDef *msg_p, ccparams_eMTC_t *eMTCconfig, in ...@@ -1101,11 +1102,12 @@ void fill_eMTC_configuration(MessageDef *msg_p, ccparams_eMTC_t *eMTCconfig, in
/** PCCH CONFIG V1310 */ /** PCCH CONFIG V1310 */
RRC_CONFIGURATION_REQ(msg_p).pcch_config_v1310[cc_idx] = TRUE; RRC_CONFIGURATION_REQ(msg_p).pcch_config_v1310[cc_idx] = TRUE;
RRC_CONFIGURATION_REQ(msg_p).paging_narrowbands_r13[cc_idx] = eMTCconfig->paging_narrowbands_r13; RRC_CONFIGURATION_REQ(msg_p).paging_narrowbands_r13[cc_idx] = eMTCconfig->paging_narrowbands_r13;
RRC_CONFIGURATION_REQ(msg_p).mpdcch_numrepetition_paging_r13[cc_idx] = eMTCconfig->mpdcch_numrepetition_paging_r13; RRC_CONFIGURATION_REQ(msg_p).mpdcch_numrepetition_paging_r13[cc_idx] = eMTCconfig->mpdcch_numrepetition_paging_r13;
AssertFatal (eMTCconfig->mpdcch_numrepetition_paging_r13 == 1 ||
AssertFatal (eMTCconfig->mpdcch_numrepetition_paging_r13 == 0 ||
eMTCconfig->mpdcch_numrepetition_paging_r13 == 1 ||
eMTCconfig->mpdcch_numrepetition_paging_r13 == 2 || eMTCconfig->mpdcch_numrepetition_paging_r13 == 2 ||
eMTCconfig->mpdcch_numrepetition_paging_r13 == 4 || eMTCconfig->mpdcch_numrepetition_paging_r13 == 4 ||
eMTCconfig->mpdcch_numrepetition_paging_r13 == 8 || eMTCconfig->mpdcch_numrepetition_paging_r13 == 8 ||
...@@ -1117,7 +1119,6 @@ void fill_eMTC_configuration(MessageDef *msg_p, ccparams_eMTC_t *eMTCconfig, in ...@@ -1117,7 +1119,6 @@ void fill_eMTC_configuration(MessageDef *msg_p, ccparams_eMTC_t *eMTCconfig, in
"illegal mpdcch_numrepetition_paging_r13 %d\n", "illegal mpdcch_numrepetition_paging_r13 %d\n",
eMTCconfig->mpdcch_numrepetition_paging_r13); eMTCconfig->mpdcch_numrepetition_paging_r13);
// RRC_CONFIGURATION_REQ(msg_p).nb_v1310[cc_idx] = CALLOC(1, sizeof(long)); // RRC_CONFIGURATION_REQ(msg_p).nb_v1310[cc_idx] = CALLOC(1, sizeof(long));
// if (!strcmp(nb_v1310, "one64thT")) { // if (!strcmp(nb_v1310, "one64thT")) {
// *RRC_CONFIGURATION_REQ(msg_p).nb_v1310[cc_idx] = 0; // *RRC_CONFIGURATION_REQ(msg_p).nb_v1310[cc_idx] = 0;
......
...@@ -321,8 +321,7 @@ typedef enum { ...@@ -321,8 +321,7 @@ typedef enum {
#define ENB_CONFIG_STRING_PUCCH_NUM_REPETITION_CE_MSG4_LEVEL2 "pucch_NumRepetitionCE_Msg4_Level2_r13" #define ENB_CONFIG_STRING_PUCCH_NUM_REPETITION_CE_MSG4_LEVEL2 "pucch_NumRepetitionCE_Msg4_Level2_r13"
#define ENB_CONFIG_STRING_PUCCH_NUM_REPETITION_CE_MSG4_LEVEL3 "pucch_NumRepetitionCE_Msg4_Level3_r13" #define ENB_CONFIG_STRING_PUCCH_NUM_REPETITION_CE_MSG4_LEVEL3 "pucch_NumRepetitionCE_Msg4_Level3_r13"
#define ENB_CONFIG_STRING_FREQ_HOPPING_PARAMETERS_R13 "sib2_freq_hoppingParameters_r13" #define ENB_CONFIG_STRING_FREQ_HOPPING_PARAMETERS_R13 "sib2_freq_hoppingParameters_r13"
#define ENB_CONFIG_STRING_PDSCH_RS_EPRE "pdsch_referenceSignalPower" #define ENB_CONFIG_STRING_PDSCH_RS_EPRE "pdsch_referenceSignalPower"
#define ENB_CONFIG_STRING_PDSCH_PB "pdsch_p_b" #define ENB_CONFIG_STRING_PDSCH_PB "pdsch_p_b"
...@@ -364,6 +363,14 @@ typedef enum { ...@@ -364,6 +363,14 @@ typedef enum {
#define ENB_CONFIG_STRING_RACH_MAXHARQMSG3TX "rach_maxHARQ_Msg3Tx" #define ENB_CONFIG_STRING_RACH_MAXHARQMSG3TX "rach_maxHARQ_Msg3Tx"
#define ENB_CONFIG_STRING_PCCH_DEFAULT_PAGING_CYCLE "pcch_default_PagingCycle" #define ENB_CONFIG_STRING_PCCH_DEFAULT_PAGING_CYCLE "pcch_default_PagingCycle"
#define ENB_CONFIG_STRING_PCCH_NB "pcch_nB" #define ENB_CONFIG_STRING_PCCH_NB "pcch_nB"
#define ENB_CONFIG_STRING_DRX_CONFIG_PRESENT "drx_Config_present"
#define ENB_CONFIG_STRING_DRX_ONDURATIONTIMER "drx_onDurationTimer"
#define ENB_CONFIG_STRING_DRX_INACTIVITYTIMER "drx_InactivityTimer"
#define ENB_CONFIG_STRING_DRX_RETRANSMISSIONTIMER "drx_RetransmissionTimer"
#define ENB_CONFIG_STRING_DRX_LONGDRX_CYCLESTARTOFFSET_PRESENT "drx_longDrx_CycleStartOffset_present"
#define ENB_CONFIG_STRING_DRX_LONGDRX_CYCLESTARTOFFSET "drx_longDrx_CycleStartOffset"
#define ENB_CONFIG_STRING_DRX_SHORTDRX_CYCLE "drx_shortDrx_Cycle"
#define ENB_CONFIG_STRING_DRX_SHORTDRX_SHORTCYCLETIMER "drx_shortDrx_ShortCycleTimer"
#define ENB_CONFIG_STRING_BCCH_MODIFICATIONPERIODCOEFF "bcch_modificationPeriodCoeff" #define ENB_CONFIG_STRING_BCCH_MODIFICATIONPERIODCOEFF "bcch_modificationPeriodCoeff"
#define ENB_CONFIG_STRING_UETIMERS_T300 "ue_TimersAndConstants_t300" #define ENB_CONFIG_STRING_UETIMERS_T300 "ue_TimersAndConstants_t300"
#define ENB_CONFIG_STRING_UETIMERS_T301 "ue_TimersAndConstants_t301" #define ENB_CONFIG_STRING_UETIMERS_T301 "ue_TimersAndConstants_t301"
...@@ -496,6 +503,14 @@ typedef struct ccparams_lte_s { ...@@ -496,6 +503,14 @@ typedef struct ccparams_lte_s {
int32_t rach_maxHARQ_Msg3Tx; int32_t rach_maxHARQ_Msg3Tx;
int32_t pcch_defaultPagingCycle; int32_t pcch_defaultPagingCycle;
char *pcch_nB; char *pcch_nB;
char *drx_Config_present;
char *drx_onDurationTimer;
char *drx_InactivityTimer;
char *drx_RetransmissionTimer;
char *drx_longDrx_CycleStartOffset_present;
int32_t drx_longDrx_CycleStartOffset;
char *drx_shortDrx_Cycle;
int32_t drx_shortDrx_ShortCycleTimer;
int32_t bcch_modificationPeriodCoeff; int32_t bcch_modificationPeriodCoeff;
int32_t ue_TimersAndConstants_t300; int32_t ue_TimersAndConstants_t300;
int32_t ue_TimersAndConstants_t301; int32_t ue_TimersAndConstants_t301;
...@@ -574,6 +589,14 @@ typedef struct ccparams_lte_s { ...@@ -574,6 +589,14 @@ typedef struct ccparams_lte_s {
{ .s5= {NULL }} , \ { .s5= {NULL }} , \
{ .s5= {NULL }} , \ { .s5= {NULL }} , \
{ .s5= {NULL }} , \ { .s5= {NULL }} , \
{ .s5= {NULL }} , \
{ .s5= {NULL }} , \
{ .s5= {NULL }} , \
{ .s5= {NULL }} , \
{ .s5= {NULL }} , \
{ .s5= {NULL }} , \
{ .s5= {NULL }} , \
{ .s5= {NULL }} , \
{ .s5= {NULL }} , \ { .s5= {NULL }} , \
{ .s1a= { config_check_modify_integer, UETIMER_T300_OKVALUES, UETIMER_T300_MODVALUES,8}} , \ { .s1a= { config_check_modify_integer, UETIMER_T300_OKVALUES, UETIMER_T300_MODVALUES,8}} , \
{ .s1a= { config_check_modify_integer, UETIMER_T301_OKVALUES, UETIMER_T301_MODVALUES,8}} , \ { .s1a= { config_check_modify_integer, UETIMER_T301_OKVALUES, UETIMER_T301_MODVALUES,8}} , \
...@@ -688,6 +711,14 @@ typedef struct ccparams_lte_s { ...@@ -688,6 +711,14 @@ typedef struct ccparams_lte_s {
{ENB_CONFIG_STRING_RACH_MAXHARQMSG3TX, NULL, 0, iptr:&ccparams.rach_maxHARQ_Msg3Tx, defintval:4, TYPE_UINT, 0}, \ {ENB_CONFIG_STRING_RACH_MAXHARQMSG3TX, NULL, 0, iptr:&ccparams.rach_maxHARQ_Msg3Tx, defintval:4, TYPE_UINT, 0}, \
{ENB_CONFIG_STRING_PCCH_DEFAULT_PAGING_CYCLE, NULL, 0, iptr:&ccparams.pcch_defaultPagingCycle, defintval:128, TYPE_INT, 0}, \ {ENB_CONFIG_STRING_PCCH_DEFAULT_PAGING_CYCLE, NULL, 0, iptr:&ccparams.pcch_defaultPagingCycle, defintval:128, TYPE_INT, 0}, \
{ENB_CONFIG_STRING_PCCH_NB, NULL, 0, strptr:&ccparams.pcch_nB, defstrval:"oneT", TYPE_STRING, 0}, \ {ENB_CONFIG_STRING_PCCH_NB, NULL, 0, strptr:&ccparams.pcch_nB, defstrval:"oneT", TYPE_STRING, 0}, \
{ENB_CONFIG_STRING_DRX_CONFIG_PRESENT, NULL, 0, strptr:&ccparams.drx_Config_present, defstrval:"prNothing", TYPE_STRING, 0}, \
{ENB_CONFIG_STRING_DRX_ONDURATIONTIMER, NULL, 0, strptr:&ccparams.drx_onDurationTimer, defstrval:"psf10", TYPE_STRING, 0}, \
{ENB_CONFIG_STRING_DRX_INACTIVITYTIMER, NULL, 0, strptr:&ccparams.drx_InactivityTimer, defstrval:"psf10", TYPE_STRING, 0}, \
{ENB_CONFIG_STRING_DRX_RETRANSMISSIONTIMER, NULL, 0, strptr:&ccparams.drx_RetransmissionTimer, defstrval:"psf8", TYPE_STRING, 0}, \
{ENB_CONFIG_STRING_DRX_LONGDRX_CYCLESTARTOFFSET_PRESENT, NULL, 0, strptr:&ccparams.drx_longDrx_CycleStartOffset_present, defstrval:"prSf128", TYPE_STRING, 0}, \
{ENB_CONFIG_STRING_DRX_LONGDRX_CYCLESTARTOFFSET, NULL, 0, iptr:&ccparams.drx_longDrx_CycleStartOffset, defintval:0, TYPE_UINT, 0}, \
{ENB_CONFIG_STRING_DRX_SHORTDRX_CYCLE, NULL, 0, strptr:&ccparams.drx_shortDrx_Cycle, defstrval:"sf32", TYPE_STRING, 0}, \
{ENB_CONFIG_STRING_DRX_SHORTDRX_SHORTCYCLETIMER, NULL, 0, iptr:&ccparams.drx_shortDrx_ShortCycleTimer, defintval:3, TYPE_UINT, 0}, \
{ENB_CONFIG_STRING_BCCH_MODIFICATIONPERIODCOEFF, NULL, 0, iptr:&ccparams.bcch_modificationPeriodCoeff, defintval:2, TYPE_UINT, 0}, \ {ENB_CONFIG_STRING_BCCH_MODIFICATIONPERIODCOEFF, NULL, 0, iptr:&ccparams.bcch_modificationPeriodCoeff, defintval:2, TYPE_UINT, 0}, \
{ENB_CONFIG_STRING_UETIMERS_T300, NULL, 0, iptr:&ccparams.ue_TimersAndConstants_t300, defintval:1000, TYPE_UINT, 0}, \ {ENB_CONFIG_STRING_UETIMERS_T300, NULL, 0, iptr:&ccparams.ue_TimersAndConstants_t300, defintval:1000, TYPE_UINT, 0}, \
{ENB_CONFIG_STRING_UETIMERS_T301, NULL, 0, iptr:&ccparams.ue_TimersAndConstants_t301, defintval:1000, TYPE_UINT, 0}, \ {ENB_CONFIG_STRING_UETIMERS_T301, NULL, 0, iptr:&ccparams.ue_TimersAndConstants_t301, defintval:1000, TYPE_UINT, 0}, \
...@@ -696,7 +727,7 @@ typedef struct ccparams_lte_s { ...@@ -696,7 +727,7 @@ typedef struct ccparams_lte_s {
{ENB_CONFIG_STRING_UETIMERS_N310, NULL, 0, iptr:&ccparams.ue_TimersAndConstants_n310, defintval:20, TYPE_UINT, 0}, \ {ENB_CONFIG_STRING_UETIMERS_N310, NULL, 0, iptr:&ccparams.ue_TimersAndConstants_n310, defintval:20, TYPE_UINT, 0}, \
{ENB_CONFIG_STRING_UETIMERS_N311, NULL, 0, iptr:&ccparams.ue_TimersAndConstants_n311, defintval:1, TYPE_UINT, 0}, \ {ENB_CONFIG_STRING_UETIMERS_N311, NULL, 0, iptr:&ccparams.ue_TimersAndConstants_n311, defintval:1, TYPE_UINT, 0}, \
{ENB_CONFIG_STRING_UE_TRANSMISSION_MODE, NULL, 0, iptr:&ccparams.ue_TransmissionMode, defintval:1, TYPE_UINT, 0}, \ {ENB_CONFIG_STRING_UE_TRANSMISSION_MODE, NULL, 0, iptr:&ccparams.ue_TransmissionMode, defintval:1, TYPE_UINT, 0}, \
{ENB_CONFIG_STRING_UE_MULTIPLE_MAX, NULL, 0, iptr:&ccparams.ue_multiple_max, defintval:4, TYPE_UINT, 0} \ {ENB_CONFIG_STRING_UE_MULTIPLE_MAX, NULL, 0, iptr:&ccparams.ue_multiple_max, defintval:4, TYPE_UINT, 0} \
} }
...@@ -761,14 +792,22 @@ typedef struct ccparams_lte_s { ...@@ -761,14 +792,22 @@ typedef struct ccparams_lte_s {
#define ENB_CONFIG_RACH_MAXHARQMSG3TX_IDX 57 #define ENB_CONFIG_RACH_MAXHARQMSG3TX_IDX 57
#define ENB_CONFIG_PCCH_DEFAULT_PAGING_CYCLE_IDX 58 #define ENB_CONFIG_PCCH_DEFAULT_PAGING_CYCLE_IDX 58
#define ENB_CONFIG_PCCH_NB_IDX 59 #define ENB_CONFIG_PCCH_NB_IDX 59
#define ENB_CONFIG_BCCH_MODIFICATIONPERIODCOEFF_IDX 60 #define ENB_CONFIG_STRING_DRX_CONFIG_PRESENT_IDX 60
#define ENB_CONFIG_UETIMERS_T300_IDX 61 #define ENB_CONFIG_STRING_DRX_ONDURATIONTIMER_IDX 61
#define ENB_CONFIG_UETIMERS_T301_IDX 62 #define ENB_CONFIG_STRING_DRX_INACTIVITYTIMER_IDX 62
#define ENB_CONFIG_UETIMERS_T310_IDX 63 #define ENB_CONFIG_STRING_DRX_RETRANSMISSIONTIMER_IDX 63
#define ENB_CONFIG_UETIMERS_T311_IDX 64 #define ENB_CONFIG_STRING_DRX_LONGDRX_CYCLESTARTOFFSET_PRESENT_IDX 64
#define ENB_CONFIG_UETIMERS_N310_IDX 65 #define ENB_CONFIG_STRING_DRX_LONGDRX_CYCLESTARTOFFSET_IDX 65
#define ENB_CONFIG_UETIMERS_N311_IDX 66 #define ENB_CONFIG_STRING_DRX_SHORTDRX_CYCLE_IDX 66
#define ENB_CONFIG_UE_TRANSMISSION_MODE_IDX 67 #define ENB_CONFIG_STRING_DRX_SHORTDRX_SHORTCYCLETIMER_IDX 67
#define ENB_CONFIG_BCCH_MODIFICATIONPERIODCOEFF_IDX 68
#define ENB_CONFIG_UETIMERS_T300_IDX 69
#define ENB_CONFIG_UETIMERS_T301_IDX 70
#define ENB_CONFIG_UETIMERS_T310_IDX 71
#define ENB_CONFIG_UETIMERS_T311_IDX 72
#define ENB_CONFIG_UETIMERS_N310_IDX 73
#define ENB_CONFIG_UETIMERS_N311_IDX 74
#define ENB_CONFIG_UE_TRANSMISSION_MODE_IDX 75
/*------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------*/ /*------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------*/
/* SRB1 configuration parameters section name */ /* SRB1 configuration parameters section name */
......
...@@ -61,7 +61,10 @@ ...@@ -61,7 +61,10 @@
#define ENB_CONFIG_STRING_PREAMBLE_TRANSMAX_CE_R13 "preamble_TransMax_ce_r13" #define ENB_CONFIG_STRING_PREAMBLE_TRANSMAX_CE_R13 "preamble_TransMax_ce_r13"
#define ENB_CONFIG_STRING_PREAMBLE_TRANSMAX_CE_R13_VAL "preamble_TransMax_ce_r13_val" #define ENB_CONFIG_STRING_PREAMBLE_TRANSMAX_CE_R13_VAL "preamble_TransMax_ce_r13_val"
#define ENB_CONFIG_STRING_PDSCH_MAX_NUM_REPETITION_CE_MODE_A_R13 "pdsch_maxNumRepetitionCEmodeA_r13" #define ENB_CONFIG_STRING_PDSCH_MAX_NUM_REPETITION_CE_MODE_A_R13 "pdsch_maxNumRepetitionCEmodeA_r13"
#define ENB_CONFIG_STRING_PDSCH_MAX_NUM_REPETITION_CE_MODE_B_R13 "pdsch_maxNumRepetitionCEmodeB_r13"
#define ENB_CONFIG_STRING_PUSCH_MAX_NUM_REPETITION_CE_MODE_A_R13 "pusch_maxNumRepetitionCEmodeA_r13" #define ENB_CONFIG_STRING_PUSCH_MAX_NUM_REPETITION_CE_MODE_A_R13 "pusch_maxNumRepetitionCEmodeA_r13"
#define ENB_CONFIG_STRING_PUSCH_MAX_NUM_REPETITION_CE_MODE_B_R13 "pusch_maxNumRepetitionCEmodeB_r13"
#define ENB_CONFIG_STRING_PUSCH_HOPPING_OFFSET_V1310 "pusch_HoppingOffset_v1310"
#define ENB_CONFIG_STRING_SYSTEM_INFO_VALUE_TAG_LIST "system_info_value_tag_SI" #define ENB_CONFIG_STRING_SYSTEM_INFO_VALUE_TAG_LIST "system_info_value_tag_SI"
#define ENB_CONFIG_STRING_FIRST_PREAMBLE_R13 "firstPreamble_r13" #define ENB_CONFIG_STRING_FIRST_PREAMBLE_R13 "firstPreamble_r13"
#define ENB_CONFIG_STRING_LAST_PREAMBLE_R13 "lastPreamble_r13" #define ENB_CONFIG_STRING_LAST_PREAMBLE_R13 "lastPreamble_r13"
...@@ -81,6 +84,9 @@ ...@@ -81,6 +84,9 @@
#define ENB_CONFIG_STRING_PUCCH_INFO_VALUE "pucch_info_value" #define ENB_CONFIG_STRING_PUCCH_INFO_VALUE "pucch_info_value"
#define ENB_CONFIG_STRING_N1PUCCH_AN_INFOLIST_R13 "n1PUCCH_AN_InfoList_r13" #define ENB_CONFIG_STRING_N1PUCCH_AN_INFOLIST_R13 "n1PUCCH_AN_InfoList_r13"
#define ENB_CONFIG_STRING_PCCH_CONFIG_V1310 "pcch_config_v1310" #define ENB_CONFIG_STRING_PCCH_CONFIG_V1310 "pcch_config_v1310"
#define ENB_CONFIG_STRING_PAGING_NARROWBANDS_R13 "paging_narrowbands_r13"
#define ENB_CONFIG_STRING_MPDCCH_NUMREPETITION_PAGING_R13 "mpdcch_numrepetition_paging_r13"
#define ENB_CONFIG_STRING_NB_V1310 "nb_v1310"
#define ENB_CONFIG_STRING_SIB2_FREQ_HOPPINGPARAMETERS_R13 "sib2_freq_hoppingParameters_r13" #define ENB_CONFIG_STRING_SIB2_FREQ_HOPPINGPARAMETERS_R13 "sib2_freq_hoppingParameters_r13"
typedef struct ccparams_eMTC_s { typedef struct ccparams_eMTC_s {
......
This diff is collapsed.
This diff is collapsed.
...@@ -329,6 +329,9 @@ void generate_Msg2(module_id_t module_idP, ...@@ -329,6 +329,9 @@ void generate_Msg2(module_id_t module_idP,
dl_config_pdu->mpdcch_pdu.mpdcch_pdu_rel13.mpdcch_tansmission_type = 1; // imposed (9.1.5 in 213) for Type 2 Common search space dl_config_pdu->mpdcch_pdu.mpdcch_pdu_rel13.mpdcch_tansmission_type = 1; // imposed (9.1.5 in 213) for Type 2 Common search space
AssertFatal (cc[CC_idP].sib1_v13ext->bandwidthReducedAccessRelatedInfo_r13 != NULL, "cc[CC_idP].sib1_v13ext->bandwidthReducedAccessRelatedInfo_r13 is null\n"); AssertFatal (cc[CC_idP].sib1_v13ext->bandwidthReducedAccessRelatedInfo_r13 != NULL, "cc[CC_idP].sib1_v13ext->bandwidthReducedAccessRelatedInfo_r13 is null\n");
dl_config_pdu->mpdcch_pdu.mpdcch_pdu_rel13.start_symbol = cc[CC_idP].sib1_v13ext->bandwidthReducedAccessRelatedInfo_r13->startSymbolBR_r13; dl_config_pdu->mpdcch_pdu.mpdcch_pdu_rel13.start_symbol = cc[CC_idP].sib1_v13ext->bandwidthReducedAccessRelatedInfo_r13->startSymbolBR_r13;
LOG_E(MAC, "start_symbol = %d \n", dl_config_pdu->mpdcch_pdu.mpdcch_pdu_rel13.start_symbol);
dl_config_pdu->mpdcch_pdu.mpdcch_pdu_rel13.ecce_index = 0; // Note: this should be dynamic dl_config_pdu->mpdcch_pdu.mpdcch_pdu_rel13.ecce_index = 0; // Note: this should be dynamic
dl_config_pdu->mpdcch_pdu.mpdcch_pdu_rel13.aggregation_level = 24; // OK for CEModeA r1-3 (9.1.5-1b) or CEModeB r1-4 dl_config_pdu->mpdcch_pdu.mpdcch_pdu_rel13.aggregation_level = 24; // OK for CEModeA r1-3 (9.1.5-1b) or CEModeB r1-4
dl_config_pdu->mpdcch_pdu.mpdcch_pdu_rel13.rnti_type = 2; // RA-RNTI dl_config_pdu->mpdcch_pdu.mpdcch_pdu_rel13.rnti_type = 2; // RA-RNTI
......
This diff is collapsed.
This diff is collapsed.
...@@ -553,6 +553,7 @@ typedef struct { ...@@ -553,6 +553,7 @@ typedef struct {
uint16_t serving_num; uint16_t serving_num;
UE_ULSCH_STATUS status; UE_ULSCH_STATUS status;
} eNB_ULSCH_INFO; } eNB_ULSCH_INFO;
/*! \brief temp struct for DLSCH sched */ /*! \brief temp struct for DLSCH sched */
typedef struct { typedef struct {
rnti_t rnti; rnti_t rnti;
...@@ -561,6 +562,7 @@ typedef struct { ...@@ -561,6 +562,7 @@ typedef struct {
uint16_t serving_num; uint16_t serving_num;
UE_DLSCH_STATUS status; UE_DLSCH_STATUS status;
} eNB_DLSCH_INFO; } eNB_DLSCH_INFO;
/*! \brief eNB overall statistics */ /*! \brief eNB overall statistics */
typedef struct { typedef struct {
/// num BCCH PDU per CC /// num BCCH PDU per CC
...@@ -635,6 +637,7 @@ typedef struct { ...@@ -635,6 +637,7 @@ typedef struct {
int missed_deadlines; int missed_deadlines;
} eNB_STATS; } eNB_STATS;
/*! \brief eNB statistics for the connected UEs*/ /*! \brief eNB statistics for the connected UEs*/
typedef struct { typedef struct {
/// CRNTI of UE /// CRNTI of UE
...@@ -778,6 +781,7 @@ typedef struct { ...@@ -778,6 +781,7 @@ typedef struct {
} eNB_UE_STATS; } eNB_UE_STATS;
/*! \brief eNB template for UE context information */ /*! \brief eNB template for UE context information */
typedef struct { typedef struct {
/// C-RNTI of UE /// C-RNTI of UE
rnti_t rnti; rnti_t rnti;
...@@ -998,6 +1002,62 @@ typedef struct { ...@@ -998,6 +1002,62 @@ typedef struct {
int32_t uplane_inactivity_timer; int32_t uplane_inactivity_timer;
uint8_t crnti_reconfigurationcomplete_flag; uint8_t crnti_reconfigurationcomplete_flag;
uint8_t cqi_req_flag; uint8_t cqi_req_flag;
/* HARQ RRT Timers */
/// (UL) HARQ RTT timers, especially used for CDRX operations, one timer per cell per harq process (and per user)
uint8_t harq_rtt_timer[NFAPI_CC_MAX][8];
uint8_t ul_harq_rtt_timer[NFAPI_CC_MAX][8]; // Note: UL HARQ RTT timers are only for asynchronous HARQ processes
uint8_t ul_synchronous_harq_timer[NFAPI_CC_MAX][8]; // These timers are used for UL synchronous HARQ processes
/* C-DRX related timers */
/* Note: only valid for FDD and LTE UE when this comment is written (11-01-19)*/
/// is TRUE if the cqi mask feature is activated by RRC configuration
boolean_t cqi_mask_boolean;
/// is TRUE if the following drx parameters are configured for UE
boolean_t cdrx_configured;
/*
* if TRUE, the eNB has configured the CDRX locally, but is waiting for the UE to acknowledge
* the activation. This is needed, during the RRC configuration process, when the context is
* configured on the eNB side, but not yet on the UE side...
*/
boolean_t cdrx_waiting_ack;
/*
* Is set when a ULSCH scheduling is done and run until the first corresponding transmission is done (4 subframes).
* When set, SR cannot be set for the UE. This allows OAI to avoid concidering a SR as uncompleted if the UE sends
* a SR just after a periodic DCI0 ULSCH scheduling. Without CDRX there is no problem, but with CDRX this case would
* create a lost in timers synchronization.
*/
uint8_t dci0_ongoing_timer;
/// is TRUE if the UE is in "Active Time", hence listening to PDCCH
boolean_t in_active_time;
/// OnDurationTimer
uint16_t on_duration_timer;
uint16_t on_duration_timer_thres;
/// drx-InactivityTimer
uint16_t drx_inactivity_timer;
uint16_t drx_inactivity_timer_thres;
/// is TRUE if UE is currently in short DRX cycle
boolean_t in_short_drx_cycle;
/// drxShortCycleTimer int (1..16) (number of short DRX cycles duration before long DRX cycles)
uint8_t drx_shortCycle_timer_value;
/// shortDRX-Cycle (duration of one short DRX cycle)
uint16_t short_drx_cycle_duration;
/// DRX short cycle timer before switching to long DRX cycle = drx_shortCycle_timer_value * short_drx_cycle_duration
uint16_t drx_shortCycle_timer;
uint16_t drx_shortCycle_timer_thres;
/// is TRUE if UE is currently in long DRX cycle
boolean_t in_long_drx_cycle;
/// longDRX-CycleStartOffset (long DRX cycle timer)
uint16_t drx_longCycle_timer;
uint16_t drx_longCycle_timer_thres;
/// longDRX-CycleStartOffset (offset value)
uint16_t drx_start_offset;
/// DRX retransmission timer, one per DL HARQ process
uint8_t drx_retransmission_timer[8];
uint8_t drx_retransmission_timer_thres[8];
/// DRX UL retransmission timer, one per UL HARQ process
/* Not implemented yet */
/* End of C-DRX related timers */
} UE_sched_ctrl; } UE_sched_ctrl;
/*! \brief eNB template for the Random access information */ /*! \brief eNB template for the Random access information */
...@@ -1485,6 +1545,7 @@ typedef struct { ...@@ -1485,6 +1545,7 @@ typedef struct {
int16_t bucket_size[MAX_NUM_LCID]; int16_t bucket_size[MAX_NUM_LCID];
} UE_SCHEDULING_INFO; } UE_SCHEDULING_INFO;
/*!\brief Top level UE MAC structure */ /*!\brief Top level UE MAC structure */
typedef struct { typedef struct {
uint16_t Node_id; uint16_t Node_id;
/// RX frame counter /// RX frame counter
......
...@@ -1273,11 +1273,15 @@ void pre_scd_nb_rbs_required( module_id_t module_idP, ...@@ -1273,11 +1273,15 @@ void pre_scd_nb_rbs_required( module_id_t module_idP,
uint16_t nb_rbs_required[MAX_NUM_CCs][NUMBER_OF_UE_MAX]); uint16_t nb_rbs_required[MAX_NUM_CCs][NUMBER_OF_UE_MAX]);
#endif #endif
/*Slice related functions */ /* Slice related functions */
uint16_t nb_rbs_allowed_slice(float rb_percentage, int total_rbs); uint16_t nb_rbs_allowed_slice(float rb_percentage, int total_rbs);
int ue_dl_slice_membership(module_id_t mod_id, int UE_id, int slice_idx); int ue_dl_slice_membership(module_id_t mod_id, int UE_id, int slice_idx);
int ue_ul_slice_membership(module_id_t mod_id, int UE_id, int slice_idx); int ue_ul_slice_membership(module_id_t mod_id, int UE_id, int slice_idx);
/* DRX Configuration */
/* Configure local DRX timers and thresholds in UE context, following the drx_configuration input */
void eNB_Config_Local_DRX(module_id_t Mod_id, rnti_t rnti, LTE_DRX_Config_t *drx_Configuration);
/* from here: prototypes to get rid of compilation warnings: doc to be written by function author */ /* from here: prototypes to get rid of compilation warnings: doc to be written by function author */
uint8_t ul_subframe2_k_phich(COMMON_channels_t * cc, sub_frame_t ul_subframe); uint8_t ul_subframe2_k_phich(COMMON_channels_t * cc, sub_frame_t ul_subframe);
#endif #endif
......
...@@ -487,21 +487,32 @@ void decode_slice_positioning(module_id_t Mod_idP, ...@@ -487,21 +487,32 @@ void decode_slice_positioning(module_id_t Mod_idP,
} }
} }
//-----------------------------------------------------------------------------
// This fuction sorts the UE in order their dlsch buffer and CQI /*
void * This function sorts the UEs in order, depending on their dlsch buffer and CQI
sort_UEs(module_id_t Mod_idP, */
int slice_idx, void sort_UEs(module_id_t Mod_idP,
int frameP, int slice_idx,
sub_frame_t subframeP) int frameP,
sub_frame_t subframeP)
//-----------------------------------------------------------------------------
{ {
int i;
int list[MAX_MOBILES_PER_ENB]; int list[MAX_MOBILES_PER_ENB];
int list_size = 0; int list_size = 0;
struct sort_ue_dl_params params = {Mod_idP, frameP, subframeP, slice_idx}; struct sort_ue_dl_params params = {Mod_idP, frameP, subframeP, slice_idx};
UE_list_t *UE_list = &RC.mac[Mod_idP]->UE_list; UE_list_t *UE_list = &(RC.mac[Mod_idP]->UE_list);
UE_sched_ctrl *UE_scheduling_control = NULL;
for (int i = 0; i < MAX_MOBILES_PER_ENB; i++) {
for (i = 0; i < MAX_MOBILES_PER_ENB; i++) { UE_scheduling_control = &(UE_list->UE_sched_ctrl[i]);
/* Check CDRX configuration and if UE is in active time for this subframe */
if (UE_scheduling_control->cdrx_configured == TRUE) {
if (UE_scheduling_control->in_active_time == FALSE) {
continue;
}
}
if (UE_list->active[i] == TRUE && if (UE_list->active[i] == TRUE &&
UE_RNTI(Mod_idP, i) != NOT_A_RNTI && UE_RNTI(Mod_idP, i) != NOT_A_RNTI &&
...@@ -515,8 +526,9 @@ sort_UEs(module_id_t Mod_idP, ...@@ -515,8 +526,9 @@ sort_UEs(module_id_t Mod_idP,
qsort_r(list, list_size, sizeof(int), ue_dl_compare, &params); qsort_r(list, list_size, sizeof(int), ue_dl_compare, &params);
if (list_size) { if (list_size) {
for (i = 0; i < list_size - 1; ++i) for (int i = 0; i < list_size - 1; ++i) {
UE_list->next[list[i]] = list[i + 1]; UE_list->next[list[i]] = list[i + 1];
}
UE_list->next[list[list_size - 1]] = -1; UE_list->next[list[list_size - 1]] = -1;
UE_list->head = list[0]; UE_list->head = list[0];
...@@ -1666,13 +1678,14 @@ void ulsch_scheduler_pre_processor(module_id_t module_idP, ...@@ -1666,13 +1678,14 @@ void ulsch_scheduler_pre_processor(module_id_t module_idP,
uint16_t average_rbs_per_user[NFAPI_CC_MAX]; uint16_t average_rbs_per_user[NFAPI_CC_MAX];
int16_t total_remaining_rbs[NFAPI_CC_MAX]; int16_t total_remaining_rbs[NFAPI_CC_MAX];
uint16_t total_ue_count[NFAPI_CC_MAX]; uint16_t total_ue_count[NFAPI_CC_MAX];
UE_list_t *UE_list = &RC.mac[module_idP]->UE_list; eNB_MAC_INST *eNB = RC.mac[module_idP];
slice_info_t *sli = &RC.mac[module_idP]->slice_info; UE_list_t *UE_list = &eNB->UE_list;
slice_info_t *sli = &eNB->slice_info;
UE_TEMPLATE *UE_template = 0; UE_TEMPLATE *UE_template = 0;
UE_sched_ctrl *ue_sched_ctl; UE_sched_ctrl *ue_sched_ctl;
int N_RB_UL = 0; int N_RB_UL = 0;
uint16_t available_rbs, first_rb_offset; uint16_t available_rbs, first_rb_offset;
rnti_t rntiTable[MAX_MOBILES_PER_ENB]; // Rnti array => Add SSR 12-2018 rnti_t rntiTable[MAX_MOBILES_PER_ENB];
// sort ues // sort ues
LOG_D(MAC, "In ulsch_preprocessor: sort ue \n"); LOG_D(MAC, "In ulsch_preprocessor: sort ue \n");
...@@ -1725,7 +1738,7 @@ void ulsch_scheduler_pre_processor(module_id_t module_idP, ...@@ -1725,7 +1738,7 @@ void ulsch_scheduler_pre_processor(module_id_t module_idP,
nCCE_to_be_used[CC_id] = nCCE_to_be_used[CC_id] + (1<<aggregation); nCCE_to_be_used[CC_id] = nCCE_to_be_used[CC_id] + (1<<aggregation);
max_num_ue_to_be_scheduled+=1; max_num_ue_to_be_scheduled+=1;
} */ } */
N_RB_UL = to_prb(RC.mac[module_idP]->common_channels[CC_id].ul_Bandwidth); N_RB_UL = to_prb(eNB->common_channels[CC_id].ul_Bandwidth);
ue_sched_ctl = &UE_list->UE_sched_ctrl[UE_id]; ue_sched_ctl = &UE_list->UE_sched_ctrl[UE_id];
ue_sched_ctl->max_rbs_allowed_slice_uplink[CC_id][slice_idx] = ue_sched_ctl->max_rbs_allowed_slice_uplink[CC_id][slice_idx] =
nb_rbs_allowed_slice(sli->ul[slice_idx].pct, N_RB_UL); nb_rbs_allowed_slice(sli->ul[slice_idx].pct, N_RB_UL);
...@@ -1802,7 +1815,7 @@ void ulsch_scheduler_pre_processor(module_id_t module_idP, ...@@ -1802,7 +1815,7 @@ void ulsch_scheduler_pre_processor(module_id_t module_idP,
// This is the actual CC_id in the list // This is the actual CC_id in the list
CC_id = UE_list->ordered_ULCCids[n][UE_id]; CC_id = UE_list->ordered_ULCCids[n][UE_id];
UE_template = &UE_list->UE_template[CC_id][UE_id]; UE_template = &UE_list->UE_template[CC_id][UE_id];
N_RB_UL = to_prb(RC.mac[module_idP]->common_channels[CC_id].ul_Bandwidth); N_RB_UL = to_prb(eNB->common_channels[CC_id].ul_Bandwidth);
first_rb_offset = UE_list->first_rb_offset[CC_id][slice_idx]; first_rb_offset = UE_list->first_rb_offset[CC_id][slice_idx];
available_rbs = cmin(ue_sched_ctl->max_rbs_allowed_slice_uplink[CC_id][slice_idx], N_RB_UL - first_rb[CC_id] - first_rb_offset); available_rbs = cmin(ue_sched_ctl->max_rbs_allowed_slice_uplink[CC_id][slice_idx], N_RB_UL - first_rb[CC_id] - first_rb_offset);
total_remaining_rbs[CC_id] = available_rbs - total_allocated_rbs[CC_id]; total_remaining_rbs[CC_id] = available_rbs - total_allocated_rbs[CC_id];
...@@ -2011,20 +2024,34 @@ static int ue_ul_compare(const void *_a, const void *_b, void *_params) { ...@@ -2011,20 +2024,34 @@ static int ue_ul_compare(const void *_a, const void *_b, void *_params) {
return 0; return 0;
} }
void //-----------------------------------------------------------------------------
sort_ue_ul(module_id_t module_idP, /*
int slice_idx, * This function sorts the UEs in order, depending on their ulsch buffer and CQI
int sched_frameP, */
sub_frame_t sched_subframeP, void sort_ue_ul(module_id_t module_idP,
rnti_t *rntiTable) int slice_idx,
int sched_frameP,
sub_frame_t sched_subframeP,
rnti_t *rntiTable)
//-----------------------------------------------------------------------------
{ {
int i;
int list[MAX_MOBILES_PER_ENB]; int list[MAX_MOBILES_PER_ENB];
int list_size = 0; int list_size = 0;
struct sort_ue_ul_params params = { module_idP, sched_frameP, sched_subframeP }; struct sort_ue_ul_params params = { module_idP, sched_frameP, sched_subframeP };
UE_list_t *UE_list = &RC.mac[module_idP]->UE_list; UE_list_t *UE_list = &RC.mac[module_idP]->UE_list;
UE_sched_ctrl *UE_scheduling_control = NULL;
for (int i = 0; i < MAX_MOBILES_PER_ENB; i++) {
UE_scheduling_control = &(UE_list->UE_sched_ctrl[i]);
/* Check CDRX configuration and if UE is in active time for this subframe */
if (UE_scheduling_control->cdrx_configured == TRUE) {
if (UE_scheduling_control->in_active_time == FALSE) {
continue;
}
}
for (i = 0; i < MAX_MOBILES_PER_ENB; i++) {
rntiTable[i] = UE_RNTI(module_idP, i); rntiTable[i] = UE_RNTI(module_idP, i);
// Valid element and is not the actual CC_id in the list // Valid element and is not the actual CC_id in the list
if (UE_list->active[i] == TRUE && if (UE_list->active[i] == TRUE &&
...@@ -2037,13 +2064,16 @@ sort_ue_ul(module_id_t module_idP, ...@@ -2037,13 +2064,16 @@ sort_ue_ul(module_id_t module_idP,
qsort_r(list, list_size, sizeof(int), ue_ul_compare, &params); qsort_r(list, list_size, sizeof(int), ue_ul_compare, &params);
if (list_size) { // At mimimum one list element if (list_size) { // At mimimum one list element
for (i = 0; i < list_size - 1; i++)
for (int i = 0; i < list_size - 1; i++) {
UE_list->next_ul[list[i]] = list[i + 1]; UE_list->next_ul[list[i]] = list[i + 1];
}
UE_list->next_ul[list[list_size - 1]] = -1; UE_list->next_ul[list[list_size - 1]] = -1;
UE_list->head_ul = list[0]; UE_list->head_ul = list[0];
} else { // No element
} else { // No element
UE_list->head_ul = -1; UE_list->head_ul = -1;
} }
} }
...@@ -114,26 +114,25 @@ void handle_cqi(UL_IND_t *UL_info) { ...@@ -114,26 +114,25 @@ void handle_cqi(UL_IND_t *UL_info) {
} }
void handle_harq(UL_IND_t *UL_info) { void handle_harq(UL_IND_t *UL_info) {
int i; if (NFAPI_MODE == NFAPI_MODE_PNF && UL_info->harq_ind.harq_indication_body.number_of_harqs > 0) { // PNF
if (NFAPI_MODE == NFAPI_MODE_PNF && UL_info->harq_ind.harq_indication_body.number_of_harqs>0) { // PNF
//LOG_D(PHY, "UL_info->harq_ind.harq_indication_body.number_of_harqs:%d Send to VNF\n", UL_info->harq_ind.harq_indication_body.number_of_harqs); //LOG_D(PHY, "UL_info->harq_ind.harq_indication_body.number_of_harqs:%d Send to VNF\n", UL_info->harq_ind.harq_indication_body.number_of_harqs);
int retval = oai_nfapi_harq_indication(&UL_info->harq_ind); int retval = oai_nfapi_harq_indication(&UL_info->harq_ind);
if (retval!=0) { if (retval != 0) {
LOG_E(PHY, "Failed to encode NFAPI HARQ_IND retval:%d\n", retval); LOG_E(PHY, "Failed to encode NFAPI HARQ_IND retval:%d\n", retval);
} }
UL_info->harq_ind.harq_indication_body.number_of_harqs = 0; UL_info->harq_ind.harq_indication_body.number_of_harqs = 0;
} else { } else {
for (i=0; i<UL_info->harq_ind.harq_indication_body.number_of_harqs; i++) for (int i=0; i < UL_info->harq_ind.harq_indication_body.number_of_harqs; i++)
harq_indication(UL_info->module_id, harq_indication(UL_info->module_id,
UL_info->CC_id, UL_info->CC_id,
NFAPI_SFNSF2SFN(UL_info->harq_ind.sfn_sf), NFAPI_SFNSF2SFN(UL_info->harq_ind.sfn_sf),
NFAPI_SFNSF2SF(UL_info->harq_ind.sfn_sf), NFAPI_SFNSF2SF(UL_info->harq_ind.sfn_sf),
&UL_info->harq_ind.harq_indication_body.harq_pdu_list[i]); &UL_info->harq_ind.harq_indication_body.harq_pdu_list[i]);
UL_info->harq_ind.harq_indication_body.number_of_harqs=0; UL_info->harq_ind.harq_indication_body.number_of_harqs = 0;
} }
} }
......
This diff is collapsed.
This diff is collapsed.
...@@ -70,6 +70,15 @@ uint8_t do_MIB(rrc_eNB_carrier_data_t *carrier, uint32_t N_RB_DL, uint32_t phich ...@@ -70,6 +70,15 @@ uint8_t do_MIB(rrc_eNB_carrier_data_t *carrier, uint32_t N_RB_DL, uint32_t phich
#endif #endif
); );
/**
\brief Generate configuration structure for DRX_Config
@param Mod_id Instance of eNB
@param CC_id Id of component to configure
@param configuration Pointer Configuration Request structure
@param UEcap Pointer Configuration UE capablities
@return DRX_Config structure pointer or NULL => error */
LTE_DRX_Config_t *do_DrxConfig(uint8_t Mod_id, int CC_id, RrcConfigurationReq *configuration, LTE_UE_EUTRA_Capability_t *UEcap);
/** /**
\brief Generate configuration for SIB1 (eNB). \brief Generate configuration for SIB1 (eNB).
@param carrier pointer to Carrier information @param carrier pointer to Carrier information
......
...@@ -140,9 +140,9 @@ static uint8_t check_trigger_meas_event( ...@@ -140,9 +140,9 @@ static uint8_t check_trigger_meas_event(
LTE_Q_OffsetRange_t ofs, LTE_Q_OffsetRange_t ocs, long a3_offset, LTE_TimeToTrigger_t ttt); LTE_Q_OffsetRange_t ofs, LTE_Q_OffsetRange_t ocs, long a3_offset, LTE_TimeToTrigger_t ttt);
#if (LTE_RRC_VERSION >= MAKE_VERSION(10, 0, 0)) #if (LTE_RRC_VERSION >= MAKE_VERSION(10, 0, 0))
static void decode_MBSFNAreaConfiguration(module_id_t module_idP, uint8_t eNB_index, frame_t frameP,uint8_t mbsfn_sync_area); static void decode_MBSFNAreaConfiguration(module_id_t module_idP, uint8_t eNB_index, frame_t frameP,uint8_t mbsfn_sync_area);
uint8_t rrc_ue_generate_SidelinkUEInformation( const protocol_ctxt_t *const ctxt_pP, const uint8_t eNB_index,LTE_SL_DestinationInfoList_r12_t *destinationInfoList, long *discTxResourceReq, uint8_t rrc_ue_generate_SidelinkUEInformation( const protocol_ctxt_t *const ctxt_pP, const uint8_t eNB_index,LTE_SL_DestinationInfoList_r12_t *destinationInfoList, long *discTxResourceReq,
SL_TRIGGER_t mode); SL_TRIGGER_t mode);
#endif #endif
......
This diff is collapsed.
...@@ -55,9 +55,7 @@ rrc_init_global_param( ...@@ -55,9 +55,7 @@ rrc_init_global_param(
) )
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
{ {
rrc_rlc_register_rrc (rrc_data_ind, NULL); //register with rlc rrc_rlc_register_rrc (rrc_data_ind, NULL); //register with rlc
DCCH_LCHAN_DESC.transport_block_size = 4; DCCH_LCHAN_DESC.transport_block_size = 4;
DCCH_LCHAN_DESC.max_transport_blocks = 16; DCCH_LCHAN_DESC.max_transport_blocks = 16;
DCCH_LCHAN_DESC.Delay_class = 1; DCCH_LCHAN_DESC.Delay_class = 1;
...@@ -67,13 +65,11 @@ rrc_init_global_param( ...@@ -67,13 +65,11 @@ rrc_init_global_param(
DTCH_UL_LCHAN_DESC.transport_block_size = 52; DTCH_UL_LCHAN_DESC.transport_block_size = 52;
DTCH_UL_LCHAN_DESC.max_transport_blocks = 20; DTCH_UL_LCHAN_DESC.max_transport_blocks = 20;
DTCH_UL_LCHAN_DESC.Delay_class = 1; DTCH_UL_LCHAN_DESC.Delay_class = 1;
Rlc_info_um.rlc_mode = RLC_MODE_UM; Rlc_info_um.rlc_mode = RLC_MODE_UM;
Rlc_info_um.rlc.rlc_um_info.timer_reordering = 5; Rlc_info_um.rlc.rlc_um_info.timer_reordering = 5;
Rlc_info_um.rlc.rlc_um_info.sn_field_length = 10; Rlc_info_um.rlc.rlc_um_info.sn_field_length = 10;
Rlc_info_um.rlc.rlc_um_info.is_mXch = 0; Rlc_info_um.rlc.rlc_um_info.is_mXch = 0;
//Rlc_info_um.rlc.rlc_um_info.sdu_discard_mode=16; //Rlc_info_um.rlc.rlc_um_info.sdu_discard_mode=16;
Rlc_info_am_config.rlc_mode = RLC_MODE_AM; Rlc_info_am_config.rlc_mode = RLC_MODE_AM;
Rlc_info_am_config.rlc.rlc_am_info.max_retx_threshold = 50; Rlc_info_am_config.rlc.rlc_am_info.max_retx_threshold = 50;
Rlc_info_am_config.rlc.rlc_am_info.poll_pdu = 8; Rlc_info_am_config.rlc.rlc_am_info.poll_pdu = 8;
...@@ -81,20 +77,18 @@ rrc_init_global_param( ...@@ -81,20 +77,18 @@ rrc_init_global_param(
Rlc_info_am_config.rlc.rlc_am_info.t_poll_retransmit = 15; Rlc_info_am_config.rlc.rlc_am_info.t_poll_retransmit = 15;
Rlc_info_am_config.rlc.rlc_am_info.t_reordering = 50; Rlc_info_am_config.rlc.rlc_am_info.t_reordering = 50;
Rlc_info_am_config.rlc.rlc_am_info.t_status_prohibit = 10; Rlc_info_am_config.rlc.rlc_am_info.t_status_prohibit = 10;
return 0; return 0;
} }
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
void void
rrc_config_buffer( rrc_config_buffer(
SRB_INFO* Srb_info, SRB_INFO *Srb_info,
uint8_t Lchan_type, uint8_t Lchan_type,
uint8_t Role uint8_t Role
) )
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
{ {
Srb_info->Rx_buffer.payload_size = 0; Srb_info->Rx_buffer.payload_size = 0;
Srb_info->Tx_buffer.payload_size = 0; Srb_info->Tx_buffer.payload_size = 0;
} }
...@@ -200,7 +194,7 @@ static band_freq bands[] = { ...@@ -200,7 +194,7 @@ static band_freq bands[] = {
{ BAND_TYPE_FDD, 3, 1710000000UL, 1785000000UL, 1805000000UL, 1880000000UL }, { BAND_TYPE_FDD, 3, 1710000000UL, 1785000000UL, 1805000000UL, 1880000000UL },
{ BAND_TYPE_FDD, 4, 1710000000UL, 1755000000UL, 2110000000UL, 2155000000UL }, { BAND_TYPE_FDD, 4, 1710000000UL, 1755000000UL, 2110000000UL, 2155000000UL },
{ BAND_TYPE_FDD, 5, 824000000UL, 849000000UL, 869000000UL, 894000000UL }, { BAND_TYPE_FDD, 5, 824000000UL, 849000000UL, 869000000UL, 894000000UL },
/* to remove? */{ BAND_TYPE_FDD, 6, 830000000UL, 840000000UL, 875000000UL, 885000000UL }, /* to remove? */{ BAND_TYPE_FDD, 6, 830000000UL, 840000000UL, 875000000UL, 885000000UL },
{ BAND_TYPE_FDD, 7, 2500000000UL, 2570000000UL, 2620000000UL, 2690000000UL }, { BAND_TYPE_FDD, 7, 2500000000UL, 2570000000UL, 2620000000UL, 2690000000UL },
{ BAND_TYPE_FDD, 8, 880000000UL, 915000000UL, 925000000UL, 960000000UL }, { BAND_TYPE_FDD, 8, 880000000UL, 915000000UL, 925000000UL, 960000000UL },
{ BAND_TYPE_FDD, 9, 1749900000UL, 1784900000UL, 1844900000UL, 1879900000UL }, { BAND_TYPE_FDD, 9, 1749900000UL, 1784900000UL, 1844900000UL, 1879900000UL },
...@@ -278,17 +272,17 @@ static earfcn earfcn_table[] = { ...@@ -278,17 +272,17 @@ static earfcn earfcn_table[] = {
{ 42, 3400000000UL, 41590, 41590, 43589, 3400000000UL, 41590, 41590, 43589 }, { 42, 3400000000UL, 41590, 41590, 43589, 3400000000UL, 41590, 41590, 43589 },
{ 43, 3600000000UL, 43590, 43590, 45589, 3600000000UL, 43590, 43590, 45589 }, { 43, 3600000000UL, 43590, 43590, 45589, 3600000000UL, 43590, 43590, 45589 },
}; };
int freq_to_arfcn10(int band, unsigned long freq) int freq_to_arfcn10(int band, unsigned long freq) {
{ int N = sizeof(earfcn_table) / sizeof(earfcn_table[0]);
int N = sizeof(earfcn_table) / sizeof(earfcn_table[0]);
int i; int i;
for (i = 0; i < N; i++) if (bands[i].band == band) break; for (i = 0; i < N; i++) if (bands[i].band == band) break;
if (i == N) return -1; if (i == N) return -1;
if (!(bands[i].dl_minfreq < freq && freq < bands[i].dl_maxfreq)) if (!(bands[i].dl_minfreq < freq && freq < bands[i].dl_maxfreq))
return -1; return -1;
return (freq - earfcn_table[i].dl_flow) / 100000UL + earfcn_table[i].dl_off; return (freq - earfcn_table[i].dl_flow) / 100000UL + earfcn_table[i].dl_off;
} }
...@@ -200,6 +200,8 @@ void *send_UE_status_notification(void *); ...@@ -200,6 +200,8 @@ void *send_UE_status_notification(void *);
/* for ImsiMobileIdentity_t */ /* for ImsiMobileIdentity_t */
#include "MobileIdentity.h" #include "MobileIdentity.h"
#include "LTE_DRX-Config.h"
/* correct Rel(8|10)/Rel14 differences /* correct Rel(8|10)/Rel14 differences
* the code is in favor of Rel14, those defines do the translation * the code is in favor of Rel14, those defines do the translation
*/ */
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
...@@ -34,8 +34,7 @@ ________________________________________________________________*/ ...@@ -34,8 +34,7 @@ ________________________________________________________________*/
//------------------------------------------------------------------------------------------------------------------// //------------------------------------------------------------------------------------------------------------------//
uint16_t find_free_dtch_position(uint8_t Mod_id, uint16_t UE_CH_index) uint16_t find_free_dtch_position(uint8_t Mod_id, uint16_t UE_CH_index) {
{
uint16_t i,j; uint16_t i,j;
if(UE_CH_index==0) { if(UE_CH_index==0) {
...@@ -45,22 +44,18 @@ uint16_t find_free_dtch_position(uint8_t Mod_id, uint16_t UE_CH_index) ...@@ -45,22 +44,18 @@ uint16_t find_free_dtch_position(uint8_t Mod_id, uint16_t UE_CH_index)
} }
for(i=j; i<NB_RAB_MAX; i++) { //first RAB IS BROADCAST DTCH for(i=j; i<NB_RAB_MAX; i++) { //first RAB IS BROADCAST DTCH
if(CH_rrc_inst[Mod_id].Rab[i][UE_CH_index].Active==0) { if(CH_rrc_inst[Mod_id].Rab[i][UE_CH_index].Active==0) {
return( i); return( i);
} }
} }
msg("NO FREE DTCH LCHAN, exit... \n"); msg("NO FREE DTCH LCHAN, exit... \n");
Mac_rlc_xface->macphy_exit("NO FREE DTCH LCHAN, exit"); Mac_rlc_xface->macphy_exit("NO FREE DTCH LCHAN, exit");
return 0; return 0;
} }
//-------------------------------------------------------------------------------------------// //-------------------------------------------------------------------------------------------//
uint8_t rrc_find_free_ue_index(uint8_t Mod_id) uint8_t rrc_find_free_ue_index(uint8_t Mod_id) {
{
//-------------------------------------------------------------------------------------------// //-------------------------------------------------------------------------------------------//
uint16_t i; uint16_t i;
...@@ -78,8 +73,7 @@ uint8_t rrc_find_free_ue_index(uint8_t Mod_id) ...@@ -78,8 +73,7 @@ uint8_t rrc_find_free_ue_index(uint8_t Mod_id)
//-------------------------------------------------------------------------------------------// //-------------------------------------------------------------------------------------------//
unsigned short rrc_find_ue_index(unsigned char Mod_id, L2_ID Mac_id) unsigned short rrc_find_ue_index(unsigned char Mod_id, L2_ID Mac_id) {
{
//-------------------------------------------------------------------------------------------// //-------------------------------------------------------------------------------------------//
unsigned char i; unsigned char i;
/* /*
...@@ -90,8 +84,7 @@ unsigned short rrc_find_ue_index(unsigned char Mod_id, L2_ID Mac_id) ...@@ -90,8 +84,7 @@ unsigned short rrc_find_ue_index(unsigned char Mod_id, L2_ID Mac_id)
*/ */
} }
//-------------------------------------------------------------------------------------------// //-------------------------------------------------------------------------------------------//
uint8_t rrc_is_node_isolated(uint8_t Mod_id) uint8_t rrc_is_node_isolated(uint8_t Mod_id) {
{
//-------------------------------------------------------------------------------------------// //-------------------------------------------------------------------------------------------//
/*uint8_t i; /*uint8_t i;
for(i=0;i<NB_CNX_UE;i++) for(i=0;i<NB_CNX_UE;i++)
...@@ -102,8 +95,7 @@ uint8_t rrc_is_node_isolated(uint8_t Mod_id) ...@@ -102,8 +95,7 @@ uint8_t rrc_is_node_isolated(uint8_t Mod_id)
} }
//-------------------------------------------------------------------------------------------// //-------------------------------------------------------------------------------------------//
uint8_t find_rrc_info_index(uint8_t Mod_id,uint8_t CH_id) uint8_t find_rrc_info_index(uint8_t Mod_id,uint8_t CH_id) {
{
//-------------------------------------------------------------------------------------------// //-------------------------------------------------------------------------------------------//
/*uint8_t i; /*uint8_t i;
...@@ -170,8 +162,7 @@ RB_INFO* rrc_find_rb_info(uint8_t Mod_id,uint16_t Rb_id){ ...@@ -170,8 +162,7 @@ RB_INFO* rrc_find_rb_info(uint8_t Mod_id,uint16_t Rb_id){
*/ */
/*------------------------------------------------------------------------------*/ /*------------------------------------------------------------------------------*/
unsigned char rrc_is_mobile_already_associated(uint8_t Mod_id, L2_ID Mac_id) unsigned char rrc_is_mobile_already_associated(uint8_t Mod_id, L2_ID Mac_id) {
{
/*------------------------------------------------------------------------------*/ /*------------------------------------------------------------------------------*/
/* /*
unsigned char i; unsigned char i;
...@@ -184,8 +175,7 @@ unsigned char rrc_is_mobile_already_associated(uint8_t Mod_id, L2_ID Mac_id) ...@@ -184,8 +175,7 @@ unsigned char rrc_is_mobile_already_associated(uint8_t Mod_id, L2_ID Mac_id)
//-------------------------------------------------------------------------------------------// //-------------------------------------------------------------------------------------------//
void rrc_reset_buffer(RRC_BUFFER *Rrc_buffer) void rrc_reset_buffer(RRC_BUFFER *Rrc_buffer) {
{
//-------------------------------------------------------------------------------------------// //-------------------------------------------------------------------------------------------//
// Rrc_buffer->Header->Rv_tb_idx=0; // Rrc_buffer->Header->Rv_tb_idx=0;
// Rrc_buffer->W_idx=0; // Rrc_buffer->W_idx=0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment