Commit Graph

289 Commits

Author SHA1 Message Date
Dimitri Stolnikov 0923bcb687 remove unused variables 2013-10-25 23:46:34 +02:00
Dimitri Stolnikov 96b5e4388f file: allow changing the sample rate when throttle=true
this is dangerous from signal processing perspective and should be used
with caution.
2013-10-20 18:50:27 +02:00
Dimitri Stolnikov 596790e8c1 cmake: fix flag passing to Clang compiler 2013-10-19 16:38:05 +02:00
Dimitri Stolnikov 6fa0815be0 apps: catch corner cases for file= mode in osmocom_fft
verified for gqrx and sdrangerlove as well:

file=/tmp/lte.cfile,rate=40e6,freq=1815e6,repeat=true,throttle=true
2013-10-18 19:49:12 +02:00
Dimitri Stolnikov c7dcddc3cd bladerf: use newstyle version getters 2013-10-04 18:32:40 +02:00
Dimitri Stolnikov a81016d230 bladerf: make source less picky wrt rf gain 2013-10-03 14:50:24 +02:00
Dimitri Stolnikov 884ee47605 source/sink: initialize sample rate cache variable
Thanks to Jiří Pinkava for bringing this up.
2013-10-03 14:50:16 +02:00
Dimitri Stolnikov 6187f182d5 source/sink: fix automatic bandwidth selection 2013-10-03 14:45:12 +02:00
Dimitri Stolnikov 2d644d2eae rtl: don't try to parse empty device index values 2013-09-28 13:59:23 +02:00
Dimitri Stolnikov 2dfc73351f apps: filter bandwidth follows sample rate in osmocom_fft 2013-09-28 13:59:18 +02:00
Dimitri Stolnikov 89db739999 updated header documentation for bandwidth setter 2013-09-28 13:59:09 +02:00
Dimitri Stolnikov 681e3b7d4a bladerf: implement automatic bandwidth selection 2013-09-28 13:59:03 +02:00
Dimitri Stolnikov 5d5dc04371 hackrf: enable AMP gain stage by default 2013-09-28 13:58:57 +02:00
Dimitri Stolnikov 911f916b3b hackrf: don't set automatic bandwidth on samplerate change
automatic bandwidth selection may be triggered by calling
set_bandwidth(0) after changing the sample rate
2013-09-28 13:58:50 +02:00
Jon Szymaniak a0b534d118 bladeRF: Refactored buffering scheme in sink
Removed the use of an intermediate sample FIFO in the sink
implementation. Note the the FIFO has not been moved out of
bladerf_common --> bladerf_source_c in this commit.

work() now handles converting samples from complex to SC16_Q12, and filling
"transmit-ready" buffers. The callbacks are now only responsible for
marking the provided buffer free, and returning the next buffer.

It appears that a small deadlock issues remains in this changest, which
can be induced by:
 1: Using a small sample rate (160Khz)
 2: Switching back and forth between sinusoid <-> GSM burst

 In this case, it appears that work() is blocked waiting for a buffer to
 become free. More investigation here is required...
2013-09-28 00:42:46 +02:00
Dimitri Stolnikov 1c9a793a70 bladerf: migration to async api (WIP)
receive works, transmit locks up in work() after few seconds
2013-09-28 00:37:58 +02:00
Frederik M.J. Vestre 2e9828f120 Support setting external sampling to bladerf 2013-08-29 23:38:20 +02:00
Dimitri Stolnikov c16a562ddc bladerf: follow recent API changes
tested against aea04c5f119288370166ece05166a8a4157da6fa
2013-08-27 22:42:24 +02:00
Dimitri Stolnikov d0a043ace3 cmake: use *_INCLUDE_DIRS in modules 2013-08-13 20:20:17 +02:00
Dimitri Stolnikov 11841ccb29 bladerf: update common sample rate values 2013-07-28 20:04:27 +02:00
Dimitri Stolnikov 41bb9a0ef9 bladerf: migrate to new api to enable/disable TX/RX modules
TX support has been verified with osmocom_siggen and fpga image from git
f6c6a3abcb22d2794946e5adbc556805a73788a3
2013-07-28 20:04:17 +02:00
Dimitri Stolnikov 65e34f6863 bladerf: add support for nuand LLC bladeRF (WIP)
This is based on the original work (https://github.com/Nuand/gr-osmosdr)
done by folks at nuand LLC for the gr3.6 branch of gr-osmosdr.

The following modifications have been done in this commit:

* port to gr-osmosdr master codebase (gr3.7)
* moved shared properties to bladerf_common
* added & verified IF filter bandwidth setters
* set LMS6002D registers with values taken from FAQ 5.27
* print device information (serial/versions) on startup
* added fpga= and fw= device arguments to program MCU/FPGA
* added bladerf=# dev. arg. to select a specific bladeRF
* grc gain field controls RF path VGA for RX/TX
* grc BB gain field controls BB path VGA for RX/TX

Usage example:

osmocom_fft -a "bladerf,fpga=/tmp/hostedx115.rbf"

The following RX named gain stages are available:

LNA: 0 to 6 dB, in 3dB steps
VGA1: 5 to 30 dB, in 1dB steps; nonlinear mapping done inside the lib
VGA2: 0 to 60 dB, in 3dB steps; not recommended to be used above 30dB

The following TX named gain stages are available:

VGA1: -35 to -4 dB, in 1dB steps, BB side
VGA2: 0 to 25 dB, in 1dB steps, RF side

Thanks a lot to the team of nuand LLC for this major contribution.
2013-07-28 19:57:45 +02:00
Dimitri Stolnikov 7058fd6610 fcd: add support for FUNcube Dongle Pro+
The "3.6" branch of the gnuradio block https://github.com/dl1ksv/gr-

Available named gains:

Dongle Classic:

LNA: -5 to 30 dB, in 2.5 dB steps
MIX: 4 or 12 dB

Dongle Pro+:

LNA: 0 or 1, meaning off/on only. no information about real values.
MIX: 0 or 1, meaning off/on only. no information about real values.
BB: 0 to 59 dB, in 1 dB steps

This patch also introduces optional "device" and "type" arguments which
allow to override the values automatically picked by gr-osmosdr:

osmocom_fft -a "fcd,device=hw:2,type=2"

The "device" argument overrides the audio device used by the underlying
driver to access the dongle's IQ sample stream.

The "type" argument selects the dongle type, 1 for Classic, 2 for Pro+.

Thanks to Alexey Bazhin for the initial patch and Volker Schroer for
testing.
2013-07-28 19:16:28 +02:00
Dimitri Stolnikov 6e2a2023d5 cmake: require Python v2 for build configuration
based on a gnuradio patch by Jiri Pinkava
http://gnuradio.org/cgit/gnuradio.git/commit/?id=8144572532b8bfa37af01e1264a334d2a898ea8d
2013-07-28 17:49:10 +02:00
Dimitri Stolnikov 2d02ae9b83 rtl: remove residue DC component introduced by RTL chip
received from Juha Vierinen:

A student here noticed that there is dc bias even with the rafael tuner.
We looked into this issue and found that using 127.4f instead of 127.5f
removes this bias. I assume this is associated with a bug in the digital
downconversion of the RTL chip. This change fixes the problem.
2013-07-28 17:48:42 +02:00
Dimitri Stolnikov ffd2bbf424 update version to 0.0.3git 2013-06-12 20:29:26 +02:00
Dimitri Stolnikov 7b11f872c4 update version to 0.0.2 2013-06-12 20:18:51 +02:00
Dimitri Stolnikov e42752826c uhd: implement frequency correction 2013-06-10 21:21:14 +02:00
Dimitri Stolnikov d25666b594 apps: allow float frequency correction values 2013-06-09 23:36:58 +02:00
Dimitri Stolnikov 6f04a9b03a uhd: implement dc correction 2013-06-09 23:13:12 +02:00
Dimitri Stolnikov e1f4c24232 hackrf: select narrower filters in auto bw mode to prevent aliasing 2013-06-09 13:11:32 +02:00
Dimitri Stolnikov ed627cea9c hackrf: use new sample rate function introduced in libhackrf b892bc34ad 2013-06-09 09:03:54 +02:00
Dimitri Stolnikov f70550fe40 uhd: implement bandwidth controls 2013-06-08 22:16:05 +02:00
Dimitri Stolnikov 5a4033869f cmake: update url to documentation page 2013-06-08 17:39:56 +02:00
Dimitri Stolnikov faa1f44550 return cached values in setters immediately if same as requested 2013-06-08 17:13:16 +02:00
Dimitri Stolnikov 1822e88148 apps: enable bandwidth control for osmocom_fft and osmocom_siggen 2013-06-08 17:11:53 +02:00
Dimitri Stolnikov 2cd4126288 hackrf: add fractional sample rate support introduced in libhackrf
d9c46cbdac
2013-06-07 22:37:29 +02:00
Dimitri Stolnikov b59b0080f5 hackrf: add human readable error prints to all libhackrf funcs 2013-06-07 22:06:38 +02:00
Dimitri Stolnikov eaec4c5acc apps: check for sample rate availability 2013-06-05 19:58:16 +02:00
Dimitri Stolnikov ba5c6c8da6 hackrf: set the default sample rate to 10M
this prevents a regression with early firmware who did not have 8M rate
but 5M instead. they both had 10M, so we use this as default.
2013-06-05 19:21:13 +02:00
Dimitri Stolnikov 17c2bda9f8 hackrf: disable start/stop as it has caused lock-ups 2013-06-02 16:17:27 +02:00
Dimitri Stolnikov 9714f9cd74 change OSMOCOM to lowercase like in master 2013-05-30 17:21:49 +02:00
Dimitri Stolnikov 0e6b6f9ec9 update revision to 0.0.2git
for next maintenance release 0.0.2 of gr3.6 block series
2013-05-30 17:09:41 +02:00
Dimitri Stolnikov 9cbe22f23d hackrf: change out-of-spec rate 5e6 to 8e6 default 2013-05-30 01:00:45 +02:00
Dimitri Stolnikov 6a70539872 hackrf: update to libhackrf gain API introduced in b5f275abc5 2013-05-30 00:47:32 +02:00
Dimitri Stolnikov fed7cfd368 update revision to 0.0.1
this is the legacy version for gnuradio 3.6
2013-05-29 22:38:14 +02:00
Dimitri Stolnikov ceb14f0f13 hackrf: enable buffers argument for the source block 2013-05-26 13:04:06 +02:00
Dimitri Stolnikov 193fd0ad88 osmosdr: remove deprecated device arguments 2013-05-26 13:02:14 +02:00
Dimitri Stolnikov 4c101ea44c update README 2013-05-26 01:07:24 +02:00
Dimitri Stolnikov de74870c04 cmake: make python support optional 2013-05-25 18:35:04 +02:00