Commit a58a5bc8 authored by Cedric Roux's avatar Cedric Roux

- Fix some more compiler warnings

Pre-ci tests passed


git-svn-id: http://svn.eurecom.fr/openair4G/trunk@4389 818b1a75-f10b-46b9-bf7c-635c3b92a50f
parent 2c899296
...@@ -138,7 +138,7 @@ char interleave_compact_byte(short * base_interleaver,unsigned char * input, uns ...@@ -138,7 +138,7 @@ char interleave_compact_byte(short * base_interleaver,unsigned char * input, uns
__m128i tmp; __m128i tmp;
int input_length_words=n>>1; int input_length_words=n>>1;
unsigned short * systematic2_ptr=(unsigned short *) output; unsigned short * systematic2_ptr=(unsigned short *) output;
int j; // int j;
for ( i=0; i< input_length_words ; i ++ ) { for ( i=0; i< input_length_words ; i ++ ) {
// for (j=0;j<16;j++) printf("%d(%d).",ptr_intl[j],expandInput[ptr_intl[j]]); // for (j=0;j<16;j++) printf("%d(%d).",ptr_intl[j],expandInput[ptr_intl[j]]);
......
...@@ -413,9 +413,9 @@ uint32_t lte_rate_matching_turbo(uint32_t RTC, ...@@ -413,9 +413,9 @@ uint32_t lte_rate_matching_turbo(uint32_t RTC,
uint32_t Nir,Ncb,Gp,GpmodC,E,Ncbmod,ind,k; uint32_t Nir,Ncb,Gp,GpmodC,E,Ncbmod,ind,k;
// int cnt=0; // int cnt=0;
int code_block,round;
uint8_t *e2; uint8_t *e2;
#ifdef RM_DEBUG_TX #ifdef RM_DEBUG_TX
int code_block,round;
int cnt; int cnt;
int zeroed=0; int zeroed=0;
int oned=0; int oned=0;
...@@ -626,7 +626,7 @@ int lte_rate_matching_turbo_rx(uint32_t RTC, ...@@ -626,7 +626,7 @@ int lte_rate_matching_turbo_rx(uint32_t RTC,
uint32_t Nir,Ncb,Gp,GpmodC,E,Ncbmod,ind,k; uint32_t Nir,Ncb,Gp,GpmodC,E,Ncbmod,ind,k;
int16_t *soft_input2; int16_t *soft_input2;
s32 w_tmp; // s32 w_tmp;
#ifdef RM_DEBUG #ifdef RM_DEBUG
int nulled=0; int nulled=0;
#endif #endif
......
...@@ -443,9 +443,9 @@ void phy_config_afterHO_ue(u8 Mod_id,u8 eNB_id, MobilityControlInfo_t *mobilityC ...@@ -443,9 +443,9 @@ void phy_config_afterHO_ue(u8 Mod_id,u8 eNB_id, MobilityControlInfo_t *mobilityC
//PHY_vars_UE_g[UE_id]->UE_mode[0] = PRACH; //PHY_vars_UE_g[UE_id]->UE_mode[0] = PRACH;
LTE_DL_FRAME_PARMS *lte_frame_parms = &PHY_vars_UE_g[Mod_id]->lte_frame_parms; LTE_DL_FRAME_PARMS *lte_frame_parms = &PHY_vars_UE_g[Mod_id]->lte_frame_parms;
int N_ZC; // int N_ZC;
u8 prach_fmt; // u8 prach_fmt;
int u; // int u;
LOG_I(PHY,"[UE%d] Frame %d: Handover triggered: Applying radioResourceConfigCommon from eNB %d\n", LOG_I(PHY,"[UE%d] Frame %d: Handover triggered: Applying radioResourceConfigCommon from eNB %d\n",
Mod_id,PHY_vars_UE_g[Mod_id]->frame,eNB_id); Mod_id,PHY_vars_UE_g[Mod_id]->frame,eNB_id);
...@@ -457,10 +457,10 @@ void phy_config_afterHO_ue(u8 Mod_id,u8 eNB_id, MobilityControlInfo_t *mobilityC ...@@ -457,10 +457,10 @@ void phy_config_afterHO_ue(u8 Mod_id,u8 eNB_id, MobilityControlInfo_t *mobilityC
lte_frame_parms->prach_config_common.prach_ConfigInfo.zeroCorrelationZoneConfig =radioResourceConfigCommon->prach_Config.prach_ConfigInfo->zeroCorrelationZoneConfig; lte_frame_parms->prach_config_common.prach_ConfigInfo.zeroCorrelationZoneConfig =radioResourceConfigCommon->prach_Config.prach_ConfigInfo->zeroCorrelationZoneConfig;
lte_frame_parms->prach_config_common.prach_ConfigInfo.prach_FreqOffset =radioResourceConfigCommon->prach_Config.prach_ConfigInfo->prach_FreqOffset; lte_frame_parms->prach_config_common.prach_ConfigInfo.prach_FreqOffset =radioResourceConfigCommon->prach_Config.prach_ConfigInfo->prach_FreqOffset;
prach_fmt = get_prach_fmt(radioResourceConfigCommon->prach_Config.prach_ConfigInfo->prach_ConfigIndex,lte_frame_parms->frame_type); // prach_fmt = get_prach_fmt(radioResourceConfigCommon->prach_Config.prach_ConfigInfo->prach_ConfigIndex,lte_frame_parms->frame_type);
N_ZC = (prach_fmt <4)?839:139; // N_ZC = (prach_fmt <4)?839:139;
u = (prach_fmt < 4) ? prach_root_sequence_map0_3[lte_frame_parms->prach_config_common.rootSequenceIndex] : // u = (prach_fmt < 4) ? prach_root_sequence_map0_3[lte_frame_parms->prach_config_common.rootSequenceIndex] :
prach_root_sequence_map4[lte_frame_parms->prach_config_common.rootSequenceIndex]; // prach_root_sequence_map4[lte_frame_parms->prach_config_common.rootSequenceIndex];
//compute_prach_seq(u,N_ZC, PHY_vars_UE_g[Mod_id]->X_u); //compute_prach_seq(u,N_ZC, PHY_vars_UE_g[Mod_id]->X_u);
compute_prach_seq(&PHY_vars_UE_g[Mod_id]->lte_frame_parms.prach_config_common, compute_prach_seq(&PHY_vars_UE_g[Mod_id]->lte_frame_parms.prach_config_common,
......
...@@ -18,11 +18,14 @@ extern int card; ...@@ -18,11 +18,14 @@ extern int card;
void void
phy_adjust_gain (PHY_VARS_UE *phy_vars_ue, u8 eNB_id) { phy_adjust_gain (PHY_VARS_UE *phy_vars_ue, u8 eNB_id) {
u16 rx_power_fil_dB,i; u16 rx_power_fil_dB;
#ifdef EXMIMO #ifdef EXMIMO
#ifdef DRIVER2013 #ifdef DRIVER2013
exmimo_config_t *p_exmimo_config = openair0_exmimo_pci[card].exmimo_config_ptr; exmimo_config_t *p_exmimo_config = openair0_exmimo_pci[card].exmimo_config_ptr;
#endif #endif
#endif
#if defined(EXMIMO) || defined(CBMIMO1)
u16 i;
#endif #endif
//rx_power_fil_dB = dB_fixed(phy_vars_ue->PHY_measurements.rssi); //rx_power_fil_dB = dB_fixed(phy_vars_ue->PHY_measurements.rssi);
......
...@@ -3208,6 +3208,8 @@ int generate_ue_ulsch_params_from_dci(void *dci_pdu, ...@@ -3208,6 +3208,8 @@ int generate_ue_ulsch_params_from_dci(void *dci_pdu,
msg("Format 0 DCI :ulsch (ue): Nsymb_pusch %d\n",ulsch->Nsymb_pusch); msg("Format 0 DCI :ulsch (ue): Nsymb_pusch %d\n",ulsch->Nsymb_pusch);
msg("Format 0 DCI :ulsch (ue): cshift %d\n",ulsch->harq_processes[harq_pid]->n_DMRS2); msg("Format 0 DCI :ulsch (ue): cshift %d\n",ulsch->harq_processes[harq_pid]->n_DMRS2);
#else
UNUSED_VARIABLE(dai);
#endif #endif
return(0); return(0);
} }
...@@ -3570,6 +3572,8 @@ int generate_eNB_ulsch_params_from_dci(void *dci_pdu, ...@@ -3570,6 +3572,8 @@ int generate_eNB_ulsch_params_from_dci(void *dci_pdu,
msg("ulsch (eNB): Or1 %d\n",ulsch->Or1); msg("ulsch (eNB): Or1 %d\n",ulsch->Or1);
msg("ulsch (eNB): Nsymb_pusch %d\n",ulsch->Nsymb_pusch); msg("ulsch (eNB): Nsymb_pusch %d\n",ulsch->Nsymb_pusch);
msg("ulsch (eNB): cshift %d\n",ulsch->harq_processes[harq_pid]->n_DMRS2); msg("ulsch (eNB): cshift %d\n",ulsch->harq_processes[harq_pid]->n_DMRS2);
#else
UNUSED_VARIABLE(dai);
#endif #endif
return(0); return(0);
} }
......
...@@ -32,7 +32,7 @@ void apply_7_5_kHz(PHY_VARS_UE *phy_vars_ue,s32*txdata,u8 slot) { ...@@ -32,7 +32,7 @@ void apply_7_5_kHz(PHY_VARS_UE *phy_vars_ue,s32*txdata,u8 slot) {
u32 *kHz7_5ptr; u32 *kHz7_5ptr;
__m128i *txptr128,*kHz7_5ptr128,mmtmp_re,mmtmp_im,mmtmp_re2,mmtmp_im2; __m128i *txptr128,*kHz7_5ptr128,mmtmp_re,mmtmp_im,mmtmp_re2,mmtmp_im2;
u32 slot_offset; u32 slot_offset;
u8 aa; // u8 aa;
u32 i; u32 i;
LTE_DL_FRAME_PARMS *frame_parms=&phy_vars_ue->lte_frame_parms; LTE_DL_FRAME_PARMS *frame_parms=&phy_vars_ue->lte_frame_parms;
......
...@@ -1020,7 +1020,7 @@ int mult_cpx_vector_norep_conj2(s16 *x1, ...@@ -1020,7 +1020,7 @@ int mult_cpx_vector_norep_conj2(s16 *x1,
s16 *temps; // s16 *temps;
int *tempw; int *tempw;
......
...@@ -139,4 +139,6 @@ ...@@ -139,4 +139,6 @@
#define printk printf #define printk printf
#endif #endif
#endif #define UNUSED_VARIABLE(vARIABLE) (void)(vARIABLE)
#endif /* __PLATFORM_CONSTANTS_H__ */
...@@ -9,9 +9,8 @@ ...@@ -9,9 +9,8 @@
#ifndef __PLATFORM_TYPES_H__ #ifndef __PLATFORM_TYPES_H__
# define __PLATFORM_TYPES_H__ # define __PLATFORM_TYPES_H__
#ifndef USER_MODE #ifdef USER_MODE
#else # include "openair_types.h"
#include "openair_types.h"
#endif #endif
typedef unsigned char u8_t; typedef unsigned char u8_t;
......
...@@ -229,11 +229,9 @@ PRACH_RESOURCES_t *ue_get_rach(u8 Mod_id,u32 frame, u8 eNB_index,u8 subframe){ ...@@ -229,11 +229,9 @@ PRACH_RESOURCES_t *ue_get_rach(u8 Mod_id,u32 frame, u8 eNB_index,u8 subframe){
s32 frame_diff=0; s32 frame_diff=0;
mac_rlc_status_resp_t rlc_status; mac_rlc_status_resp_t rlc_status;
u8 dcch_header_len=0; u8 dcch_header_len=0;
u8 dcch_header_len_tmp=0;
u16 sdu_lengths[8]; u16 sdu_lengths[8];
u8 sdu_lcids[8],payload_offset=0,num_sdus=0; u8 sdu_lcids[8];
u8 ulsch_buff[MAX_ULSCH_PAYLOAD_BYTES]; u8 ulsch_buff[MAX_ULSCH_PAYLOAD_BYTES];
u16 sdu_length_total=0;
if (UE_mode == PRACH) { if (UE_mode == PRACH) {
if (UE_mac_inst[Mod_id].radioResourceConfigCommon) if (UE_mac_inst[Mod_id].radioResourceConfigCommon)
...@@ -313,11 +311,9 @@ PRACH_RESOURCES_t *ue_get_rach(u8 Mod_id,u32 frame, u8 eNB_index,u8 subframe){ ...@@ -313,11 +311,9 @@ PRACH_RESOURCES_t *ue_get_rach(u8 Mod_id,u32 frame, u8 eNB_index,u8 subframe){
DCCH, DCCH,
(char *)&ulsch_buff[0]); (char *)&ulsch_buff[0]);
sdu_length_total = sdu_lengths[0];
sdu_lcids[0] = DCCH; sdu_lcids[0] = DCCH;
LOG_D(MAC,"[UE %d] TX Got %d bytes for DCCH\n",Mod_id,sdu_lengths[0]); LOG_D(MAC,"[UE %d] TX Got %d bytes for DCCH\n",Mod_id,sdu_lengths[0]);
num_sdus = 1;
update_bsr(Mod_id, frame, DCCH,UE_mac_inst[Mod_id].scheduling_info.LCGID[DCCH]); update_bsr(Mod_id, frame, DCCH,UE_mac_inst[Mod_id].scheduling_info.LCGID[DCCH]);
//header_len +=2; //header_len +=2;
UE_mac_inst[Mod_id].RA_active = 1; UE_mac_inst[Mod_id].RA_active = 1;
......
...@@ -113,7 +113,11 @@ int set_gateway(char *interfaceName, char *gateway) ...@@ -113,7 +113,11 @@ int set_gateway(char *interfaceName, char *gateway)
rt.rt_dev = interfaceName; rt.rt_dev = interfaceName;
//rt.rt_flags = RTF_UP|RTF_GATEWAY|RTF_DEFAULT; //rt.rt_flags = RTF_UP|RTF_GATEWAY|RTF_DEFAULT;
rt.rt_flags = RTF_GATEWAY|RTF_DEFAULT; /* SR: rt_flags on 16 bits but RTF_DEFAULT = 0x00010000
* therefore doesn't lie in container -> disable it
*/
//rt.rt_flags = RTF_GATEWAY|RTF_DEFAULT;
rt.rt_flags = RTF_GATEWAY;
if (ioctl(sock_fd, SIOCADDRT, &rt) < 0) if (ioctl(sock_fd, SIOCADDRT, &rt) < 0)
{ {
......
...@@ -16,7 +16,6 @@ ...@@ -16,7 +16,6 @@
void job_list_init (Job_List * listP) { void job_list_init (Job_List * listP) {
int i = 0;
listP->tail = NULL; listP->tail = NULL;
listP->head = NULL; listP->head = NULL;
...@@ -24,7 +23,6 @@ void job_list_init (Job_List * listP) { ...@@ -24,7 +23,6 @@ void job_list_init (Job_List * listP) {
} }
void event_list_init (Event_List * listP) { void event_list_init (Event_List * listP) {
int i = 0;
listP->tail = NULL; listP->tail = NULL;
listP->head = NULL; listP->head = NULL;
...@@ -32,7 +30,6 @@ void event_list_init (Event_List * listP) { ...@@ -32,7 +30,6 @@ void event_list_init (Event_List * listP) {
} }
void pkt_list_init (Packet_OTG_List * listP) { void pkt_list_init (Packet_OTG_List * listP) {
int i = 0;
listP->tail = NULL; listP->tail = NULL;
listP->head = NULL; listP->head = NULL;
......
...@@ -47,6 +47,8 @@ ...@@ -47,6 +47,8 @@
#include "client_traci_OMG.h" #include "client_traci_OMG.h"
#include "TraCIConstants.h" #include "TraCIConstants.h"
#define UNUSED_VARIABLE(vARIABLE) (void)(vARIABLE)
int handshake(char *hoststr,int portno){ int handshake(char *hoststr,int portno){
check_endianness(); // check endianness check_endianness(); // check endianness
...@@ -140,13 +142,17 @@ void processSubscriptions() { ...@@ -140,13 +142,17 @@ void processSubscriptions() {
} }
char *objID = readString(); char *objID = readString();
int varNo = readUnsignedByte(); int varNo = readUnsignedByte();
UNUSED_VARIABLE(objID);
UNUSED_VARIABLE(respStart);
int i; int i;
for (i=0; i<varNo; ++i) { for (i=0; i<varNo; ++i) {
int varID = readUnsignedByte(); int varID = readUnsignedByte();
bool ok = readUnsignedByte()==RTYPE_OK; bool ok = readUnsignedByte()==RTYPE_OK;
int valueDataType = readUnsignedByte(); int valueDataType = readUnsignedByte();
UNUSED_VARIABLE(valueDataType);
if (ok&&cmdId==CMD_SUBSCRIBE_SIM_VARIABLE+0x10&&varID==VAR_DEPARTED_VEHICLES_IDS) { if (ok&&cmdId==CMD_SUBSCRIBE_SIM_VARIABLE+0x10&&varID==VAR_DEPARTED_VEHICLES_IDS) {
tmp_departed = readStringList(tmp_departed); tmp_departed = readStringList(tmp_departed);
//printf(" OMG Got departed cars\n"); //printf(" OMG Got departed cars\n");
...@@ -176,7 +182,7 @@ int extractCommandStatus(storage *s, unsigned char commandId, char * description ...@@ -176,7 +182,7 @@ int extractCommandStatus(storage *s, unsigned char commandId, char * description
// tracker currently points to the begining of the recieved data in the linked list // tracker currently points to the begining of the recieved data in the linked list
tracker = s; tracker = s;
storage *freeTracker = tracker; // save it for calling free // storage *freeTracker = tracker; // save it for calling free
int commandLength = readUnsignedByte(); int commandLength = readUnsignedByte();
...@@ -210,8 +216,11 @@ int extractCommandStatus(storage *s, unsigned char commandId, char * description ...@@ -210,8 +216,11 @@ int extractCommandStatus(storage *s, unsigned char commandId, char * description
//free actual message content //free actual message content
//depends on the message which is handled //depends on the message which is handled
/* if (commandId != CMD_GET_VEHICLE_VARIABLE) /* if (commandId != CMD_GET_VEHICLE_VARIABLE)
freeStorage(freeTracker);*/ freeStorage(freeTracker);*/
UNUSED_VARIABLE(commandLength);
UNUSED_VARIABLE(storageLength_);
return success; return success;
} }
...@@ -312,6 +321,10 @@ void commandGetVehicleVariable(char *vehID, int varID)// malloc for vehID and va ...@@ -312,6 +321,10 @@ void commandGetVehicleVariable(char *vehID, int varID)// malloc for vehID and va
char* rs = readString(); char* rs = readString();
int valueDataType = readUnsignedByte(); int valueDataType = readUnsignedByte();
UNUSED_VARIABLE(VariableID);
UNUSED_VARIABLE(rs);
UNUSED_VARIABLE(valueDataType);
UNUSED_VARIABLE(domID);
} }
} }
...@@ -375,6 +388,12 @@ int commandGetMaxSUMONodesVariable() ...@@ -375,6 +388,12 @@ int commandGetMaxSUMONodesVariable()
else { else {
//LOG_W(OMG, " No Matching Data Type Value \n"); //LOG_W(OMG, " No Matching Data Type Value \n");
} }
UNUSED_VARIABLE(res);
UNUSED_VARIABLE(Length);
UNUSED_VARIABLE(flag);
UNUSED_VARIABLE(dom);
UNUSED_VARIABLE(domID);
UNUSED_VARIABLE(VariableID);
} }
return max_car; return max_car;
......
...@@ -121,13 +121,11 @@ Job_list quick_sort (Job_list list) ...@@ -121,13 +121,11 @@ Job_list quick_sort (Job_list list)
Job_list remove_job(Job_list list, int nID, int node_type){ Job_list remove_job(Job_list list, int nID, int node_type){
int found;
Job_list current, previous; Job_list current, previous;
//int cond=0; //int cond=0;
int i=0; int i=0;
if (list == NULL){ if (list == NULL){
found = 1; //false
return NULL; return NULL;
} }
else{ //start search else{ //start search
...@@ -153,12 +151,10 @@ Job_list remove_job(Job_list list, int nID, int node_type){ ...@@ -153,12 +151,10 @@ Job_list remove_job(Job_list list, int nID, int node_type){
//if (current->pair->b->type == node_type){LOG_D(OMG, "current->pair->b->type == node_type");} //if (current->pair->b->type == node_type){LOG_D(OMG, "current->pair->b->type == node_type");}
if (current ==NULL) { if (current ==NULL) {
found= 1 ;
LOG_D(OMG," Job to remove is not found\n "); //LOG_N LOG_D(OMG," Job to remove is not found\n "); //LOG_N
return NULL; return NULL;
} //value not found } //value not found
else{ else{
found = 0; // true value found
if (current == list) { if (current == list) {
list = current->next ; list = current->next ;
LOG_D(OMG,"Job to remove is found at the beginning\n"); LOG_D(OMG,"Job to remove is found at the beginning\n");
......
...@@ -69,8 +69,6 @@ int otg_rx_pkt( int src, int dst, int ctime, char *buffer_tx, unsigned int size) ...@@ -69,8 +69,6 @@ int otg_rx_pkt( int src, int dst, int ctime, char *buffer_tx, unsigned int size)
unsigned int seq_num_rx; unsigned int seq_num_rx;
unsigned int nb_loss_pkts; unsigned int nb_loss_pkts;
unsigned int lost_packet=0; unsigned int lost_packet=0;
unsigned int i;
char * hdr_payload=NULL;
//int header_size; //int header_size;
if (buffer_tx!=NULL) { if (buffer_tx!=NULL) {
......
...@@ -388,8 +388,12 @@ void do_DL_sig(double **r_re0,double **r_im0, ...@@ -388,8 +388,12 @@ void do_DL_sig(double **r_re0,double **r_im0,
12); 12);
rx_pwr2 = signal_energy(rxdata[0]+slot_offset,512); rx_pwr2 = signal_energy(rxdata[0]+slot_offset,512);
#ifdef DEBUG_SIM #ifdef DEBUG_SIM
LOG_D(OCM,"[SIM][DL] UE %d : rx_pwr (ADC out) %f dB (%d) for slot %d (subframe %d), writing to %p\n",UE_id, 10*log10((double)rx_pwr2),rx_pwr2,next_slot,next_slot>>1,rxdata); LOG_D(OCM,"[SIM][DL] UE %d : rx_pwr (ADC out) %f dB (%d) for slot %d (subframe %d), writing to %p\n",UE_id, 10*log10((double)rx_pwr2),rx_pwr2,next_slot,next_slot>>1,rxdata);
#else
UNUSED_VARIABLE(rx_pwr2);
UNUSED_VARIABLE(tx_pwr);
UNUSED_VARIABLE(rx_pwr);
#endif #endif
//}// UE_index loop //}// UE_index loop
} }
...@@ -400,8 +404,9 @@ void do_DL_sig(double **r_re0,double **r_im0, ...@@ -400,8 +404,9 @@ void do_DL_sig(double **r_re0,double **r_im0,
void do_UL_sig(double **r_re0,double **r_im0,double **r_re,double **r_im,double **s_re,double **s_im,channel_desc_t *UE2eNB[NUMBER_OF_UE_MAX][NUMBER_OF_eNB_MAX],node_desc_t *enb_data[NUMBER_OF_eNB_MAX],node_desc_t *ue_data[NUMBER_OF_UE_MAX],u16 next_slot,u8 abstraction_flag,LTE_DL_FRAME_PARMS *frame_parms, u32 frame) { void do_UL_sig(double **r_re0,double **r_im0,double **r_re,double **r_im,double **s_re,double **s_im,channel_desc_t *UE2eNB[NUMBER_OF_UE_MAX][NUMBER_OF_eNB_MAX],node_desc_t *enb_data[NUMBER_OF_eNB_MAX],node_desc_t *ue_data[NUMBER_OF_UE_MAX],u16 next_slot,u8 abstraction_flag,LTE_DL_FRAME_PARMS *frame_parms, u32 frame) {
s32 **txdata,**rxdata; s32 **txdata,**rxdata;
#ifdef PHY_ABSTRACTION_UL
s32 att_eNB_id=-1; s32 att_eNB_id=-1;
#endif
u8 eNB_id=0,UE_id=0; u8 eNB_id=0,UE_id=0;
u8 nb_antennas_rx = UE2eNB[0][0]->nb_rx; // number of rx antennas at eNB u8 nb_antennas_rx = UE2eNB[0][0]->nb_rx; // number of rx antennas at eNB
...@@ -411,18 +416,18 @@ void do_UL_sig(double **r_re0,double **r_im0,double **r_re,double **r_im,double ...@@ -411,18 +416,18 @@ void do_UL_sig(double **r_re0,double **r_im0,double **r_re,double **r_im,double
s32 rx_pwr2; s32 rx_pwr2;
u32 i,aa; u32 i,aa;
u32 slot_offset,slot_offset_meas; u32 slot_offset,slot_offset_meas;
double min_path_loss=-200;
u16 ul_nb_rb=0 ;
u16 ul_fr_rb=0;
int ulnbrb2 ;
int ulfrrb2 ;
u8 harq_pid;
u8 hold_channel=0; u8 hold_channel=0;
#ifdef PHY_ABSTRACTION_UL
double min_path_loss=-200;
int subframe = (next_slot>>1); int subframe = (next_slot>>1);
// u8 aatx,aarx;
u8 harq_pid;
u16 ul_nb_rb=0;
u16 ul_fr_rb=0;
#endif
if (next_slot==4) if (next_slot==4)
{ {
...@@ -624,8 +629,13 @@ void do_UL_sig(double **r_re0,double **r_im0,double **r_re,double **r_im,double ...@@ -624,8 +629,13 @@ void do_UL_sig(double **r_re0,double **r_im0,double **r_re,double **r_im,double
rx_pwr2 = signal_energy(rxdata[0]+slot_offset,frame_parms->samples_per_tti>>1); rx_pwr2 = signal_energy(rxdata[0]+slot_offset,frame_parms->samples_per_tti>>1);
#ifdef DEBUG_SIM #ifdef DEBUG_SIM
printf("[SIM][UL] eNB %d rx_pwr (ADC out) %f dB (%d) for slot %d (subframe %d)\n",eNB_id,10*log10((double)rx_pwr2),rx_pwr2,next_slot,next_slot>>1); printf("[SIM][UL] eNB %d rx_pwr (ADC out) %f dB (%d) for slot %d (subframe %d)\n",
#endif eNB_id,10*log10((double)rx_pwr2),rx_pwr2,next_slot,next_slot>>1);
#else
UNUSED_VARIABLE(tx_pwr);
UNUSED_VARIABLE(rx_pwr);
UNUSED_VARIABLE(rx_pwr2);
#endif
} // eNB_id } // eNB_id
} // abstraction_flag==0 } // abstraction_flag==0
......
...@@ -205,7 +205,6 @@ void calc_path_loss(node_desc_t* enb_data, node_desc_t* ue_data, channel_desc_t ...@@ -205,7 +205,6 @@ void calc_path_loss(node_desc_t* enb_data, node_desc_t* ue_data, channel_desc_t
void init_snr(channel_desc_t* eNB2UE, node_desc_t *enb_data, node_desc_t *ue_data, double* sinr_dB, double* N0, u8 transmission_mode, u16 q, u8 dl_power_off) { void init_snr(channel_desc_t* eNB2UE, node_desc_t *enb_data, node_desc_t *ue_data, double* sinr_dB, double* N0, u8 transmission_mode, u16 q, u8 dl_power_off) {
int return_value;
u16 nb_rb = 25; //No. of resource blocks u16 nb_rb = 25; //No. of resource blocks
double thermal_noise,abs_channel,channelx, channely,channelx_i, channely_i ; double thermal_noise,abs_channel,channelx, channely,channelx_i, channely_i ;
int count; int count;
......
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