eCPRI fronthaul "flushing" prior to streaming. TX path still not included
This commit is contained in:
@@ -111,18 +111,18 @@ void send_IF5(RU_t *ru, openair0_timestamp proc_timestamp, int subframe, uint8_t
|
||||
|
||||
for (packet_id=0; packet_id < spsf / spp_eth; packet_id++) {
|
||||
for (int aid=0; aid<ru->nb_tx;aid++) {
|
||||
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME( VCD_SIGNAL_DUMPER_VARIABLES_SEND_IF5_PKT_ID, packet_id );
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_WRITE_IF0, 1 );
|
||||
//VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME( VCD_SIGNAL_DUMPER_VARIABLES_SEND_IF5_PKT_ID, packet_id );
|
||||
//VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_WRITE_IF0, 1 );
|
||||
clock_gettime( CLOCK_MONOTONIC, &start_comp);
|
||||
ru->ifdevice.trx_write_func2(&ru->ifdevice,
|
||||
/* ru->ifdevice.trx_write_func2(&ru->ifdevice,
|
||||
(proc_timestamp + packet_id*spp_eth),
|
||||
(void*)txp[aid],
|
||||
spp_eth,
|
||||
aid,
|
||||
0);
|
||||
0); */
|
||||
clock_gettime( CLOCK_MONOTONIC, &end_comp);
|
||||
LOG_D(HW,"[SF %d] IF_Write_Time: %"PRId64"\n",subframe,clock_difftime_ns(start_comp, end_comp));
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_WRITE_IF0, 0 );
|
||||
//VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_WRITE_IF0, 0 );
|
||||
for (i=0; i < fp->nb_antennas_tx; i++)
|
||||
txp[i] += spp_eth;
|
||||
|
||||
@@ -137,8 +137,8 @@ void send_IF5(RU_t *ru, openair0_timestamp proc_timestamp, int subframe, uint8_t
|
||||
data_block = (uint16_t*)(alaw_buffer + APP_HEADER_SIZE_BYTES);
|
||||
}
|
||||
for (packet_id=0; packet_id < spsf / spp_eth; packet_id++) {
|
||||
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME( VCD_SIGNAL_DUMPER_VARIABLES_SEND_IF5_PKT_ID, packet_id );
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_COMPR_IF, 1 );
|
||||
//VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME( VCD_SIGNAL_DUMPER_VARIABLES_SEND_IF5_PKT_ID, packet_id );
|
||||
//VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_COMPR_IF, 1 );
|
||||
clock_gettime( CLOCK_MONOTONIC, &start_comp);
|
||||
for (i=0; i < fp->nb_antennas_rx; i++) {
|
||||
for (element_id=0; element_id< spp_eth; element_id++){
|
||||
@@ -148,8 +148,8 @@ void send_IF5(RU_t *ru, openair0_timestamp proc_timestamp, int subframe, uint8_t
|
||||
}
|
||||
clock_gettime( CLOCK_MONOTONIC, &end_comp);
|
||||
LOG_D(HW,"[SF %d] Compress_Time: %"PRId64"\n",subframe,clock_difftime_ns(start_comp, end_comp));
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_COMPR_IF, 0 );
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_WRITE_IF0, 1 );
|
||||
//VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_COMPR_IF, 0 );
|
||||
//VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_WRITE_IF0, 1 );
|
||||
clock_gettime( CLOCK_MONOTONIC, &start_comp);
|
||||
ru->ifdevice.trx_write_func(&ru->ifdevice,
|
||||
(proc_timestamp + packet_id*spp_eth),
|
||||
@@ -379,8 +379,8 @@ void recv_IF5(RU_t *ru, openair0_timestamp *proc_timestamp, int subframe, uint16
|
||||
txp[i] = (void*)&ru->common.txdata[i][subframe*fp->samples_per_tti];
|
||||
|
||||
for (packet_id=0; packet_id < spsf / spp_eth; packet_id++) {
|
||||
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME( VCD_SIGNAL_DUMPER_VARIABLES_RECV_IF5_PKT_ID, packet_id );
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_READ_IF0, 1 );
|
||||
//VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME( VCD_SIGNAL_DUMPER_VARIABLES_RECV_IF5_PKT_ID, packet_id );
|
||||
//VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_READ_IF0, 1 );
|
||||
clock_gettime( CLOCK_MONOTONIC, &start_decomp);
|
||||
ru->ifdevice.trx_read_func(&ru->ifdevice,
|
||||
×tamp[packet_id],
|
||||
@@ -389,7 +389,7 @@ void recv_IF5(RU_t *ru, openair0_timestamp *proc_timestamp, int subframe, uint16
|
||||
fp->nb_antennas_tx);
|
||||
clock_gettime( CLOCK_MONOTONIC, &end_decomp);
|
||||
LOG_D(HW,"[SF %d] IF_Read_Time: %"PRId64"\n",subframe,clock_difftime_ns(start_decomp, end_decomp));
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_READ_IF0, 0 );
|
||||
//VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_READ_IF0, 0 );
|
||||
for (i=0; i < fp->nb_antennas_tx; i++)
|
||||
txp[i] += spp_eth;
|
||||
|
||||
@@ -435,202 +435,48 @@ void recv_IF5(RU_t *ru, openair0_timestamp *proc_timestamp, int subframe, uint16
|
||||
} else if (eth->compression == NO_COMPRESS) {
|
||||
int16_t temp_rx[spp_eth*2];
|
||||
for (i=0; i < ru->nb_rx; i++)
|
||||
rxp[i] = (void*)&ru->common.rxdata[i][subframe*fp->samples_per_tti];
|
||||
int aid;
|
||||
rxp[i] = &ru->common.rxdata[i][subframe*fp->samples_per_tti];
|
||||
int aid;
|
||||
int firstTS=1;
|
||||
openair0_timestamp oldTS;
|
||||
|
||||
for (packet_id=0; packet_id < ru->nb_rx*spsf / spp_eth; packet_id++) {
|
||||
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME( VCD_SIGNAL_DUMPER_VARIABLES_SEND_IF5_PKT_ID, packet_id );
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_READ_IF0, 1 );
|
||||
//VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME( VCD_SIGNAL_DUMPER_VARIABLES_SEND_IF5_PKT_ID, packet_id );
|
||||
//VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_READ_IF0, 1 );
|
||||
clock_gettime( CLOCK_MONOTONIC, &start_decomp);
|
||||
ru->ifdevice.trx_read_func2(&ru->ifdevice,
|
||||
×tamp[packet_id],
|
||||
(void*)temp_rx,
|
||||
spp_eth,
|
||||
&aid);
|
||||
//LOG_I(PHY,"Received packet %d: aid %d, TS %lld\n",packet_id,aid,(unsigned long long)timestamp[packet_id]);
|
||||
if (aid==0) {
|
||||
if (firstTS==1) firstTS=0;
|
||||
else if (oldTS + 256 != timestamp[packet_id]) {
|
||||
LOG_I(PHY,"oldTS %llu, newTS %llu, diff %llu\n",oldTS,timestamp[packet_id],timestamp[packet_id]-oldTS);
|
||||
for (int i=0;i<=packet_id;i++) LOG_I(PHY,"packet %d TS %llu\n",i,timestamp[i]);
|
||||
AssertFatal(1==0,"fronthaul problem\n");
|
||||
}
|
||||
|
||||
oldTS = timestamp[packet_id];
|
||||
}
|
||||
|
||||
|
||||
// HYPOTHESIS: first packet per subframe has lowest timestamp of subframe
|
||||
// should detect out of order and act accordingly ....
|
||||
|
||||
memcpy(rxp[aid]+((timestamp[packet_id]-timestamp[0])<<2),
|
||||
AssertFatal(aid==0 || aid==1,"aid %d != 0 or 1\n",aid);
|
||||
//LOG_I(PHY,"rxp[%d] %p, dest %p, offset %d (%lld,%lld)\n",aid,rxp[aid],rxp[aid]+(timestamp[packet_id]-timestamp[0]),(timestamp[packet_id]-timestamp[0]),timestamp[packet_id],timestamp[0]);
|
||||
memcpy((void*)(rxp[aid]+(timestamp[packet_id]-timestamp[0])),
|
||||
(void*)temp_rx,
|
||||
spp_eth);
|
||||
spp_eth<<2);
|
||||
clock_gettime( CLOCK_MONOTONIC, &end_decomp);
|
||||
LOG_D(HW,"[SF %d] IF_Read_Time: %"PRId64"\n",subframe,clock_difftime_ns(start_decomp, end_decomp));
|
||||
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_READ_IF0, 0 );
|
||||
for (i=0; i < fp->nb_antennas_rx; i++)
|
||||
rxp[i] += spp_eth;
|
||||
//VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME( VCD_SIGNAL_DUMPER_FUNCTIONS_TRX_READ_IF0, 0 );
|
||||
|
||||
}
|
||||
}
|
||||
*proc_timestamp = timestamp[0];
|
||||
|
||||
} else if (packet_type == IF5_MOBIPASS) {
|
||||
if (ru->if_timing == synch_to_mobipass_standalone) {
|
||||
uint16_t db_fulllength = PAYLOAD_MOBIPASS_NUM_SAMPLES;
|
||||
openair0_timestamp timestamp_mobipass[fp->samples_per_tti/db_fulllength];
|
||||
int32_t *rx_buffer=NULL;
|
||||
__m128i *data_block=NULL, *data_block_head=NULL;
|
||||
__m128i *rxp128;
|
||||
__m128i r0;
|
||||
|
||||
unsigned char _rx_buffer[MAC_HEADER_SIZE_BYTES + sizeof_IF5_mobipass_header_t + db_fulllength*sizeof(int16_t)];
|
||||
rx_buffer = (int32_t *)_rx_buffer;
|
||||
data_block_head = (__m128i *)((uint8_t *)rx_buffer + MAC_HEADER_SIZE_BYTES + sizeof_IF5_mobipass_header_t);
|
||||
|
||||
rxp[0] = (void*)&ru->common.rxdata[0][subframe*ru->frame_parms.samples_per_tti];
|
||||
rxp128 = (__m128i *) (rxp[0]);
|
||||
|
||||
packet_id=0;
|
||||
while(packet_id<fp->samples_per_tti/db_fulllength) {
|
||||
data_block = data_block_head;
|
||||
|
||||
ru->ifdevice.trx_read_func(&ru->ifdevice,
|
||||
×tamp_mobipass[packet_id],
|
||||
(void**)&rx_buffer,
|
||||
db_fulllength,
|
||||
1
|
||||
);
|
||||
|
||||
//store rxdata and increase packet_id
|
||||
rxp[0] = (void*)&ru->common.rxdata[0][(subframe*ru->frame_parms.samples_per_tti)+packet_id*db_fulllength];
|
||||
rxp128 = (__m128i *) (rxp[0]);
|
||||
for (i=0; i<db_fulllength>>2; i+=2) {
|
||||
r0 = _mm_loadu_si128(data_block++);
|
||||
*rxp128++ =_mm_slli_epi16(_mm_srai_epi16(_mm_unpacklo_epi8(r0,r0),8),4);
|
||||
*rxp128++ =_mm_slli_epi16(_mm_srai_epi16(_mm_unpackhi_epi8(r0,r0),8),4);
|
||||
}
|
||||
packet_id++;
|
||||
}//end while
|
||||
|
||||
*proc_timestamp = ntohl(timestamp_mobipass[0]);
|
||||
} else {
|
||||
|
||||
uint16_t db_fulllength = PAYLOAD_MOBIPASS_NUM_SAMPLES;
|
||||
openair0_timestamp timestamp_mobipass[fp->samples_per_tti/db_fulllength];
|
||||
#ifdef DEBUG_UL_MOBIPASS
|
||||
int lower_offset = 0;
|
||||
int upper_offset = 70000;
|
||||
#endif
|
||||
int subframe_skip = 0;
|
||||
int reset_flag = 0;
|
||||
int32_t *rx_buffer=NULL;
|
||||
__m128i *data_block=NULL, *data_block_head=NULL;
|
||||
__m128i *rxp128;
|
||||
__m128i r0;
|
||||
|
||||
//rx_buffer = memalign(16, MAC_HEADER_SIZE_BYTES + sizeof_IF5_mobipass_header_t + db_fulllength*sizeof(int16_t));
|
||||
rx_buffer = malloc(MAC_HEADER_SIZE_BYTES + sizeof_IF5_mobipass_header_t + db_fulllength*sizeof(int16_t));
|
||||
IF5_mobipass_header_t *header = (IF5_mobipass_header_t *)((uint8_t *)rx_buffer + MAC_HEADER_SIZE_BYTES);
|
||||
data_block_head = (__m128i *)((uint8_t *)rx_buffer + MAC_HEADER_SIZE_BYTES + sizeof_IF5_mobipass_header_t);
|
||||
|
||||
rxp[0] = (void*)&ru->common.rxdata[0][subframe*ru->frame_parms.samples_per_tti];
|
||||
rxp128 = (__m128i *) (rxp[0]);
|
||||
|
||||
RU_proc_t *proc = &ru->proc;
|
||||
/*
|
||||
// while(packet_id<fp->samples_per_tti/db_fulllength) {
|
||||
data_block = data_block_head;
|
||||
|
||||
eNB->ifdevice.trx_read_func(&eNB->ifdevice,
|
||||
&ts0,
|
||||
(void**)&rx_buffer,
|
||||
db_fulllength,
|
||||
1
|
||||
);
|
||||
|
||||
if ((header->seqno == 1)&&(first_packet==1)) {
|
||||
first_packet = 0; //ignore the packets before synchnorization
|
||||
packet_id = 0;
|
||||
ts_offset = ntohl(ts0);
|
||||
}
|
||||
if (first_packet==0) {
|
||||
packet_cnt++;
|
||||
ts = ntohl(ts0);
|
||||
packet_id = (ts-ts_offset)/db_fulllength;
|
||||
packet_id = packet_id % (fp->samples_per_tti/db_fulllength);
|
||||
|
||||
printf("[IF5_tools]packet_id:%d\n", packet_id);
|
||||
// if (ts_stored == 0) {
|
||||
// ts_stored = 1;
|
||||
*proc_timestamp = ntohl(ts - (packet_id*db_fulllength));
|
||||
// }
|
||||
rxp[0] = (void*)&eNB->common_vars.rxdata[0][0][(subframe*eNB->frame_parms.samples_per_tti)+packet_id*db_fulllength];
|
||||
rxp128 = (__m128i *) (rxp[0]);
|
||||
|
||||
for (i=0; i<db_fulllength>>2; i+=2) {
|
||||
r0 = _mm_loadu_si128(data_block++);
|
||||
*rxp128++ =_mm_slli_epi16(_mm_srai_epi16(_mm_unpacklo_epi8(r0,r0),8),4);
|
||||
*rxp128++ =_mm_slli_epi16(_mm_srai_epi16(_mm_unpackhi_epi8(r0,r0),8),4);
|
||||
}
|
||||
}
|
||||
// }//end while
|
||||
*/
|
||||
|
||||
|
||||
packet_id=0;
|
||||
while(packet_id<fp->samples_per_tti/db_fulllength) {
|
||||
data_block = data_block_head;
|
||||
|
||||
|
||||
ru->ifdevice.trx_read_func(&ru->ifdevice,
|
||||
×tamp_mobipass[packet_id],
|
||||
(void**)&rx_buffer,
|
||||
db_fulllength,
|
||||
1
|
||||
);
|
||||
#ifdef DEBUG_UL_MOBIPASS
|
||||
if (((proc->timestamp_tx + lower_offset) > ntohl(timestamp_mobipass[packet_id])) || ((proc->timestamp_tx + upper_offset) < ntohl(timestamp_mobipass[packet_id]))) {
|
||||
//ignore the packet
|
||||
subframe_skip_extra = (subframe_skip_extra + 1)%67;
|
||||
LOG_D("[Mobipass] ignored packet, id:[%d,%d], proc->timestamp_tx:%llu, proc->timestamp_rx:%llu, seqno:%d\n", packet_id,subframe_skip_extra, proc->timestamp_tx, ntohl(timestamp_mobipass[packet_id]), header->seqno);
|
||||
}
|
||||
#endif
|
||||
//skip SUBFRAME_SKIP_NUM_MOBIPASS additional UL packets
|
||||
if ((start_flag == 1) && (subframe_skip < SUBFRAME_SKIP_NUM_MOBIPASS)){
|
||||
subframe_skip++;
|
||||
offset_cnt = header->seqno;
|
||||
} else {
|
||||
if ((offset_cnt != header->seqno) && (start_flag == 0) && (proc->first_rx > 3)){
|
||||
#ifdef DEBUG_UL_MOBIPASS
|
||||
LOG_D(PHY,"[Mobipass] Reset sequence number, offset_cnt:%d, header->seqno:%d, packet_id:%d\n", offset_cnt, header->seqno, packet_id);
|
||||
#endif
|
||||
reset_flag=1;
|
||||
}
|
||||
if ((reset_flag == 1) && (proc->first_rx > 3 ) && (start_flag == 0) && (packet_id == 0)) {
|
||||
packet_id = 1;
|
||||
reset_flag = 0;
|
||||
}
|
||||
start_flag = 0;
|
||||
|
||||
//store rxdata and increase packet_id
|
||||
rxp[0] = (void*)&ru->common.rxdata[0][(subframe*ru->frame_parms.samples_per_tti)+packet_id*db_fulllength];
|
||||
rxp128 = (__m128i *) (rxp[0]);
|
||||
for (i=0; i<db_fulllength>>2; i+=2) {
|
||||
r0 = _mm_loadu_si128(data_block++);
|
||||
*rxp128++ =_mm_slli_epi16(_mm_srai_epi16(_mm_unpacklo_epi8(r0,r0),8),4);
|
||||
*rxp128++ =_mm_slli_epi16(_mm_srai_epi16(_mm_unpackhi_epi8(r0,r0),8),4);
|
||||
}
|
||||
packet_id++;
|
||||
offset_cnt = (header->seqno+1)&255;
|
||||
}
|
||||
}//end while
|
||||
|
||||
*proc_timestamp = ntohl(timestamp_mobipass[0]);
|
||||
#ifdef DEBUG_UL_MOBIPASS
|
||||
LOG_I(PHY,"[Mobipass][Recv_MOBIPASS] timestamp: %llu\n ", *proc_timestamp);
|
||||
if (eNB->CC_id>0) {
|
||||
rxe = dB_fixed(signal_energy(rxp[0],fp->samples_per_tti));
|
||||
if (rxe > 0){
|
||||
LOG_I(PHY,"[Mobipass] frame:%d, subframe:%d, energy %d\n", (*proc_timestamp/(10*fp->samples_per_tti))&1023,subframe, rxe);
|
||||
|
||||
// LOG_M("rxsigmb.m","rxs",(void*)dummy_buffer_rx, fp->samples_per_tti,1, 5);
|
||||
// exit(-1);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
free(rx_buffer);
|
||||
|
||||
|
||||
}
|
||||
} else {
|
||||
AssertFatal(1==0, "recv_IF5 - Unknown packet_type %x", packet_type);
|
||||
}
|
||||
|
||||
@@ -432,6 +432,12 @@ struct openair0_device_t {
|
||||
\param device the hardware configuration to use
|
||||
*/
|
||||
int (*thirdparty_cleanup)(openair0_device *device);
|
||||
|
||||
/*! \brief Callback for Third-party start streaming routine
|
||||
\param device the hardware configuration to use
|
||||
*/
|
||||
int (*thirdparty_startstreaming)(openair0_device *device);
|
||||
|
||||
};
|
||||
|
||||
/* type of device init function, implemented in shared lib */
|
||||
|
||||
@@ -297,7 +297,7 @@ int trx_eth_write_udp(openair0_device *device, openair0_timestamp timestamp, voi
|
||||
// ECPRI PC_ID (2 bytes)
|
||||
*(uint16_t *)(buff2 + 4) = cc;
|
||||
// OAI modified SEQ_ID (4 bytes)
|
||||
*(uint64_t *)(buff2 + 6) = (uint64_t )timestamp;
|
||||
*(uint64_t *)(buff2 + 6) = ((uint64_t )timestamp)*3;
|
||||
|
||||
|
||||
int sent_byte;
|
||||
@@ -436,8 +436,8 @@ int trx_eth_read_udp(openair0_device *device, openair0_timestamp *timestamp, voi
|
||||
// handle 1.4,3,5,10,15 MHz cases
|
||||
*cc = *(uint16_t*)(buff2 + ECPRICOMMON_BYTES);
|
||||
}
|
||||
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME( VCD_SIGNAL_DUMPER_VARIABLES_RX_SEQ_NUM,eth->pck_seq_num_cur);
|
||||
VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME( VCD_SIGNAL_DUMPER_VARIABLES_RX_SEQ_NUM_PRV,eth->pck_seq_num_prev);
|
||||
//VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME( VCD_SIGNAL_DUMPER_VARIABLES_RX_SEQ_NUM,eth->pck_seq_num_cur);
|
||||
//VCD_SIGNAL_DUMPER_DUMP_VARIABLE_BY_NAME( VCD_SIGNAL_DUMPER_VARIABLES_RX_SEQ_NUM_PRV,eth->pck_seq_num_prev);
|
||||
eth->rx_actual_nsamps=bytes_received>>2;
|
||||
eth->rx_count++;
|
||||
}
|
||||
|
||||
@@ -178,10 +178,12 @@ void fh_if5_south_in(RU_t *ru,int *frame, int *subframe) {
|
||||
proc->frame_rx = (proc->timestamp_rx / (fp->samples_per_tti*10))&1023;
|
||||
proc->subframe_rx = (proc->timestamp_rx / fp->samples_per_tti)%10;
|
||||
|
||||
//LOG_I(PHY,"%d.%d (TS %llu) => %d.%d\n",*frame,*subframe,(unsigned long long)proc->timestamp_rx,proc->frame_rx,proc->subframe_rx);
|
||||
if (proc->first_rx == 0) {
|
||||
if (proc->subframe_rx != *subframe) {
|
||||
LOG_E(PHY,"Received Timestamp doesn't correspond to the time we think it is (proc->subframe_rx %d, subframe %d)\n",proc->subframe_rx,*subframe);
|
||||
exit_fun("Exiting");
|
||||
LOG_E(PHY,"Received Timestamp doesn't correspond to the time we think it is (proc->subframe_rx %d, subframe %d), resynching\n",proc->subframe_rx,*subframe);
|
||||
*frame=proc->frame_rx;
|
||||
*subframe=proc->subframe_rx;
|
||||
}
|
||||
|
||||
if (proc->frame_rx != *frame) {
|
||||
@@ -1650,7 +1652,7 @@ void *ru_thread( void *param ) {
|
||||
// Start RF device if any
|
||||
if (ru->start_rf) {
|
||||
if (ru->start_rf(ru) != 0)
|
||||
LOG_E(HW,"Could not start the RF device\n");
|
||||
AssertFatal(1==0,"Could not start the RF device\n");
|
||||
else LOG_I(PHY,"RU %d rf device ready\n",ru->idx);
|
||||
}
|
||||
else LOG_D(PHY,"RU %d no rf device\n",ru->idx);
|
||||
@@ -1814,7 +1816,6 @@ void *ru_thread( void *param ) {
|
||||
|
||||
if ((ru->fh_north_out) && (ru->state!=RU_CHECK_SYNC)) ru->fh_north_out(ru);
|
||||
}
|
||||
|
||||
proc->emulate_rf_busy = 0;
|
||||
}
|
||||
|
||||
@@ -2070,6 +2071,10 @@ static void *rf_tx( void *param ) {
|
||||
#endif
|
||||
|
||||
|
||||
int start_streaming(RU_t *ru) {
|
||||
LOG_I(PHY,"Starting streaming on third-party RRU\n");
|
||||
return(ru->ifdevice.thirdparty_startstreaming(&ru->ifdevice));
|
||||
}
|
||||
|
||||
int start_if(struct RU_t_s *ru,struct PHY_VARS_eNB_s *eNB) {
|
||||
return(ru->ifdevice.trx_start_func(&ru->ifdevice));
|
||||
@@ -2084,6 +2089,10 @@ int stop_rf(RU_t *ru) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
int start_steraming(RU_t *ru) {
|
||||
return(ru->ifdevice.thirdparty_startstreaming);
|
||||
}
|
||||
|
||||
extern void fep_full(RU_t *ru);
|
||||
extern void ru_fep_full_2thread(RU_t *ru);
|
||||
extern void feptx_ofdm(RU_t *ru);
|
||||
@@ -2547,8 +2556,7 @@ void set_function_spec_param(RU_t *ru) {
|
||||
ru->fh_south_out = fh_if5_south_out; // synchronous IF5 transmission
|
||||
ru->fh_south_asynch_in = NULL; // no asynchronous UL
|
||||
}
|
||||
|
||||
ru->start_rf = NULL; // no local RF
|
||||
ru->start_rf = ru->eth_params.transp_preference == ETH_UDP_IF5_ORI_MODE ? start_streaming : NULL; // no local RF
|
||||
ru->stop_rf = NULL;
|
||||
ru->start_if = start_if; // need to start if interface for IF5
|
||||
ru->ifdevice.host_type = RAU_HOST;
|
||||
|
||||
@@ -1,41 +1,67 @@
|
||||
[*]
|
||||
[*] GTKWave Analyzer v3.3.58 (w)1999-2014 BSI
|
||||
[*] Sun Jul 31 13:30:42 2016
|
||||
[*] GTKWave Analyzer v3.3.66 (w)1999-2015 BSI
|
||||
[*] Tue Sep 24 06:59:08 2019
|
||||
[*]
|
||||
[dumpfile] "/tmp/openair_dump_eNB.vcd"
|
||||
[dumpfile_mtime] "Sun Jul 31 13:21:59 2016"
|
||||
[dumpfile_size] 18273240
|
||||
[savefile] "/home/fourmi/openairinterface5g/targets/RT/USER/rcc_if5.gtkw"
|
||||
[timestart] 24070893000
|
||||
[size] 1301 716
|
||||
[pos] 309 0
|
||||
*-19.793451 29026062100 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
|
||||
[sst_width] 284
|
||||
[signals_width] 262
|
||||
[dumpfile_mtime] "Mon Sep 23 20:04:56 2019"
|
||||
[dumpfile_size] 1625759
|
||||
[savefile] "/home/orange/aw2s/openairinterface5g/targets/RT/USER/rcc_if5.gtkw"
|
||||
[timestart] 12600104000
|
||||
[size] 1215 1000
|
||||
[pos] 0 22
|
||||
*-19.506693 12600920638 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1
|
||||
[sst_width] 386
|
||||
[signals_width] 344
|
||||
[sst_expanded] 1
|
||||
[sst_vpaned_height] 294
|
||||
[sst_vpaned_height] 303
|
||||
@29
|
||||
functions.send_if5
|
||||
@28
|
||||
functions.recv_if5
|
||||
@24
|
||||
variables.trx_ts[63:0]
|
||||
variables.trx_tst[63:0]
|
||||
@28
|
||||
functions.send_if5
|
||||
functions.recv_if5
|
||||
functions.eNB_thread_rxtx0
|
||||
@24
|
||||
variables.frame_number_RX0_RU[63:0]
|
||||
variables.subframe_number_RX0_RU[63:0]
|
||||
variables.frame_number_TX0_RU[63:0]
|
||||
variables.subframe_number_TX0_RU[63:0]
|
||||
@28
|
||||
functions.mac_schedule_dlsch
|
||||
functions.macxface_eNB_dlsch_ulsch_scheduler
|
||||
functions.macxface_ue_scheduler
|
||||
functions.phy_eNB_ofdm_mod_l
|
||||
@24
|
||||
variables.frame_number_RX0_eNB[63:0]
|
||||
variables.subframe_number_RX0_eNB[63:0]
|
||||
variables.frame_number_TX0_eNB[63:0]
|
||||
variables.subframe_number_TX0_eNB[63:0]
|
||||
@28
|
||||
functions.eNB_thread_rxtx1
|
||||
@24
|
||||
variables.frame_number_RX1_eNB[63:0]
|
||||
variables.subframe_number_RX1_eNB[63:0]
|
||||
variables.frame_number_TX1_eNB[63:0]
|
||||
variables.subframe_number_TX1_eNB[63:0]
|
||||
@28
|
||||
functions.phy_eNB_dlsch_modulation
|
||||
functions.phy_eNB_dlsch_encoding
|
||||
functions.phy_eNB_dlsch_scrambling
|
||||
functions.phy_eNB_beam_precoding
|
||||
functions.phy_enb_pdcch_tx
|
||||
functions.phy_enb_prach_rx
|
||||
functions.phy_procedures_ru_feprx0
|
||||
functions.phy_procedures_eNb_rx_uespec0
|
||||
functions.phy_procedures_eNb_rx_uespec1
|
||||
functions.phy_enb_sfgen
|
||||
functions.phy_procedures_eNb_tx0
|
||||
functions.phy_procedures_eNb_tx1
|
||||
functions.phy_procedures_ru_feprx1
|
||||
functions.phy_procedures_ru_feptx_ofdm0
|
||||
functions.phy_procedures_ru_feptx_ofdm1
|
||||
functions.phy_procedures_ru_feptx_prec0
|
||||
functions.phy_procedures_ru_feptx_prec1
|
||||
functions.eNB_thread_rxtx1
|
||||
functions.phy_enb_sfgen
|
||||
functions.phy_eNB_slot_fep
|
||||
functions.phy_enb_prach_rx
|
||||
@24
|
||||
variables.dci_info[63:0]
|
||||
|
||||
Reference in New Issue
Block a user