srsran / srsRAN_4G

Open source SDR 4G software suite from Software Radio Systems (SRS) https://docs.srsran.com/projects/4g
https://www.srsran.com
GNU Affero General Public License v3.0
3.48k stars 1.14k forks source link

Correspondence between "tx_gain" in ue.conf and "set gain" in bladeRF #697

Closed ghost closed 3 years ago

ghost commented 3 years ago

Issue Description

There are no description in ue.conf about Correspondence between "tx_gain" in ue.conf and "set gain" in bladeRF.

In case of bladeRFxA4, the range of tx gain is [-23.75 ~ 66]. And in case of bladeRFX40, it is [17 ~ 73].

Does the value of "tx_gain" in ue.conf correspond to the gain setting of bladeRF , or not ?

Setup Details

[ue]

Ubunt18.04LTS bladeRFxA4 BladeRF-cli = 1.8.0 BladeRF-lib = 2.4.0 BladeRF-fw = 2.4.0 BladeRF-fpga= 0.12.0 srsLTE_20_10_1

[enb,epc]

Ubunt18.04LTS USRPb210 srsLTE_20_10_1

Expected Behavior

Actual Behaviour

Bellow is the tx spectrum of ue (bladeRFxA4). In ue.conf , tx_gain is set to 100,120,80,60,140,300. In case of tx=60 is Green Spectrum. In case of tx=100,120,80,60,140,300, these spectrums are almost the same power, so it seems that the max value of tx_gain is 80. However, power of these spectrums seem to be extremely lower than that of bladeRF Max tx power (+8dBm). (Since the signal from the tx channel of bladeRF is distributed 4 ways, the actual power should be about 6dB higher than the graph.)

UE_spectrum(tx_gain=100,120,80,60,140,300)

Steps to reproduce the problem

[enb,epc hostPC] wifi turn-on , connect to the Internet

cd ~/srsLTE-release_20_10_1
sudo srsepc_if_masq.sh wlp6s0

[epc]

cd ~/srsLTE-release_20_10_1/srsepc
sudo srsepc epc.conf

[enb]

cd ~/srsLTE-release_20_10_1/srsenb
sudo srsenb enb.conf

[ue]

cd ~/srsLTE-release_20_10_1/srsue
sudo srsue ue.conf

Additional Information

andrepuschmann commented 3 years ago

Hey,

the tx_gain set in the config files is directly fed into the RF driver, be it UHD, Soapy or the native bladeRF driver. I am pretty sure that the max value is capped in all drivers, so what you're seeing is perfectly fine.

The max output power of the device is usually not achieved over such a wide bandwidth, i.e. 10 MHz in your case.

Hope that helps.