Commit ca98dc9d authored by lfarizav's avatar lfarizav

pbch,sib1/2/3 in frequency domain

parent 450b970c
...@@ -139,7 +139,7 @@ eNBs = ...@@ -139,7 +139,7 @@ eNBs =
////////// MME parameters: ////////// MME parameters:
mme_ip_address = ( { ipv4 = "172.24.11.201"; mme_ip_address = ( { ipv4 = "172.24.10.112";
ipv6 = "192:168:30::17"; ipv6 = "192:168:30::17";
active = "yes"; active = "yes";
preference = "ipv4"; preference = "ipv4";
...@@ -150,9 +150,9 @@ eNBs = ...@@ -150,9 +150,9 @@ eNBs =
{ {
ENB_INTERFACE_NAME_FOR_S1_MME = "eth0"; ENB_INTERFACE_NAME_FOR_S1_MME = "eth0";
ENB_IPV4_ADDRESS_FOR_S1_MME = "172.24.10.219/24"; ENB_IPV4_ADDRESS_FOR_S1_MME = "192.168.12.171/24";
ENB_INTERFACE_NAME_FOR_S1U = "eth3"; ENB_INTERFACE_NAME_FOR_S1U = "eth0";
ENB_IPV4_ADDRESS_FOR_S1U = "172.24.10.219/24"; ENB_IPV4_ADDRESS_FOR_S1U = "192.168.12.171/24";
ENB_PORT_FOR_S1U = 2152; # Spec 2152 ENB_PORT_FOR_S1U = 2152; # Spec 2152
}; };
......
...@@ -493,7 +493,7 @@ static void *UE_thread_synch_freq(void *arg) { ...@@ -493,7 +493,7 @@ static void *UE_thread_synch_freq(void *arg) {
int freq_offset=0; int freq_offset=0;
char threadname[128]; char threadname[128];
int do_ofdm_mod = UE->do_ofdm_mod; //int do_ofdm_mod = UE->do_ofdm_mod;
cpu_set_t cpuset; cpu_set_t cpuset;
CPU_ZERO(&cpuset); CPU_ZERO(&cpuset);
...@@ -1033,12 +1033,12 @@ void *UE_thread(void *arg) { ...@@ -1033,12 +1033,12 @@ void *UE_thread(void *arg) {
UE->current_thread_id[sub_frame] = thread_idx; UE->current_thread_id[sub_frame] = thread_idx;
LOG_D(PHY,"Process Subframe %d thread Idx %d , frame %d \n", sub_frame, UE->current_thread_id[sub_frame],proc->frame_rx); LOG_D(PHY,"Process Subframe %d thread Idx %d , frame %d \n", sub_frame, UE->current_thread_id[sub_frame],proc->frame_rx);
if (sub_frame==6 && ((proc->frame_rx&0x1)==0)) /*if (sub_frame==6 && ((proc->frame_rx&0x1)==0))
{ {
write_output("lteue_rxsigF_frame0.m","lteue_rxsF0", UE->common_vars.common_vars_rx_data_per_thread[0].rxdataF[0],10*UE->frame_parms.ofdm_symbol_size*UE->frame_parms.symbols_per_tti,1,16); write_output("lteue_rxsigF_frame0.m","lteue_rxsF0", UE->common_vars.common_vars_rx_data_per_thread[0].rxdataF[0],10*UE->frame_parms.ofdm_symbol_size*UE->frame_parms.symbols_per_tti,1,16);
write_output("lteue_rxsigF_frame1.m","lteue_rxsF1", UE->common_vars.common_vars_rx_data_per_thread[1].rxdataF[0],10*UE->frame_parms.ofdm_symbol_size*UE->frame_parms.symbols_per_tti,1,16); write_output("lteue_rxsigF_frame1.m","lteue_rxsF1", UE->common_vars.common_vars_rx_data_per_thread[1].rxdataF[0],10*UE->frame_parms.ofdm_symbol_size*UE->frame_parms.symbols_per_tti,1,16);
//exit(-1); //exit(-1);
} }*/
thread_idx++; thread_idx++;
if(thread_idx>=RX_NB_TH) if(thread_idx>=RX_NB_TH)
...@@ -1319,12 +1319,6 @@ void *UE_thread_freq(void *arg) { ...@@ -1319,12 +1319,6 @@ void *UE_thread_freq(void *arg) {
UE->current_thread_id[sub_frame] = thread_idx; UE->current_thread_id[sub_frame] = thread_idx;
LOG_D(PHY,"Process Subframe %d thread Idx %d , frame %d \n", sub_frame, UE->current_thread_id[sub_frame],proc->frame_rx); LOG_D(PHY,"Process Subframe %d thread Idx %d , frame %d \n", sub_frame, UE->current_thread_id[sub_frame],proc->frame_rx);
//if (sub_frame==5 && ((proc->frame_rx&0x1)==0))
//{
write_output("lteue_rxsigF_frame0.m","lteue_rxsF0", UE->common_vars.common_vars_rx_data_per_thread[0].rxdataF[0],10*UE->frame_parms.ofdm_symbol_size*UE->frame_parms.symbols_per_tti,1,16);
write_output("lteue_rxsigF_frame1.m","lteue_rxsF1", UE->common_vars.common_vars_rx_data_per_thread[1].rxdataF[0],10*UE->frame_parms.ofdm_symbol_size*UE->frame_parms.symbols_per_tti,1,16);
//exit(-1);
//}
thread_idx++; thread_idx++;
if(thread_idx>=RX_NB_TH) if(thread_idx>=RX_NB_TH)
...@@ -1394,6 +1388,12 @@ void *UE_thread_freq(void *arg) { ...@@ -1394,6 +1388,12 @@ void *UE_thread_freq(void *arg) {
for (th_id=0; th_id < RX_NB_TH; th_id++) { for (th_id=0; th_id < RX_NB_TH; th_id++) {
UE->proc.proc_rxtx[th_id].frame_rx++; UE->proc.proc_rxtx[th_id].frame_rx++;
} }
}
if (sub_frame<10 && ((proc->frame_rx&0x1)==0)){
write_output("lteue_rxsigF_frame0.m","lteue_rxsF0", UE->common_vars.common_vars_rx_data_per_thread[0].rxdataF[0],10*UE->frame_parms.ofdm_symbol_size*UE->frame_parms.symbols_per_tti,1,16);
write_output("lteue_rxsigF_frame1.m","lteue_rxsF1", UE->common_vars.common_vars_rx_data_per_thread[1].rxdataF[0],10*UE->frame_parms.ofdm_symbol_size*UE->frame_parms.symbols_per_tti,1,16);
//exit(-1);
} }
//UE->proc.proc_rxtx[0].gotIQs=readTime(gotIQs); //UE->proc.proc_rxtx[0].gotIQs=readTime(gotIQs);
//UE->proc.proc_rxtx[1].gotIQs=readTime(gotIQs); //UE->proc.proc_rxtx[1].gotIQs=readTime(gotIQs);
......
...@@ -531,7 +531,7 @@ void do_DL_sig_freq(channel_desc_t *eNB2UE[NUMBER_OF_eNB_MAX][NUMBER_OF_UE_MAX][ ...@@ -531,7 +531,7 @@ void do_DL_sig_freq(channel_desc_t *eNB2UE[NUMBER_OF_eNB_MAX][NUMBER_OF_UE_MAX][
txdataF = PHY_vars_eNB_g[eNB_id][CC_id]->common_vars.txdataF[0]; txdataF = PHY_vars_eNB_g[eNB_id][CC_id]->common_vars.txdataF[0];
sf_offset = subframe*frame_parms->ofdm_symbol_size*frame_parms->symbols_per_tti; sf_offset = subframe*frame_parms->ofdm_symbol_size*frame_parms->symbols_per_tti;
for (int idx=0;idx<10;idx++) printf("dumping raw subframe %d: txdataF[%d] = (%d,%d)\n", subframe, idx, ((short*)&txdataF[0][sf_offset+idx])[0], ((short*)&txdataF[0][sf_offset+idx])[1]); //for (int idx=0;idx<10;idx++) printf("dumping raw subframe %d: txdataF[%d] = (%d,%d)\n", subframe, idx, ((short*)&txdataF[0][sf_offset+idx])[0], ((short*)&txdataF[0][sf_offset+idx])[1]);
tx_pwr = dac_fixed_gain(s_re_f, tx_pwr = dac_fixed_gain(s_re_f,
...@@ -550,7 +550,7 @@ void do_DL_sig_freq(channel_desc_t *eNB2UE[NUMBER_OF_eNB_MAX][NUMBER_OF_UE_MAX][ ...@@ -550,7 +550,7 @@ void do_DL_sig_freq(channel_desc_t *eNB2UE[NUMBER_OF_eNB_MAX][NUMBER_OF_UE_MAX][
//} //}
write_output("txsigFrame.m","txsF", PHY_vars_eNB_g[eNB_id][CC_id]->common_vars.txdataF[0][0],10*frame_parms->ofdm_symbol_size*frame_parms->symbols_per_tti,1,16); write_output("txsigFrame.m","txsF", PHY_vars_eNB_g[eNB_id][CC_id]->common_vars.txdataF[0][0],10*frame_parms->ofdm_symbol_size*frame_parms->symbols_per_tti,1,16);
for (int idx=0;idx<10;idx++) printf("dumping raw tx subframe (input) %d: s_f[%d] = (%f,%f)\n", subframe, idx, s_re_f[0][idx],s_im_f[0][idx]); //for (int idx=0;idx<10;idx++) printf("dumping raw tx subframe (input) %d: s_f[%d] = (%f,%f)\n", subframe, idx, s_re_f[0][idx],s_im_f[0][idx]);
#ifdef DEBUG_SIM #ifdef DEBUG_SIM
LOG_D(OCM,"[SIM][DL] eNB %d (CCid %d): tx_pwr %.1f dBm/RE (target %d dBm/RE), for subframe %d\n", LOG_D(OCM,"[SIM][DL] eNB %d (CCid %d): tx_pwr %.1f dBm/RE (target %d dBm/RE), for subframe %d\n",
......
...@@ -1100,12 +1100,11 @@ int eNB_trx_read(openair0_device *device, openair0_timestamp *ptimestamp, void * ...@@ -1100,12 +1100,11 @@ int eNB_trx_read(openair0_device *device, openair0_timestamp *ptimestamp, void *
(unsigned long long)current_eNB_rx_timestamp[eNB_id][CC_id]); (unsigned long long)current_eNB_rx_timestamp[eNB_id][CC_id]);
printf("is Prach generated? %d, is prach_subframe? %d, frame %d, subframe %d, mode %d, n_ra_prb %d\n",PHY_vars_UE_g[0][CC_id]->generate_prach,is_prach_subframe(frame_parms,frame,subframe),frame,subframe,PHY_vars_UE_g[0][CC_id]->UE_mode[eNB_id], 11111); printf("is Prach generated? %d, is prach_subframe? %d, frame %d, subframe %d, mode %d, n_ra_prb %d\n",PHY_vars_UE_g[0][CC_id]->generate_prach,is_prach_subframe(frame_parms,frame,subframe),frame,subframe,PHY_vars_UE_g[0][CC_id]->UE_mode[eNB_id], 11111);
if (do_ofdm_mod) if (do_ofdm_mod)
{ {
write_output("txprachF.m","prach_txF", PHY_vars_UE_g[0][0]->prach_vars[0]->prachF,frame_parms->ofdm_symbol_size*frame_parms->symbols_per_tti,1,1); if (is_prach_subframe(frame_parms,frame,subframe) && PHY_vars_UE_g[0][CC_id]->generate_prach)
//generate_prach(PHY_vars_UE_g[0][0],eNB_id,subframe,frame); {
//PHY_vars_UE_g[0][0]->generate_prach=1;
if (is_prach_subframe(frame_parms,frame,subframe))
do_UL_prach(UE2eNB, do_UL_prach(UE2eNB,
enb_data, enb_data,
ue_data, ue_data,
...@@ -1115,6 +1114,10 @@ int eNB_trx_read(openair0_device *device, openair0_timestamp *ptimestamp, void * ...@@ -1115,6 +1114,10 @@ int eNB_trx_read(openair0_device *device, openair0_timestamp *ptimestamp, void *
0, // frame is only used for abstraction 0, // frame is only used for abstraction
eNB_id, eNB_id,
CC_id); CC_id);
write_output("txprachF.m","prach_txF", PHY_vars_UE_g[0][0]->prach_vars[0]->prachF,frame_parms->ofdm_symbol_size*frame_parms->symbols_per_tti,1,1);
//generate_prach(PHY_vars_UE_g[0][0],eNB_id,subframe,frame);
//PHY_vars_UE_g[0][0]->generate_prach=1;
}
do_UL_sig_freq(UE2eNB, do_UL_sig_freq(UE2eNB,
enb_data, enb_data,
......
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