mirror of https://github.com/PentHertz/srsLTE.git
Restart rx_stream on radio error
This commit is contained in:
parent
91664ef2be
commit
ed52604d30
|
@ -87,11 +87,8 @@ void radio::stop()
|
|||
void radio::reset()
|
||||
{
|
||||
printf("Resetting Radio...\n");
|
||||
srslte_rf_close(&rf_device);
|
||||
sleep(3);
|
||||
if (srslte_rf_open_devname(&rf_device, saved_devname, saved_args, saved_nof_channels)) {
|
||||
fprintf(stderr, "Error opening RF device\n");
|
||||
}
|
||||
srslte_rf_stop_rx_stream(&rf_device);
|
||||
radio_is_streaming = false;
|
||||
}
|
||||
|
||||
void radio::set_manual_calibration(rf_cal_t* calibration)
|
||||
|
|
|
@ -143,16 +143,10 @@ void phch_recv::reset()
|
|||
void phch_recv::radio_error()
|
||||
{
|
||||
log_h->error("SYNC: Receiving from radio.\n");
|
||||
phy_state = IDLE;
|
||||
|
||||
// Need to find a method to effectively reset radio, reloading the driver does not work
|
||||
//radio_h->reset();
|
||||
radio_h->stop();
|
||||
|
||||
fprintf(stdout, "Error while receiving samples. Restart srsUE\n");
|
||||
exit(-1);
|
||||
|
||||
phy_state = CELL_SEARCH;
|
||||
reset();
|
||||
// Need to find a method to effectively reset radio, reloading the driver does not work
|
||||
radio_h->reset();
|
||||
}
|
||||
|
||||
void phch_recv::set_cfo(float cfo) {
|
||||
|
|
Loading…
Reference in New Issue