Radio stops Rx stream prior to stop and benchmark prompts RF metrics

master
Xavier Arteaga 4 years ago committed by Xavier Arteaga
parent de0501cc55
commit eb5210dbda

@ -241,6 +241,12 @@ bool radio::is_init()
void radio::stop()
{
// Stop Rx streams as soon as possible to avoid Overflows
if (radio_is_streaming) {
for (srslte_rf_t& rf_device : rf_devices) {
srslte_rf_stop_rx_stream(&rf_device);
}
}
if (zeros) {
free(zeros);
zeros = NULL;

@ -281,6 +281,7 @@ int main(int argc, char** argv)
srslte_dft_plan_t dft_plan = {}, idft_plan = {};
srslte_agc_t agc[SRSLTE_MAX_RADIOS] = {};
phy_dummy phy;
srslte::rf_metrics_t rf_metrics = {};
rf_buffer_t rf_buffers[SRSLTE_MAX_RADIOS] = {};
@ -523,7 +524,13 @@ int main(int argc, char** argv)
nof_samples -= frame_size;
}
printf("Finished streaming with %d gaps...\n", nof_gaps);
radio_h[0]->get_metrics(&rf_metrics);
printf("Finished streaming with %d gaps, %d late timestamps, %d overflows, %d underflow...\n",
nof_gaps,
rf_metrics.rf_l,
rf_metrics.rf_o,
rf_metrics.rf_u);
ret = SRSLTE_SUCCESS;

Loading…
Cancel
Save