public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
* rtl2832_sdr and /dev/swradio0
@ 2017-01-31 17:50 Russel Winder
  2017-02-01  1:28 ` Nicolas Dufresne
  2017-02-01 17:23 ` Antti Palosaari
  0 siblings, 2 replies; 3+ messages in thread
From: Russel Winder @ 2017-01-31 17:50 UTC (permalink / raw)
  To: DVB_Linux_Media

[-- Attachment #1: Type: text/plain, Size: 729 bytes --]

Hi,

Is anyone actively working on the rtl2832_sdr driver?

I am particularly interested in anyone who has code for turning the
byte stream from /dev/swradio0 into an ETI stream. Or failing that
getting enough data about the API for using /dev/swradio0 so as to
write a byte sequence to ETI driver based on the dab2eti program in
DABtool (which uses the librtlsdr mechanism instead of the
/dev/swradio0 one).

-- 
Russel.
=============================================================================
Dr Russel Winder      t: +44 20 7585 2200   voip: sip:russel.winder@ekiga.net
41 Buckmaster Road    m: +44 7770 465 077   xmpp: russel@winder.org.uk
London SW11 1EN, UK   w: www.russel.org.uk  skype: russel_winder

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: rtl2832_sdr and /dev/swradio0
  2017-01-31 17:50 rtl2832_sdr and /dev/swradio0 Russel Winder
@ 2017-02-01  1:28 ` Nicolas Dufresne
  2017-02-01 17:23 ` Antti Palosaari
  1 sibling, 0 replies; 3+ messages in thread
From: Nicolas Dufresne @ 2017-02-01  1:28 UTC (permalink / raw)
  To: Russel Winder, DVB_Linux_Media

[-- Attachment #1: Type: text/plain, Size: 990 bytes --]

Le mardi 31 janvier 2017 à 17:50 +0000, Russel Winder a écrit :
> Hi,
> 
> Is anyone actively working on the rtl2832_sdr driver?
> 
> I am particularly interested in anyone who has code for turning the
> byte stream from /dev/swradio0 into an ETI stream. Or failing that
> getting enough data about the API for using /dev/swradio0 so as to
> write a byte sequence to ETI driver based on the dab2eti program in
> DABtool (which uses the librtlsdr mechanism instead of the
> /dev/swradio0 one).

This device works like any V4L2 driver, with the differences explained
here:

https://linuxtv.org/downloads/v4l-dvb-apis-new/uapi/v4l/dev-sdr.html

For the rest I'm no expert. You can probably port dab2eti to use this
interface instead of librtlsdr and keep the rest. You may be able to
skip an fft if your driver supports it, otherwise you'll get RU12, that
you'll probably have to convert to floats before passing to the rest of
the processing code.

regards,
Nicolas

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 181 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: rtl2832_sdr and /dev/swradio0
  2017-01-31 17:50 rtl2832_sdr and /dev/swradio0 Russel Winder
  2017-02-01  1:28 ` Nicolas Dufresne
@ 2017-02-01 17:23 ` Antti Palosaari
  1 sibling, 0 replies; 3+ messages in thread
From: Antti Palosaari @ 2017-02-01 17:23 UTC (permalink / raw)
  To: Russel Winder, DVB_Linux_Media

On 01/31/2017 07:50 PM, Russel Winder wrote:
> Hi,
>
> Is anyone actively working on the rtl2832_sdr driver?
>
> I am particularly interested in anyone who has code for turning the
> byte stream from /dev/swradio0 into an ETI stream. Or failing that
> getting enough data about the API for using /dev/swradio0 so as to
> write a byte sequence to ETI driver based on the dab2eti program in
> DABtool (which uses the librtlsdr mechanism instead of the
> /dev/swradio0 one).
>

Easiest way to test it just use v4l2-ctl to configure device and then 
read data from device file.

$ #set ADC 2M
$ v4l2-ctl -d /dev/swradio0 --tuner=0 --set-freq=2.000
Frequency for tuner 0 set to 2000000 (2.000000 MHz)
$ #set rf tuner 98.1MHz
$ v4l2-ctl -d /dev/swradio0 --tuner=1 --set-freq=98.1
Frequency for tuner 1 set to 98100000 (98.100000 MHz)
$ # dump 32 I/Q samples
$ cat /dev/swradio0 |hexdump -n 64 -C
00000000  80 80 7e 7d 84 84 70 71  a8 5f 74 9f 6e 53 b4 9d 
|..~}..pq._t.nS..|
00000010  53 8f 9e 4c 71 b8 75 28  a1 8a 57 8c 9d 46 73 c7 
|S..Lq.u(..W..Fs.|
00000020  79 60 a6 ae 36 82 94 60  6c bf 7e 6a a7 9e 55 73 
|y`..6..`l.~j..Us|
00000030  a8 72 5c a6 7f 35 a2 a2  61 54 ce 8a 57 b3 8e 50 
|.r\..5..aT..W..P|
00000040
$

Looking v4l2-ctl code could give some ideas how to use control IOCTLs. 
Data can be read both read() or mmap() method.


regards
Antti

-- 
http://palosaari.fi/

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-02-01 17:23 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-01-31 17:50 rtl2832_sdr and /dev/swradio0 Russel Winder
2017-02-01  1:28 ` Nicolas Dufresne
2017-02-01 17:23 ` Antti Palosaari

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox