Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UE <-> gNB connection crashes after ping #343

Closed
oliverxsch opened this issue Nov 28, 2023 · 15 comments
Closed

UE <-> gNB connection crashes after ping #343

oliverxsch opened this issue Nov 28, 2023 · 15 comments

Comments

@oliverxsch
Copy link

Issue Description

The connection between the UE and gNB crashes after an while.

Setup Details

I already opened another issue #315
But I closed it because most of the time im now having a different problem.
Im using an over the air setup.

First PC:
Specs: i9 13900, 64GB Ram
OS: Ubuntu 22.04.03 LTS
UHD 3.15 LTS
Newest srsRAN Project and newest Open5Gs.
Connected via a 10G-Link to a USRP X310
"gNB"

Second PC:
Specs: i9 13900, 64GB Ram
OS: Ubuntu 22.04.03 LTS
UHD 3.15 LTS
Newest srsRAN-4G Project.
Connected via a 10G-Link to another USRP X310
"UE"

Both USRPs are connected to an CDA 2990 G for their sync and clock. I have the same problem with and without an additional active GPS Antenna.

Both USRPs are connected via antennas.
I also tried cables with 6db attenuators (with different gain values). Same issue.

Sometimes the connection is very long intact but as soon as i ping the UE from the gNB or the other way around the connection crashes.
Sometimes im able to ping but after about 20-40 seconds the connection also crashes.
Sometimes the connection does not even build up (see #315)
I tried different gain-values on both sides, different cables, computers, USRPs etc.
Sometimes i can see: [PHY-SA ] [E] [ 5030] SYNC: detected out-of-sync... skipping slot ... in the UE log
Sometimes i can see:[DU-MNG ] [I] ue=0: RLF detected. Timer of 31000 msec to release UE started... in the gNB log.

I have no idea, what i am supposed to try now, also which error i am getting or weither or not the UE connects at all seems to be random. Because if i don't change any configuration at all im still getting different errors from time to time.

Configuration and Logs (for the case when the UE actually connects, but releases the connection after a ping)
UE_and_GNB_Logs_and_Confs.zip

Thanks in advance for your help.

@oliverxsch
Copy link
Author

Just as a side note, the configuration has to be correct, because with 2 B200 following this tutorial: https://docs.srsran.com/projects/project/en/latest/tutorials/source/srsUE/source/index.html its working.

@pgawlowicz
Copy link
Collaborator

Could you try with the following parameters in the ru_sdr section:

  device_driver: uhd
  device_args: type=x300,addr=192.168.43.2,master_clock_rate=184.32e6,send_frame_size=8000,recv_frame_size=8000   
  clock: external
  sync: external                                                 
  srate: 15.36

Then for UE please change/add:

...
srate = 15.36e6
...
device_args = type=x300,addr=x.x.x.x,master_clock_rate=184.32e6,send_frame_size=8000,recv_frame_size=8000,clock=external,sync=external
...
[expert]
lte_sample_rates = true

Please run this script on both PCs: srsran_performance

@oliverxsch
Copy link
Author

Thank you so much, finally it works. Maybe add this tip to the tutorial on the website?

Could you try with the following parameters in the ru_sdr section:

  device_driver: uhd
  device_args: type=x300,addr=192.168.43.2,master_clock_rate=184.32e6,send_frame_size=8000,recv_frame_size=8000   
  clock: external
  sync: external                                                 
  srate: 15.36

Then for UE please change/add:

...
srate = 15.36e6
...
device_args = type=x300,addr=x.x.x.x,master_clock_rate=184.32e6,send_frame_size=8000,recv_frame_size=8000,clock=external,sync=external
...
[expert]
lte_sample_rates = true

Please run this script on both PCs: srsran_performance

@Rinelli96
Copy link

Rinelli96 commented Jan 24, 2024

Hi @pgawlowicz, we have exactly the same problem. Do you have any tips for us?

Our configuration consist of two URSP B210 connected via cables without attenuators. Their are synchonized with the same 10MHz external clock. The UE and GNB software run on Ubuntu 22.04.3 LTS.
The configuration files of GNB and UE respectively are attached

Thanks in advance!!

Config Files.zip

@pgawlowicz
Copy link
Collaborator

@Rinelli96 Does your configs work over zmq? Please check to be sure there are no non-RF related issues.

Then, could you check setting time_adv_nsamples=600 in the srsUE config when running with USRPs?

Finally, I would recommend adding some attenuators (10-30dB) to the setup and tune TX/RX gains for both gnb and ue.

@Rinelli96
Copy link

Thanks for your reply @pgawlowicz,

  1. we are checking the connection through ZMQ using the repo config files with the modification suggested in the doumentation guide. The GNB seems to work correctly, while the UE, when started, give us the following error:

Active RF plugins: libsrsran_rf_uhd.so libsrsran_rf_blade.so libsrsran_rf_zmq.so
Inactive RF plugins:
Reading configuration file /home/rinelli/Documents/Config_files/5G_Config/ue_zmq.conf...

Built in Release mode using commit eea87b1d8 on branch master.

Opening 1 channels in RF device=zmq with args=tx_port=tcp://127.0.0.1:2001,rx_port=tcp://127.0.0.1:2000,base_srate=11.52e6
Supported RF device list: UHD bladeRF zmq file
CHx base_srate=11.52e6
Current sample rate is 1.92 MHz with a base rate of 11.52 MHz (x6 decimation)
CH0 rx_port=tcp://127.0.0.1:2000
CH0 tx_port=tcp://127.0.0.1:2001
Error: couldn't update sample rate. 23.04 is not divisible by 11.52
Current sample rate is 1.92 MHz with a base rate of 11.52 MHz (x6 decimation)

  1. Concerning the time_adv_nsamples, I think it is in some sense related to the delay on the communication channel. Can you provide me other informations about it (e.g. How it is related to the delay? Why it is set to 300 in the default configuration?, ...) ?.

  2. What do you mean for TX/RX gain tuning? The problem can be caused by our higher gains?

  3. Just another question, Why you suggest to Oliver to set the "lte_sample_rates = true" in the UE config file and the "base_srate = 15.36" in both UE and GNB. We suppose that the srate issue have been fixed with the latest release ( base_srate = 23.04) do you confirm it ?
    Thank you for the support!!

@pgawlowicz
Copy link
Collaborator

  1. You need to change the base_rate the zmq args in the rf section of both gnb and srsue, it should be base_srate=23.04e6. The best would be to use the configs provided in our gnb+srsUE tutorial

  2. See this comment for explanation. The value of 300 [samples] was set for 10MHz bandwidth (with srate=11.52e6), since now you want to use 20MHz (srate=23.04e6), i believe it should be 2x to keep the same delay in terms of time.

  3. if the signal power received by USRP is too high, the signal might be distorted (e.g. due to clipping effect), hence SNR goes down. You need to find the correct TX/RX gains for both gnb and srsUE that maximize the SNR.

  4. the lte_sample_rates = true is only for srsUE when running with USRP x300/x310 and N-series.

@Rinelli96
Copy link

  1. I have already set the correct base_srate in the configurations:
    Config.Files.zip.

  2. Okay, thanks. I will try it!

  3. So, do I need to check the SNR in the log file? Then, do I have to modify the TX/RX Gain for both GNB and UE to maximize the SNR. Is that correct?

  4. OK

Thank you for your patience and support!

@pgawlowicz
Copy link
Collaborator

  1. does it work with zmq? note that you have device_driver: zmq and it should be device_driver=zmq same for args
  2. just type t in both srsUE and gnb an see the SNR (under pusch and pdsch)

@Rinelli96
Copy link

  1. Note that the GNB Configuration file is a .yaml file format, while UE conf is a .conf file. I downloaded them directly from the Tutorial.

@pgawlowicz
Copy link
Collaborator

i know, but you use : in srsue conf.

@Rinelli96
Copy link

Yes! I included the wrong line in the zip folder. However, thank you for the support!!
Regarding the Over-the-Air Setup, I have fixed the issue, and fine-tuning the parameters has solved the problem of connection instability. I aim to continue parameter tuning to maximize the pusch of the GNB and the snr in the UE, making the connection as reliable as possible.

@pgawlowicz
Copy link
Collaborator

@Rinelli96 could you share the successful configs here?

@Rinelli96
Copy link

Hi @pgawlowicz, here the configuration files working for us.
config.zip

@pgawlowicz
Copy link
Collaborator

@Rinelli96 Great, thank you for your feedback!
I see the configuration is the standard one, except the tx/rx gains tuning for both gnb/srsUE.

Can you confirm that you get a stable connection and the srsUE, you can run ping/iperf and the srsUE keeps the connection (i.e., does not send a PRACH after a few seconds?)

Could you also print the console output on both gnb and srsUE (typing t after they start) and check the SNR levels for pdsch and pusch ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants