5G-MAG / rt-mbms-modem

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

Enable AGC on BladeRF #28

Closed alessandrolucco closed 2 years ago

alessandrolucco commented 2 years ago

Describe the bug We have noticed that using the BaldeRF SDR, the AGC is disabled when the modem process is started. We cannot understand if it is a bug or if it is used for other SDRs. We tried to enable it changing false to true in the following line: https://github.com/5G-MAG/rt-mbms-modem/blob/b42aea935be136325f7798e94fa959269705d8c7/src/SdrReader.cpp#L152 Recompiling the code we see that the SDR card adjusts the gain following the input level

To Reproduce Steps to reproduce the behavior:

  1. The signal is generated using the R&S chain (BSCC + SDE900 + TLU9)
  2. A radio channel emulators is used to simulate reception in an external environment (it is possible to reproduce the problem by simply using a variable attenuator)
  3. We noticed that the SDR card does not automatically adjust the signal level, as stated in the specs (https://www.nuand.com/bladerf-2-0-micro/#blade-featured-wapper)

Desktop:

Additional context We noticed that this feature is only available on BladeRF. We tested the same code (with the modified instruction) on the HackRF board: the gain remains fixed, but the process works correctly.

dsilhavy commented 2 years ago

For means of completion. In RC 1.2.0 AGC can be enabled via _use_agc boolean flag in SdrReader.h

dsilhavy commented 2 years ago

We should add this as a config parameter, assigning this to myself

dsilhavy commented 2 years ago

Implemented in #34 closing this issue. Please let me know in case you run into any issues.