Quick retune not working, BladeRF2

Discussions related to embedded firmware, driver, and user mode application software development
Post Reply
Dmitriy
Posts: 6
Joined: Thu Dec 20, 2018 6:15 am

Quick retune not working, BladeRF2

Post by Dmitriy »

Hi!

A wide frequency range should be swept, so i tried to use the "bladerf_get_quick_tune" routine to minimize the latency. Unfortunately it returns -8 code (capability not supported). What am i doing wrong?

According to the example quick_tune.c, i need to set a frequency first, then read the "bladerf_quick_tune" struct, then set another frequency, read the another structure and so on. After all structures are filled i should use the "bladerf_schedule_retune" passing the structure as a parameter. Unfortunately the "bladerf_get_quick_tune" does not work. The device is open, enabled and initialized. The first step (set a frequency) works fine.

Your assistance would be greatly appreciated...
robert.ghilduta
Posts: 156
Joined: Thu Feb 28, 2013 11:14 pm

Re: Quick retune not working, BladeRF2

Post by robert.ghilduta »

Hi Dmitriy,

What libbladeRF and FPGA version are you running?
I would suggest giving master on the bladeRF Github a try along with the latest FPGA version ( https://www.nuand.com/fpga/hostedxA4-latest.rbf or https://www.nuand.com/fpga/hostedxA9-latest.rbf )
Dmitriy
Posts: 6
Joined: Thu Dec 20, 2018 6:15 am

Re: Quick retune not working, BladeRF2

Post by Dmitriy »

Hi Robert

My board is 'bladerf2' (A4).
Current FPGA version is 0.9.0. Just in case i uploaded the provided FPGA firmware file via the BladeRF-cli utility.

I run the 'libbladeRF_test_quick_retune" utility and got the message: "Failed to get f1 quick tune: Operation not supported"
Quick retune test.jpg
Dmitriy
Posts: 6
Joined: Thu Dec 20, 2018 6:15 am

Re: Quick retune not working, BladeRF2

Post by Dmitriy »

Messages from libbladeRF_test_ctrl:
libbladeRF_test_ctrl.jpg
bglod
Posts: 201
Joined: Thu Jun 18, 2015 6:10 pm

Re: Quick retune not working, BladeRF2

Post by bglod »

Please update your FPGA and libbladeRF.
  1. FPGA images (currently v0.10.2)
  2. Latest bladeRF Windows Installer (currently 2018.12-rc3)
Those libbladeRF_test_ctrl errors are likely because that test hasn't (yet) been updated. Don't panic, the libbladeRF_tests are not the factory tests we use for hardware validation; they're 'quick' software feature tests and are intended for developers.
Electrical Engineer
Nuand, LLC.
Dmitriy
Posts: 6
Joined: Thu Dec 20, 2018 6:15 am

Re: Quick retune not working, BladeRF2

Post by Dmitriy »

The "bladerf_get_quick_tune" function looks to work now, returning 0. I am trying to move further by testing the "sync rx" with meta data.
Unfortunately, the "bladerf_sync_rx" function always returns -14 code (BLADERF_ERR_TIME_PAST).

Are there any changes in the latest firmware? Did somebody checked the operation of the latest BladeRF A4 in the time stamped mode?

My sequence of actions is the following:
bladerf_sync_config with parameter BLADERF_FORMAT_SC16_Q11_META
bladerf_enable_module
bladerf_set_frequency
zero metadata
bladerf_get_timestamp
add samplerate to timestamp (in order to start in 1 second)
bladerf_sync_rx with metadata and long timeout

Result is always -14 not depending on how big time shift is added to the timestamp.

When in the BLADERF_FORMAT_SC16_Q11 mode everything works OK, but i am trying to get benefits of quick tuning and time stamped reception.

Any advise would be greatly appreciated...
Dmitriy
Posts: 6
Joined: Thu Dec 20, 2018 6:15 am

Re: Quick retune not working, BladeRF2

Post by Dmitriy »

After reducing the SampleRate from 61440000 to 30000000 the problem appears just sometimes now.
Will continue to test.
Does the selected driver (LibUSB or CYPRESS FX3) have any influence on the ability to pass data on higher sample rates?
I've selected the LibUSB when installing the BladeRF software.
bglod
Posts: 201
Joined: Thu Jun 18, 2015 6:10 pm

Re: Quick retune not working, BladeRF2

Post by bglod »

Possibly. Feel free to experiment. The USB controller itself also plays a role; some are significantly better than others. Here's a list of known good/bad controllers. It relies on user-submitted data, so it's not comprehensive.
Electrical Engineer
Nuand, LLC.
Post Reply