5G-MAG / rt-mbms-modem

MBMS - Modem
https://www.5g-mag.com/5gbroadcast
GNU Affero General Public License v3.0
15 stars 12 forks source link

Unable to initialise SDR #16

Closed Simons-CSharp closed 2 years ago

Simons-CSharp commented 2 years ago

Describe the bug SDR - BladeRF 2.0 AX5 Laptop Ubuntu 20.04

When I run the background receive process the program crashes unable to initialise the SDR

Screen text: siroda@SirodaSDR:~/rt-mbms-modem/build$ sudo modem [sudo] password for siroda: modem[483043]: 5g-mag-rt modem v1.1.1 starting up modem[483043]: Initialising SDR [INFO] Make connection: '' terminate called after throwing an instance of 'std::runtime_error' what(): Failed to make connection with '' Aborted

I've checked the SDR is connected using Soapycli: siroda@SirodaSDR:/usr/share/Nuand/bladeRF$ SoapySDRUtil --find ######################################################

Soapy SDR -- the SDR abstraction library

######################################################

[INFO] [UHD] linux; GNU C++ version 9.2.1 20200304; Boost_107100; UHD_3.15.0.0-2build5 Found device 0 default_input = True default_output = True device_id = 0 driver = audio label = hw:HDA Intel PCH,0

Found device 1 default_input = False default_output = False device_id = 6 driver = audio label = default

Found device 2 backend = libusb device = 0x02:0x02 driver = bladerf instance = 0 label = BladeRF #0 [538f5e04..76ddf502] serial = 538f5e0428fd4a48977af4bb76ddf502

I then checked the bladeRF was working using the bladeRF-cli siroda@SirodaSDR:~/rt-mbms-modem/build$ bladeRF-cli -i bladeRF> info

Board: Nuand bladeRF 2.0 (bladerf2) Serial #: 538f5e0428fd4a48977af4bb76ddf502 VCTCXO DAC calibration: 0x2189 FPGA size: 77 KLE FPGA loaded: yes Flash size: 32 Mbit (assumed) USB bus: 2 USB address: 2 USB speed: SuperSpeed Backend: libusb Instance: 0

bladeRF> version

bladeRF-cli version: 1.8.0-git-43a559dd libbladeRF version: 2.4.1-git-43a559dd

Firmware version: 2.4.0-git-a3d5c55f FPGA version: 0.14.0 (configured by USB host)

bladeRF>

In supporting_files I've set the 5gmag-rt.conf sdr section to: modem: { sdr: { center_frequency_hz = 3414720000L; filter_bandwidth_hz = 20000000; search_sample_rate = 7680000;

normalized_gain = 40.0;
device_args = "driver=bladerf";
antenna = "RX"

ringbuffer_size_ms = 200;
reader_thread_priority_rt = 50;

}

Expected behavior I wanted the background process to run so I can use OBECA GUI. I'm sure I've incorrectly set something in a conf file, but I'm not sure where to look.

Screenshots See above

Desktop (please complete the following information):

Additional context I can initialise the SDR through Pothos Flow, and set the frequency etc, so the issue seems to in the receive process. I'm happy to get to the cause of this as the LimeSDR's and BladeRF2.0 A4's are in short supply, so this might be an alternative.

dsilhavy commented 2 years ago

@Simons-CSharp Did you run the modem process as a service first? See https://github.com/5G-MAG/rt-mbms-modem#42-enabling-receive-process-daemon-for-correct-pre-configuring

Simons-CSharp commented 2 years ago

@dsilhavy thanks for responding, its appreciated! I checked this and the service is running --> systemctl --type=service UNIT LOAD ACTIVE SUB DESCRIPTION
5gmag-rt-modem.service loaded active start-pre 5gmag-rt-modem - 5G-MAG Reference Tools: MBMS Modem
accounts-daemon.service loaded active running Accounts Service
acpid.service loaded active running ACPI event daemon
alsa-restore.service loaded active exited Save/Restore Sound Card State
apparmor.service loaded active exited Load AppArmor profiles
apport.service loaded active exited LSB: automatic crash report generation

I tried again siroda@SirodaSDR:~/rt-mbms-modem/build$ sudo ./modem modem[17190]: 5g-mag-rt modem v1.1.1 starting up modem[17190]: Initialising SDR [INFO] Make connection: '' terminate called after throwing an instance of 'std::runtime_error' what(): Failed to make connection with '' Aborted siroda@SirodaSDR:~/rt-mbms-modem/build$

This feels like I've missed a conf file somewhere....

Thanks again Simon

Simons-CSharp commented 2 years ago

Fixed! The documentation says to edit the rt-mbm configuation which I understood to be the 5gmag-rt.conf in rt-mbms-modem/supporting_files. The actual file is in /etc/5gmag-rt.conf

Connected to the BladeRF 2.0 AX5 and reading data from it. Will try it in a Lab and report the progress. Thanks Simon

dsilhavy commented 2 years ago

@Simons-CSharp Thank you for the update. Can you please point me to the part of the documentation that can be improved

Simons-CSharp commented 2 years ago

Hi Daniel, In the installation instructions the location on the 5gmag-rt.conf is unclear. This file exists in two places one in /etc and the other in the installation directory + /rt-mbms-modem/supporting_files. I was editing the 5gmag-rt.conf in /supporting_files. Thanks Simon

dsilhavy commented 2 years ago

@Simons-CSharp Thank you, I adjusted it in Modem installation instructions. Can we close this issue?

Simons-CSharp commented 2 years ago

Hi Daniel,

Yes please!

Thanks

Simon

From: Daniel Silhavy @.> Sent: 08 December 2021 14:29 To: 5G-MAG/rt-mbms-modem @.> Cc: Simon Page @.>; Mention @.> Subject: Re: [5G-MAG/rt-mbms-modem] Unable to initialise SDR (Issue #16)

@Simons-CSharp https://github.com/Simons-CSharp Thank you, I adjusted it in Modem installation instructions. Can we close this issue?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/5G-MAG/rt-mbms-modem/issues/16#issuecomment-988862760 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AL6SFNA26VFI2VPHCQHFVTDUP5TSXANCNFSM5IHHMXLA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub . https://github.com/notifications/beacon/AL6SFNAVJ4CTOHKNJ77YZLDUP5TSXA5CNFSM5IHHMXLKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOHLYNSKA.gif