srsran / srsRAN_4G

Open source SDR 4G software suite from Software Radio Systems (SRS) https://docs.srsran.com/projects/4g

Home Page:https://www.srsran.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

srsRAN gnb cannot find USRP B210

bcgordon3 opened this issue · comments

Issue Description

I have a new build on Ubuntu 22.04. I have seen similar issues, but not the same. This one seems like I am just missing a fundamental step somewhere but can't figure out where. The srsRAN gNB SW cannot find the UHD device (USRP B210) connected to the system. I get the following error when trying to start:

No radio devices available.
srsGNB ERROR: Unable to create radio session.

Setup Details

[Specify details of the test setup. This would help us reproduce the problem reliably]
I have the latest source (commit 50fe9623c) as of 2/21/2024.
Ubuntu 22.04.03
Did the UHD repo addition and install:
sudo add-apt-repository ppa:ettusresearch/uhd
sudo apt-get update
sudo apt-get install libuhd-dev uhd-host

B210 connected via USB 3.1 to PC with intel i7-1185G7E, 16GB RAM

Expected Behavior

I expected the gnb SW to run and start transmitting.

Actual Behaviour

Here is the output I get when changing the AMF IP in the config file to my local 5G core:

sudo gnb -c gnb_rf_b210_fdd_srsUE.yml

The PRACH detector will not meet the performance requirements with the configuration {Format 0, ZCZ 0, SCS 1.25kHz, Rx ports 1}.
Lower PHY in quad executor mode.

--== srsRAN gNB (commit 50fe9623c) ==--

Connecting to AMF on 10.10.4.1:38412
No radio devices available.
srsGNB ERROR: Unable to create radio session.

Steps to reproduce the problem

Only modified line in the config is the AMF and bind IP addresses.

Additional Information

I did a make clean, git pull, then redid the whole build and test process with success. The UHD device is found on the PC. Below are the cmake output and the summary lines from make then make tests. Following that is the output from the uhd_find_devices and uhd_usrp_probe.

cmake output:

cmake ../
-- The C compiler identification is GNU 11.4.0
-- The CXX compiler identification is GNU 11.4.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Build type not specified: defaulting to Release.
-- Performing Test HAS_MAYBE_UNINITIALIZED
-- Performing Test HAS_MAYBE_UNINITIALIZED - Success
-- Performing Test HAVE_NON_VIRTUAL_DTOR
-- Performing Test HAVE_NON_VIRTUAL_DTOR - Success
-- Performing Test HAVE_SUGGEST_OVERRIDE
-- Performing Test HAVE_SUGGEST_OVERRIDE - Success
-- Performing Test HAVE_SHADOW
-- Performing Test HAVE_SHADOW - Success
-- Assertion level set to NORMAL
-- Could NOT find libdw (missing: LIBDW_LIBRARY LIBDW_INCLUDE_DIR)
-- Could NOT find libbfd (missing: LIBBFD_LIBRARY LIBBFD_INCLUDE_DIR)
-- Could NOT find libdwarf (missing: LIBDWARF_LIBRARY LIBDWARF_INCLUDE_DIR LIBELF_LIBRARY LIBELF_INCLUDE_DIR)
-- Found Backward: /home/siguser/srsgnb/srsRAN_Project/cmake/modules
-- Backward-cpp found, but external libraries are missing.
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.29.2")
-- Checking for module 'mbedtls'
-- No package 'mbedtls' found
-- MBEDTLS LIBRARIES: /usr/lib/x86_64-linux-gnu/libmbedcrypto.so
-- MBEDTLS STATIC LIBRARIES: /usr/lib/x86_64-linux-gnu/libmbedcrypto.a
-- MBEDTLS INCLUDE DIRS: /usr/include
-- Found MbedTLS: /usr/lib/x86_64-linux-gnu/libmbedcrypto.so
-- Checking for module 'fftw3f >= 3.0'
-- Found fftw3f , version 3.3.8
-- FFTW3F LIBRARIES: /usr/lib/x86_64-linux-gnu/libfftw3f.so
-- FFTW3F STATIC LIBRARIES: /usr/lib/x86_64-linux-gnu/libfftw3f.a
-- FFTW3F INCLUDE DIRS: /usr/include
-- Found FFTW3F: /usr/lib/x86_64-linux-gnu/libfftw3f.so
-- Found GTest: /usr/lib/x86_64-linux-gnu/cmake/GTest/GTestConfig.cmake (found version "1.11.0")
-- Found Threads: TRUE
-- UHD LIBRARIES /usr/lib/x86_64-linux-gnu/libuhd.so
-- UHD INCLUDE DIRS /usr/include
-- Found UHD: /usr/lib/x86_64-linux-gnu/libuhd.so
-- Checking for module 'yaml-cpp'
-- Found yaml-cpp, version 0.7.0
-- YAMLCPP LIBRARIES: /usr/lib/x86_64-linux-gnu/libyaml-cpp.so
-- YAMLCPP INCLUDE DIRS: /usr/include
-- Found YAMLCPP: /usr/lib/x86_64-linux-gnu/libyaml-cpp.so
-- Performing Test HAVE_SSE
-- Performing Test HAVE_SSE - Success
-- SSE4.1 is enabled - target CPU must support it
-- Performing Test HAVE_AVX
-- Performing Test HAVE_AVX - Success
-- AVX is enabled - target CPU must support it
-- Performing Test HAVE_AVX2
-- Performing Test HAVE_AVX2 - Success
-- AVX2 is enabled - target CPU must support it
-- Performing Test HAVE_FMA
-- Performing Test HAVE_FMA - Success
-- FMA is enabled - target CPU must support it
-- Performing Test HAVE_AVX512
-- Performing Test HAVE_AVX512 - Success
-- AVX512 is enabled - target CPU must support it
-- Performing Test HAVE_MARCH
-- Performing Test HAVE_MARCH - Success
-- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE)
-- Checking for module 'sctp'
-- No package 'sctp' found
-- SCTP LIBRARIES: /usr/lib/x86_64-linux-gnu/libsctp.so
-- SCTP INCLUDE DIRS: /usr/include
-- Found SCTP: /usr/lib/x86_64-linux-gnu/libsctp.so
-- FFT_LIBRARIES: /usr/lib/x86_64-linux-gnu/libfftw3f.so
-- Building srsRAN version 23.10.1
-- Configuring done
-- Generating done
-- Build files have been written to: /home/srsgnb/srsRAN_Project/build

make ending:

[100%] Linking CXX executable gnb
[100%] Linking CXX executable up_resource_manager_test
[100%] Built target gnb
[100%] Built target up_resource_manager_test
[100%] Linking CXX executable du_processor_test
[100%] Built target du_processor_test

make test summary:

100% tests passed, 0 tests failed out of 4642

uhd_find_devices:

sudo uhd_find_devices
[INFO] [UHD] linux; GNU C++ version 11.4.0; Boost_107400; UHD_4.6.0.0-0ubuntu1~jammy1

-- UHD Device 0

Device Address:
serial: 312AC3A
name: MyB210
product: B210
type: b200

uhd_usrp_probe:

sudo uhd_usrp_probe
[INFO] [UHD] linux; GNU C++ version 11.4.0; Boost_107400; UHD_4.6.0.0-0ubuntu1~jammy1
[INFO] [B200] Detected Device: B210
[INFO] [B200] Operating over USB 3.
[INFO] [B200] Detecting internal GPSDO....
[INFO] [GPS] Found an internal GPSDO: GPSTCXO , Firmware Rev 0.929a
[INFO] [B200] Initialize CODEC control...
[INFO] [B200] Initialize Radio control...
[INFO] [B200] Performing register loopback test...
[INFO] [B200] Register loopback test passed
[INFO] [B200] Performing register loopback test...
[INFO] [B200] Register loopback test passed
[INFO] [B200] Setting master clock rate selection to 'automatic'.
[INFO] [B200] Asking for clock rate 16.000000 MHz...
[INFO] [B200] Actually got clock rate 16.000000 MHz.


/
| Device: B-Series Device
| _____________________________________________________
| /
| | Mboard: B210
| | serial: 312AC3A
| | name: MyB210
| | product: 2
| | revision: 4
| | FW Version: 8.0
| | FPGA Version: 16.0
| |
| | Time sources: none, internal, external, gpsdo
| | Clock sources: internal, external, gpsdo
| | Sensors: gps_gpgga, gps_gprmc, gps_time, gps_locked, gps_servo, ref_locked
| | _____________________________________________________
| | /
| | | RX DSP: 0
| | |
| | | Freq range: -8.000 to 8.000 MHz
| | _____________________________________________________
| | /
| | | RX DSP: 1
| | |
| | | Freq range: -8.000 to 8.000 MHz
| | _____________________________________________________
| | /
| | | RX Dboard: A
| | | _____________________________________________________
| | | /
| | | | RX Frontend: A
| | | | Name: FE-RX2
| | | | Antennas: TX/RX, RX2
| | | | Sensors: temp, rssi, lo_locked
| | | | Freq range: 50.000 to 6000.000 MHz
| | | | Gain range PGA: 0.0 to 76.0 step 1.0 dB
| | | | Bandwidth range: 200000.0 to 56000000.0 step 0.0 Hz
| | | | Connection Type: IQ
| | | | Uses LO offset: No
| | | _____________________________________________________
| | | /
| | | | RX Frontend: B
| | | | Name: FE-RX1
| | | | Antennas: TX/RX, RX2
| | | | Sensors: temp, rssi, lo_locked
| | | | Freq range: 50.000 to 6000.000 MHz
| | | | Gain range PGA: 0.0 to 76.0 step 1.0 dB
| | | | Bandwidth range: 200000.0 to 56000000.0 step 0.0 Hz
| | | | Connection Type: IQ
| | | | Uses LO offset: No
| | | _____________________________________________________
| | | /
| | | | RX Codec: A
| | | | Name: B210 RX dual ADC
| | | | Gain Elements: None
| | _____________________________________________________
| | /
| | | TX DSP: 0
| | |
| | | Freq range: -8.000 to 8.000 MHz
| | _____________________________________________________
| | /
| | | TX DSP: 1
| | |
| | | Freq range: -8.000 to 8.000 MHz
| | _____________________________________________________
| | /
| | | TX Dboard: A
| | | _____________________________________________________
| | | /
| | | | TX Frontend: A
| | | | Name: FE-TX2
| | | | Antennas: TX/RX
| | | | Sensors: temp, lo_locked
| | | | Freq range: 50.000 to 6000.000 MHz
| | | | Gain range PGA: 0.0 to 89.8 step 0.2 dB
| | | | Bandwidth range: 200000.0 to 56000000.0 step 0.0 Hz
| | | | Connection Type: IQ
| | | | Uses LO offset: No
| | | _____________________________________________________
| | | /
| | | | TX Frontend: B
| | | | Name: FE-TX1
| | | | Antennas: TX/RX
| | | | Sensors: temp, lo_locked
| | | | Freq range: 50.000 to 6000.000 MHz
| | | | Gain range PGA: 0.0 to 89.8 step 0.2 dB
| | | | Bandwidth range: 200000.0 to 56000000.0 step 0.0 Hz
| | | | Connection Type: IQ
| | | | Uses LO offset: No
| | | _____________________________________________________
| | | /
| | | | TX Codec: A
| | | | Name: B210 TX dual DAC
| | | | Gain Elements: None

I guess nobody else has had this issue. Bump for MWC.

Final comment. I had to reinstall UHD drivers then rebuild srsRAN and then it started working.

Hello!
I have successfully built srsRAN 5G project in Ubuntu 22.04. Further, I have also connected USRP B205 Mini. When I am running ./gnB compiler using B200 TDD config file, I am unable to get following output:
Available radio types: uhd.

--== srsRAN gNB (commit srsran/srsRAN_Project@77be7d3) ==--

[INFO] [UHD] linux; GNU C++ version 9.4.0; Boost_107100; UHD_4.2.0.HEAD-0-g197cdc4f
Making USRP object with args 'type=b200'
Cell pci=1, bw=10 MHz, dl_arfcn=632628 (n78), dl_freq=3489.42 MHz, dl_ssb_arfcn=632640, ul_freq=3489.42 MHz

==== gNodeB started ===
Type to view trace

Instead, the following output is displayed:
The PRACH detector will not meet the performance requirements with the configuration {Format B4, ZCZ 0, SCS 30kHz, Rx ports 1}. Lower PHY in dual executor mode. --== srsRAN gNB (commit 2f90c8b60) ==-- Connecting to AMF on 127.0.1.100:38412 Failed to connect SCTP socket to 127.0.1.100:38412. error="Connection refused" timeout=0ms sr GNB ERROR: Failed to create SCTP gateway.

Please guide me to get through this step. Also, please assist me in setting up 5G SA. I have successfully built open5gs as core network and tested it using UERANSIM. I would want to run open5gs and srsRAN in same machine installed with Ubuntu 22.04.

Thank you
Regards

P.S.: I am having similar issue as mentioned in your post. I followed your final comment by re-installing UHD drivers but no expected output is being generated as mentioned above.

I can't guide you here but maybe can point to a couple things I see.

  1. You are not connecting to an AMF (5G Core) -- the filed SCTP tells you that. You need to fix that.
  2. You have a channel spacing of 30kHz in N78 on 10MHz. Pretty sure the 10 MHz will only support 15KHz spacing.

Good luck.