Commit 43c07e40 authored by laurent's avatar laurent

fix SR report from UE->DU->CU, remain later failure in PUSCH allocation

parent 1fe5ed6f
...@@ -171,7 +171,7 @@ void prach_eNB_fromsplit(uint8_t *bufferZone, int bufSize, PHY_VARS_eNB *eNB) { ...@@ -171,7 +171,7 @@ void prach_eNB_fromsplit(uint8_t *bufferZone, int bufSize, PHY_VARS_eNB *eNB) {
} }
} }
void sendFs6Ulharq(int UEid, PHY_VARS_eNB *eNB, int frame, int subframe, uint8_t *harq_ack, uint8_t tdd_mapping_mode, uint16_t tdd_multiplexing_mask) { void sendFs6Ulharq(enum pckType type, int UEid, PHY_VARS_eNB *eNB, int frame, int subframe, uint8_t *harq_ack, uint8_t tdd_mapping_mode, uint16_t tdd_multiplexing_mask, uint16_t rnti, int32_t stat) {
static int current_fsf=-1; static int current_fsf=-1;
int fsf=frame*16+subframe; int fsf=frame*16+subframe;
uint8_t *bufferZone=eNB->FS6bufferZone; uint8_t *bufferZone=eNB->FS6bufferZone;
...@@ -200,16 +200,22 @@ void sendFs6Ulharq(int UEid, PHY_VARS_eNB *eNB, int frame, int subframe, uint8_ ...@@ -200,16 +200,22 @@ void sendFs6Ulharq(int UEid, PHY_VARS_eNB *eNB, int frame, int subframe, uint8_
curBlock++; curBlock++;
} }
LOG_D(PHY,"FS6 du, block: %d: adding ul harq/sr: %d, rnti: %d, ueid: %d\n",
curBlock, type, rnti, UEid);
commonUDP_t *newUDPheader=(commonUDP_t *) firstFreeByte; commonUDP_t *newUDPheader=(commonUDP_t *) firstFreeByte;
fs6_ul_uespec_uci_element_t *tmp=(fs6_ul_uespec_uci_element_t *)(hULUEuci(newUDPheader)+1); fs6_ul_uespec_uci_element_t *tmp=(fs6_ul_uespec_uci_element_t *)(hULUEuci(newUDPheader)+1);
tmp+=hULUEuci(newUDPheader)->nb_active_ue; tmp+=hULUEuci(newUDPheader)->nb_active_ue;
tmp->type=type;
tmp->UEid=UEid; tmp->UEid=UEid;
tmp->frame=frame; tmp->frame=frame;
tmp->subframe=subframe; tmp->subframe=subframe;
if (harq_ack != NULL)
memcpy(tmp->harq_ack, harq_ack, 4); memcpy(tmp->harq_ack, harq_ack, 4);
tmp->tdd_mapping_mode=tdd_mapping_mode; tmp->tdd_mapping_mode=tdd_mapping_mode;
tmp->tdd_multiplexing_mask=tdd_multiplexing_mask; tmp->tdd_multiplexing_mask=tdd_multiplexing_mask;
tmp->n0_subband_power_dB=eNB->measurements.n0_subband_power_dB[0][0]; tmp->n0_subband_power_dB=eNB->measurements.n0_subband_power_dB[0][0];
tmp->rnti=rnti;
tmp->stat=stat;
hULUEuci(newUDPheader)->nb_active_ue++; hULUEuci(newUDPheader)->nb_active_ue++;
newUDPheader->contentBytes+=sizeof(fs6_ul_uespec_uci_element_t); newUDPheader->contentBytes+=sizeof(fs6_ul_uespec_uci_element_t);
} }
...@@ -636,12 +642,19 @@ void recvFs6Ul(uint8_t *bufferZone, int nbBlocks, PHY_VARS_eNB *eNB) { ...@@ -636,12 +642,19 @@ void recvFs6Ul(uint8_t *bufferZone, int nbBlocks, PHY_VARS_eNB *eNB) {
} else if ( type == fs6ULcch ) { } else if ( type == fs6ULcch ) {
int nb_uci=hULUEuci(bufPtr)->nb_active_ue; int nb_uci=hULUEuci(bufPtr)->nb_active_ue;
fs6_ul_uespec_uci_element_t *tmp=(fs6_ul_uespec_uci_element_t *)(hULUEuci(bufPtr)+1); fs6_ul_uespec_uci_element_t *tmp=(fs6_ul_uespec_uci_element_t *)(hULUEuci(bufPtr)+1);
for (int j=0; j < nb_uci ; j++) {
for (int i=0; i < nb_uci ; i++) { LOG_D(PHY,"FS6 cu, block: %d/%d: received ul harq/sr: %d, rnti: %d, ueid: %d\n",
i, j, type, tmp->rnti, tmp->UEid);
eNB->measurements.n0_subband_power_dB[0][0]=tmp->n0_subband_power_dB; eNB->measurements.n0_subband_power_dB[0][0]=tmp->n0_subband_power_dB;
if ( tmp->type == fs6ULindicationHarq )
fill_uci_harq_indication (tmp->UEid, eNB, &eNB->uci_vars[tmp->UEid], fill_uci_harq_indication (tmp->UEid, eNB, &eNB->uci_vars[tmp->UEid],
tmp->frame, tmp->subframe, tmp->harq_ack, tmp->frame, tmp->subframe, tmp->harq_ack,
tmp->tdd_mapping_mode, tmp->tdd_multiplexing_mask); tmp->tdd_mapping_mode, tmp->tdd_multiplexing_mask);
else if ( tmp->type == fs6ULindicationSr )
fill_sr_indication(tmp->UEid, eNB,tmp->rnti,tmp->frame,tmp->subframe,tmp->stat);
else
LOG_E(PHY, "Split FS6: impossible UL harq type\n");
tmp++; tmp++;
} }
} else } else
...@@ -655,6 +668,13 @@ void recvFs6Ul(uint8_t *bufferZone, int nbBlocks, PHY_VARS_eNB *eNB) { ...@@ -655,6 +668,13 @@ void recvFs6Ul(uint8_t *bufferZone, int nbBlocks, PHY_VARS_eNB *eNB) {
void phy_procedures_eNB_uespec_RX_fromsplit(uint8_t *bufferZone, int nbBlocks,PHY_VARS_eNB *eNB) { void phy_procedures_eNB_uespec_RX_fromsplit(uint8_t *bufferZone, int nbBlocks,PHY_VARS_eNB *eNB) {
// The configuration arrived in Dl, so we can extract the UL data // The configuration arrived in Dl, so we can extract the UL data
recvFs6Ul(bufferZone, nbBlocks, eNB); recvFs6Ul(bufferZone, nbBlocks, eNB);
// dirty memory allocation in OAI...
for (int i = 0; i < NUMBER_OF_UCI_VARS_MAX; i++)
if ( eNB->uci_vars[i].frame == eNB->proc.frame_rx &&
eNB->uci_vars[i].subframe == eNB->proc.subframe_rx )
eNB->uci_vars[i].active=0;
pusch_procedures_fromsplit(bufferZone, nbBlocks, eNB); pusch_procedures_fromsplit(bufferZone, nbBlocks, eNB);
} }
...@@ -1025,13 +1045,8 @@ void phy_procedures_eNB_TX_tosplit(uint8_t *bufferZone, PHY_VARS_eNB *eNB, L1_rx ...@@ -1025,13 +1045,8 @@ void phy_procedures_eNB_TX_tosplit(uint8_t *bufferZone, PHY_VARS_eNB *eNB, L1_rx
LTE_UL_eNB_HARQ_t *ulsch_harq = ulsch->harq_processes[harq_pid]; LTE_UL_eNB_HARQ_t *ulsch_harq = ulsch->harq_processes[harq_pid];
if (ulsch->rnti>0) { if (ulsch->rnti>0) {
LOG_I(PHY,"check in UL scheduled harq %d: rnti %d, tx frame %d/%d, ulsch: %d, %d/%d (handled: %d)\n", LOG_D(PHY,"check in UL scheduled harq %d: rnti %d, tx frame %d/%d, ulsch: %d, %d/%d (handled: %d)\n",
harq_pid, ulsch->rnti, frame, subframe, ulsch_harq->status, ulsch_harq->frame, ulsch_harq->subframe, ulsch_harq->handled); harq_pid, ulsch->rnti, frame, subframe, ulsch_harq->status, ulsch_harq->frame, ulsch_harq->subframe, ulsch_harq->handled);
for (int k=0; k<8; k++)
if ( ulsch->harq_processes[k]->status == ACTIVE)
LOG_I(PHY,"check in UL scheduledi (harq_pid %d): rnti %d, tx frame %d/%d, ulsch: %d, %d/%d (handled: %d)\n", k,
ulsch->rnti, frame, subframe, ulsch->harq_processes[k]->status, ulsch->harq_processes[k]->frame, ulsch->harq_processes[k]->subframe, ulsch->harq_processes[k]->handled);
} }
for (int k=0; k<8; k++) { for (int k=0; k<8; k++) {
......
...@@ -67,6 +67,8 @@ enum pckType { ...@@ -67,6 +67,8 @@ enum pckType {
fs6ULConfigCCH=27, fs6ULConfigCCH=27,
fs6ULsch=28, fs6ULsch=28,
fs6ULcch=29, fs6ULcch=29,
fs6ULindicationHarq=40,
fs6ULindicationSr=41,
}; };
typedef struct { typedef struct {
...@@ -132,6 +134,7 @@ typedef struct { ...@@ -132,6 +134,7 @@ typedef struct {
} fs6_ul_uespec_t; } fs6_ul_uespec_t;
typedef struct { typedef struct {
enum pckType type:8;
int UEid; int UEid;
int frame; int frame;
int subframe; int subframe;
...@@ -139,6 +142,8 @@ typedef struct { ...@@ -139,6 +142,8 @@ typedef struct {
uint8_t tdd_mapping_mode; uint8_t tdd_mapping_mode;
uint16_t tdd_multiplexing_mask; uint16_t tdd_multiplexing_mask;
unsigned short n0_subband_power_dB; unsigned short n0_subband_power_dB;
uint16_t rnti;
int32_t stat;
} fs6_ul_uespec_uci_element_t; } fs6_ul_uespec_uci_element_t;
typedef struct { typedef struct {
...@@ -174,6 +179,8 @@ static inline void *commonUDPdata(uint8_t *ptr) { ...@@ -174,6 +179,8 @@ static inline void *commonUDPdata(uint8_t *ptr) {
} }
void setAllfromTS(uint64_t TS); void setAllfromTS(uint64_t TS);
void sendFs6Ulharq(enum pckType type, int UEid, PHY_VARS_eNB *eNB, int frame, int subframe, uint8_t *harq_ack, uint8_t tdd_mapping_mode, uint16_t tdd_multiplexing_mask, uint16_t rnti, int32_t stat);
void sendFs6Ul(PHY_VARS_eNB *eNB, int UE_id, int harq_pid, int segmentID, int16_t *data, int dataLen);
void *cu_fs6(void *arg); void *cu_fs6(void *arg);
void *du_fs6(void *arg); void *du_fs6(void *arg);
void fill_rf_config(RU_t *ru, char *rf_config_file); void fill_rf_config(RU_t *ru, char *rf_config_file);
......
...@@ -195,7 +195,7 @@ int generate_pbch(LTE_eNB_PBCH *eNB_pbch, ...@@ -195,7 +195,7 @@ int generate_pbch(LTE_eNB_PBCH *eNB_pbch,
pbch_E = (frame_parms->Ncp==NORMAL) ? 1920 : 1728; //RE/RB * #RB * bits/RB (QPSK) pbch_E = (frame_parms->Ncp==NORMAL) ? 1920 : 1728; //RE/RB * #RB * bits/RB (QPSK)
// pbch_E_bytes = pbch_coded_bits>>3; // pbch_E_bytes = pbch_coded_bits>>3;
LOG_D(PHY,"%s(eNB_pbch:%p txdataF:%p amp:%d frame_parms:%p pbch_pdu:%p frame_mod4:%d)\n", __FUNCTION__, eNB_pbch, txdataF, amp, frame_parms, pbch_pdu, frame_mod4); LOG_D(PHY,"%s(eNB_pbch:%p txdataF:%p amp:%d frame_parms:%p pbch_pdu:%p frame_mod4:%d)\n", __FUNCTION__, eNB_pbch, txdataF, amp, frame_parms, pbch_pdu, frame_mod4==0);
if (frame_mod4==0) { if (frame_mod4==0) {
bzero(pbch_a,PBCH_A>>3); bzero(pbch_a,PBCH_A>>3);
......
...@@ -36,7 +36,6 @@ ...@@ -36,7 +36,6 @@
#include "common/utils/LOG/vcd_signal_dumper.h" #include "common/utils/LOG/vcd_signal_dumper.h"
#define PRACH_DEBUG
uint16_t NCS_unrestricted[16] = {0,13,15,18,22,26,32,38,46,59,76,93,119,167,279,419}; uint16_t NCS_unrestricted[16] = {0,13,15,18,22,26,32,38,46,59,76,93,119,167,279,419};
uint16_t NCS_restricted[15] = {15,18,22,26,32,38,46,55,68,82,100,128,158,202,237}; // high-speed case uint16_t NCS_restricted[15] = {15,18,22,26,32,38,46,55,68,82,100,128,158,202,237}; // high-speed case
uint16_t NCS_4[7] = {2,4,6,8,10,12,15}; uint16_t NCS_4[7] = {2,4,6,8,10,12,15};
......
...@@ -274,7 +274,7 @@ typedef struct { ...@@ -274,7 +274,7 @@ typedef struct {
/// Pointers to transport block segments /// Pointers to transport block segments
uint8_t *c[MAX_NUM_ULSCH_SEGMENTS]; uint8_t *c[MAX_NUM_ULSCH_SEGMENTS];
/// RTC values for each segment (for definition see 36-212 V8.6 2009-03, p.15) /// RTC values for each segment (for definition see 36-212 V8.6 2009-03, p.15)
uint32_t RTCC[MAX_NUM_ULSCH_SEGMENTS]; uint32_t RTC[MAX_NUM_ULSCH_SEGMENTS];
/// Current Number of Symbols /// Current Number of Symbols
uint8_t Nsymb_pusch; uint8_t Nsymb_pusch;
/// SRS active flag /// SRS active flag
......
...@@ -49,7 +49,9 @@ int16_t find_uci(uint16_t rnti, int frame, int subframe, PHY_VARS_eNB *eNB,find_ ...@@ -49,7 +49,9 @@ int16_t find_uci(uint16_t rnti, int frame, int subframe, PHY_VARS_eNB *eNB,find_
else if ((eNB->uci_vars[i].active == 0) && (first_free_index==-1)) first_free_index=i; else if ((eNB->uci_vars[i].active == 0) && (first_free_index==-1)) first_free_index=i;
} }
if (type == SEARCH_EXIST) return(-1); if (type == SEARCH_EXIST) return(-1);
else return(first_free_index); if (first_free_index==-1)
LOG_E(MAC,"UCI table is full\n");
return(first_free_index);
} }
......
...@@ -44,9 +44,10 @@ ...@@ -44,9 +44,10 @@
//#define DEBUG_ULSCH_DECODING //#define DEBUG_ULSCH_DECODING
#include "targets/RT/USER/rt_wrapper.h" #include "targets/RT/USER/rt_wrapper.h"
#include "transport_proto.h" #include "transport_proto.h"
#include <executables/split_headers.h>
extern WORKER_CONF_t get_thread_worker_conf(void); extern WORKER_CONF_t get_thread_worker_conf(void);
void sendFs6Ul(PHY_VARS_eNB *eNB, int UE_id, int harq_pid, int segmentID, int16_t *data, int dataLen);
void free_eNB_ulsch(LTE_eNB_ULSCH_t *ulsch) { void free_eNB_ulsch(LTE_eNB_ULSCH_t *ulsch) {
int i,r; int i,r;
...@@ -275,7 +276,7 @@ int ulsch_decoding_data_2thread0(td_params *tdp) { ...@@ -275,7 +276,7 @@ int ulsch_decoding_data_2thread0(td_params *tdp) {
Kr_bytes = Kr>>3; Kr_bytes = Kr>>3;
memset(&dummy_w[r][0],0,3*(6144+64)*sizeof(short)); memset(&dummy_w[r][0],0,3*(6144+64)*sizeof(short));
ulsch_harq->RTCC[r] = generate_dummy_w(4+(Kr_bytes*8), ulsch_harq->RTC[r] = generate_dummy_w(4+(Kr_bytes*8),
(uint8_t *)&dummy_w[r][0], (uint8_t *)&dummy_w[r][0],
(r==0) ? ulsch_harq->F : 0); (r==0) ? ulsch_harq->F : 0);
#ifdef DEBUG_ULSCH_DECODING #ifdef DEBUG_ULSCH_DECODING
...@@ -287,7 +288,7 @@ int ulsch_decoding_data_2thread0(td_params *tdp) { ...@@ -287,7 +288,7 @@ int ulsch_decoding_data_2thread0(td_params *tdp) {
ulsch_harq->Nl); ulsch_harq->Nl);
#endif #endif
if (lte_rate_matching_turbo_rx(ulsch_harq->RTCC[r], if (lte_rate_matching_turbo_rx(ulsch_harq->RTC[r],
G, G,
ulsch_harq->w[r], ulsch_harq->w[r],
(uint8_t *) &dummy_w[r][0], (uint8_t *) &dummy_w[r][0],
...@@ -449,7 +450,7 @@ int ulsch_decoding_data_2thread(PHY_VARS_eNB *eNB,int UE_id,int harq_pid,int llr ...@@ -449,7 +450,7 @@ int ulsch_decoding_data_2thread(PHY_VARS_eNB *eNB,int UE_id,int harq_pid,int llr
Kr_bytes = Kr>>3; Kr_bytes = Kr>>3;
memset(&dummy_w[r][0],0,3*(6144+64)*sizeof(short)); memset(&dummy_w[r][0],0,3*(6144+64)*sizeof(short));
ulsch_harq->RTCC[r] = generate_dummy_w(4+(Kr_bytes*8), ulsch_harq->RTC[r] = generate_dummy_w(4+(Kr_bytes*8),
(uint8_t *)&dummy_w[r][0], (uint8_t *)&dummy_w[r][0],
(r==0) ? ulsch_harq->F : 0); (r==0) ? ulsch_harq->F : 0);
#ifdef DEBUG_ULSCH_DECODING #ifdef DEBUG_ULSCH_DECODING
...@@ -462,7 +463,7 @@ int ulsch_decoding_data_2thread(PHY_VARS_eNB *eNB,int UE_id,int harq_pid,int llr ...@@ -462,7 +463,7 @@ int ulsch_decoding_data_2thread(PHY_VARS_eNB *eNB,int UE_id,int harq_pid,int llr
#endif #endif
start_meas(&eNB->ulsch_rate_unmatching_stats); start_meas(&eNB->ulsch_rate_unmatching_stats);
if (lte_rate_matching_turbo_rx(ulsch_harq->RTCC[r], if (lte_rate_matching_turbo_rx(ulsch_harq->RTC[r],
G, G,
ulsch_harq->w[r], ulsch_harq->w[r],
(uint8_t *) &dummy_w[r][0], (uint8_t *) &dummy_w[r][0],
...@@ -572,7 +573,7 @@ int ulsch_decoding_data(PHY_VARS_eNB *eNB,int UE_id,int harq_pid,int llr8_flag) ...@@ -572,7 +573,7 @@ int ulsch_decoding_data(PHY_VARS_eNB *eNB,int UE_id,int harq_pid,int llr8_flag)
Kr_bytes = Kr>>3; Kr_bytes = Kr>>3;
memset(&dummy_w[r][0],0,3*(6144+64)*sizeof(short)); memset(&dummy_w[r][0],0,3*(6144+64)*sizeof(short));
ulsch_harq->RTCC[r] = generate_dummy_w(4+(Kr_bytes*8), ulsch_harq->RTC[r] = generate_dummy_w(4+(Kr_bytes*8),
(uint8_t *)&dummy_w[r][0], (uint8_t *)&dummy_w[r][0],
(r==0) ? ulsch_harq->F : 0); (r==0) ? ulsch_harq->F : 0);
#ifdef DEBUG_ULSCH_DECODING #ifdef DEBUG_ULSCH_DECODING
...@@ -585,7 +586,7 @@ int ulsch_decoding_data(PHY_VARS_eNB *eNB,int UE_id,int harq_pid,int llr8_flag) ...@@ -585,7 +586,7 @@ int ulsch_decoding_data(PHY_VARS_eNB *eNB,int UE_id,int harq_pid,int llr8_flag)
#endif #endif
start_meas(&eNB->ulsch_rate_unmatching_stats); start_meas(&eNB->ulsch_rate_unmatching_stats);
if (lte_rate_matching_turbo_rx(ulsch_harq->RTCC[r], if (lte_rate_matching_turbo_rx(ulsch_harq->RTC[r],
G, G,
ulsch_harq->w[r], ulsch_harq->w[r],
(uint8_t *) &dummy_w[r][0], (uint8_t *) &dummy_w[r][0],
...@@ -620,8 +621,24 @@ int ulsch_decoding_data(PHY_VARS_eNB *eNB,int UE_id,int harq_pid,int llr8_flag) ...@@ -620,8 +621,24 @@ int ulsch_decoding_data(PHY_VARS_eNB *eNB,int UE_id,int harq_pid,int llr8_flag)
if ( getenv("fs6") != NULL && strncasecmp( getenv("fs6"), "du", 2) == 0 ) { if ( getenv("fs6") != NULL && strncasecmp( getenv("fs6"), "du", 2) == 0 ) {
// r is the segment id, // r is the segment id,
// Kr is the segment length in short // Kr is the segment length in short
// *3 because LTE redudancy scheme // *3 because LTE redudancy scheme
sendFs6Ul(eNB, UE_id, harq_pid, r, &ulsch_harq->d[r][96], Kr*sizeof(int16_t)*3); sendFs6Ul(eNB, UE_id, harq_pid, r, &ulsch_harq->d[r][96], Kr*sizeof(int16_t)*3);
LOG_D(PHY, "Cu should decode in %d iter\n",tc(&ulsch_harq->d[r][96],
NULL,
ulsch_harq->c[r],
NULL,
Kr,
ulsch->max_turbo_iterations,//MAX_TURBO_ITERATIONS,
crc_type,
(r==0) ? ulsch_harq->F : 0,
&eNB->ulsch_tc_init_stats,
&eNB->ulsch_tc_alpha_stats,
&eNB->ulsch_tc_beta_stats,
&eNB->ulsch_tc_gamma_stats,
&eNB->ulsch_tc_ext_stats,
&eNB->ulsch_tc_intl1_stats,
&eNB->ulsch_tc_intl2_stats));
return 0; return 0;
} }
...@@ -642,6 +659,7 @@ int ulsch_decoding_data(PHY_VARS_eNB *eNB,int UE_id,int harq_pid,int llr8_flag) ...@@ -642,6 +659,7 @@ int ulsch_decoding_data(PHY_VARS_eNB *eNB,int UE_id,int harq_pid,int llr8_flag)
&eNB->ulsch_tc_intl1_stats, &eNB->ulsch_tc_intl1_stats,
&eNB->ulsch_tc_intl2_stats); &eNB->ulsch_tc_intl2_stats);
stop_meas(&eNB->ulsch_turbo_decoding_stats); stop_meas(&eNB->ulsch_turbo_decoding_stats);
LOG_D(PHY,"turbo decode in %d iter\n",ret);
// Reassembly of Transport block here // Reassembly of Transport block here
......
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
void fill_uci_harq_indication(int UEid, PHY_VARS_eNB *eNB,LTE_eNB_UCI *uci,int frame,int subframe,uint8_t *harq_ack,uint8_t tdd_mapping_mode,uint16_t tdd_multiplexing_mask); void fill_uci_harq_indication(int UEid, PHY_VARS_eNB *eNB,LTE_eNB_UCI *uci,int frame,int subframe,uint8_t *harq_ack,uint8_t tdd_mapping_mode,uint16_t tdd_multiplexing_mask);
void fill_ulsch_harq_indication(PHY_VARS_eNB *eNB,LTE_UL_eNB_HARQ_t *ulsch_harq,uint16_t rnti, int frame,int subframe,int bundling); void fill_ulsch_harq_indication(PHY_VARS_eNB *eNB,LTE_UL_eNB_HARQ_t *ulsch_harq,uint16_t rnti, int frame,int subframe,int bundling);
void fill_ulsch_cqi_indication(PHY_VARS_eNB *eNB,uint16_t frame,uint8_t subframe,LTE_UL_eNB_HARQ_t *ulsch_harq,uint16_t rnti); void fill_ulsch_cqi_indication(PHY_VARS_eNB *eNB,uint16_t frame,uint8_t subframe,LTE_UL_eNB_HARQ_t *ulsch_harq,uint16_t rnti);
void fill_sr_indication(PHY_VARS_eNB *eNB,uint16_t rnti,int frame,int subframe,uint32_t stat); void fill_sr_indication(int UEid, PHY_VARS_eNB *eNB,uint16_t rnti,int frame,int subframe,uint32_t stat);
void fill_rx_indication(PHY_VARS_eNB *eNB,int UE_id,int frame,int subframe); void fill_rx_indication(PHY_VARS_eNB *eNB,int UE_id,int frame,int subframe);
void fill_crc_indication(PHY_VARS_eNB *eNB,int UE_id,int frame,int subframe,uint8_t crc_flag); void fill_crc_indication(PHY_VARS_eNB *eNB,int UE_id,int frame,int subframe,uint8_t crc_flag);
void handle_nfapi_dci_dl_pdu(PHY_VARS_eNB *eNB,int frame,int subframe,L1_rxtx_proc_t *proc,nfapi_dl_config_request_pdu_t *dl_config_pdu); void handle_nfapi_dci_dl_pdu(PHY_VARS_eNB *eNB,int frame,int subframe,L1_rxtx_proc_t *proc,nfapi_dl_config_request_pdu_t *dl_config_pdu);
......
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
#include <time.h> #include <time.h>
#include "intertask_interface.h" #include "intertask_interface.h"
void sendFs6Ulharq(int UEid, PHY_VARS_eNB *eNB, int frame, int subframe, uint8_t *harq_ack, uint8_t tdd_mapping_mode, uint16_t tdd_multiplexing_mask); #include <executables/split_headers.h>
nfapi_ue_release_request_body_t release_rntis; nfapi_ue_release_request_body_t release_rntis;
...@@ -590,7 +590,11 @@ void srs_procedures(PHY_VARS_eNB *eNB,L1_rxtx_proc_t *proc) { ...@@ -590,7 +590,11 @@ void srs_procedures(PHY_VARS_eNB *eNB,L1_rxtx_proc_t *proc) {
} }
} }
void fill_sr_indication(PHY_VARS_eNB *eNB,uint16_t rnti,int frame,int subframe,uint32_t stat) { void fill_sr_indication(int UEid, PHY_VARS_eNB *eNB,uint16_t rnti,int frame,int subframe,uint32_t stat) {
if ( getenv("fs6") != NULL && strncasecmp( getenv("fs6"), "du", 2) == 0 ) {
sendFs6Ulharq(fs6ULindicationSr, UEid, eNB, frame, subframe, NULL,0,0, rnti, stat);
return;
}
pthread_mutex_lock(&eNB->UL_INFO_mutex); pthread_mutex_lock(&eNB->UL_INFO_mutex);
nfapi_sr_indication_t *sr_ind = &eNB->UL_INFO.sr_ind; nfapi_sr_indication_t *sr_ind = &eNB->UL_INFO.sr_ind;
nfapi_sr_indication_body_t *sr_ind_body = &sr_ind->sr_indication_body; nfapi_sr_indication_body_t *sr_ind_body = &sr_ind->sr_indication_body;
...@@ -706,7 +710,7 @@ uci_procedures(PHY_VARS_eNB *eNB, ...@@ -706,7 +710,7 @@ uci_procedures(PHY_VARS_eNB *eNB,
if (uci->type == SR) { if (uci->type == SR) {
if (SR_payload == 1) { if (SR_payload == 1) {
fill_sr_indication(eNB,uci->rnti,frame,subframe,metric_SR); fill_sr_indication(i, eNB,uci->rnti,frame,subframe,metric_SR);
break; break;
} else { } else {
break; break;
...@@ -742,7 +746,7 @@ uci_procedures(PHY_VARS_eNB *eNB, ...@@ -742,7 +746,7 @@ uci_procedures(PHY_VARS_eNB *eNB,
/* cancel SR detection if reception on n1_pucch0 is better than on SR PUCCH resource index, otherwise send it up to MAC */ /* cancel SR detection if reception on n1_pucch0 is better than on SR PUCCH resource index, otherwise send it up to MAC */
if (uci->type==HARQ_SR && metric[0] > metric_SR) SR_payload = 0; if (uci->type==HARQ_SR && metric[0] > metric_SR) SR_payload = 0;
else if (SR_payload == 1) fill_sr_indication(eNB,uci->rnti,frame,subframe,metric_SR); else if (SR_payload == 1) fill_sr_indication(i, eNB,uci->rnti,frame,subframe,metric_SR);
if (uci->type==HARQ_SR && metric[0] <= metric_SR) { if (uci->type==HARQ_SR && metric[0] <= metric_SR) {
/* when transmitting ACK/NACK on SR PUCCH resource index, SR payload is always 1 */ /* when transmitting ACK/NACK on SR PUCCH resource index, SR payload is always 1 */
...@@ -793,7 +797,7 @@ uci_procedures(PHY_VARS_eNB *eNB, ...@@ -793,7 +797,7 @@ uci_procedures(PHY_VARS_eNB *eNB,
); );
if (uci->type==HARQ_SR && metric[0] > metric_SR) SR_payload = 0; if (uci->type==HARQ_SR && metric[0] > metric_SR) SR_payload = 0;
else if (SR_payload == 1) fill_sr_indication(eNB,uci->rnti,frame,subframe,metric_SR); else if (SR_payload == 1) fill_sr_indication(i, eNB,uci->rnti,frame,subframe,metric_SR);
if (uci->type==HARQ_SR && metric[0] <= metric_SR) { if (uci->type==HARQ_SR && metric[0] <= metric_SR) {
SR_payload = 1; SR_payload = 1;
...@@ -1757,7 +1761,7 @@ void fill_ulsch_harq_indication (PHY_VARS_eNB *eNB, LTE_UL_eNB_HARQ_t *ulsch_har ...@@ -1757,7 +1761,7 @@ void fill_ulsch_harq_indication (PHY_VARS_eNB *eNB, LTE_UL_eNB_HARQ_t *ulsch_har
void fill_uci_harq_indication (int UEid, PHY_VARS_eNB *eNB, LTE_eNB_UCI *uci, int frame, int subframe, uint8_t *harq_ack, uint8_t tdd_mapping_mode, uint16_t tdd_multiplexing_mask) { void fill_uci_harq_indication (int UEid, PHY_VARS_eNB *eNB, LTE_eNB_UCI *uci, int frame, int subframe, uint8_t *harq_ack, uint8_t tdd_mapping_mode, uint16_t tdd_multiplexing_mask) {
if ( getenv("fs6") != NULL && strncasecmp( getenv("fs6"), "du", 2) == 0 ) { if ( getenv("fs6") != NULL && strncasecmp( getenv("fs6"), "du", 2) == 0 ) {
sendFs6Ulharq(UEid, eNB, frame, subframe, harq_ack, tdd_mapping_mode, tdd_multiplexing_mask); sendFs6Ulharq(fs6ULindicationHarq, UEid, eNB, frame, subframe, harq_ack, tdd_mapping_mode, tdd_multiplexing_mask, 0, 0);
return; return;
} }
......
...@@ -487,7 +487,7 @@ int rfsimulator_read(openair0_device *device, openair0_timestamp *ptimestamp, vo ...@@ -487,7 +487,7 @@ int rfsimulator_read(openair0_device *device, openair0_timestamp *ptimestamp, vo
if ( first_sock == FD_SETSIZE ) { if ( first_sock == FD_SETSIZE ) {
// no connected device (we are eNB, no UE is connected) // no connected device (we are eNB, no UE is connected)
if (!flushInput(t, 10)) { if (!flushInput(t, 100)) {
for (int x=0; x < nbAnt; x++) for (int x=0; x < nbAnt; x++)
memset(samplesVoid[x],0,sampleToByte(nsamps,1)); memset(samplesVoid[x],0,sampleToByte(nsamps,1));
......
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