Hi!
I'm just wondering what the best way to be able to contribute code into the rtl-sdr project is?
I've added support for the FC0012 tuner (based on the dvb driver and cleaned up some), and would much rather contribute directly rather than fork it just for the sake of the stuff I write.
There's a diff here: https://gist.github.com/2171926 against rtl-sdr a few days back. I've got a couple of fixes that aren't in that patch still to upload (like setting GPIO6 to flip the V/U band filter. Oops.)
Cheers,
David
Hi David,
On Mon, Mar 26, 2012 at 01:21:03AM +1100, David Basden wrote:
I'm just wondering what the best way to be able to contribute code into the rtl-sdr project is?
Clone our git tree and make reasonably-sized commits (one bugfix / logical change per commit), put your email/realname in the git config and write a short summary of your commit.
Then use git send-email to send the patches to the osmocom-sdr mailinglist.
I've added support for the FC0012 tuner (based on the dvb driver and cleaned up some), and would much rather contribute directly rather than fork it just for the sake of the stuff I write.
If you think there will be regular contributions, we could give you git commit access. But even in that case, we normally expect developers to commit to a private branch from which the maintainer (in this case Steve Markgraf) will cherry-pick or merge.
Regards, Harald
Hi,
On 25.03.2012 16:21, David Basden wrote:
I've added support for the FC0012 tuner (based on the dvb driver and cleaned up some), and would much rather contribute directly rather than fork it just for the sake of the stuff I write.
We're currently in the process of completely refactoring the code and separating it into a library for using it from commandline as well as a Gnuradio source block, so I will merge the FC0012 driver after that.
Regards, Steve
Hi David,
Hi,
It works on my Ezcap eztv646 ! Congratulations and thank you.
However I had to tweak main.c and force fc0002 tuner because it was always taking elonics e4000 tuner. This because the Ezcap seems to have clash with the VID&PID, mine is 0BDA:2838, the same codes as for the model with an elonics tuner. I don't know if there's another way to differentiate them. Otherwise, rtl-sdr will need to have a flag to force a certain type of tuner.
It works on FM band but with bad performance and I have noticed unwanted images (at +/-400kHz) and also adjacent interference problems.
There is not this problem with the Noxon DAB+ key that has a FC0013 tuner. My interpretation is that the FC0013 has got enhanced filtering (looking at the driver code).
There may be ways to adjust gains in FC0012 but there's very few information about this chip unfortunately. I didn't have the occasion to test the elonics tuner yet (order in wait mode at dealextreme, Terratec Cinergy RC rev3 not yet available here yet)
Trying different sampling frequencies, it seems it doesn't work under 1Msample/s.
For those interested to interface directly with gnuradio, it works well using FIFO and a buffer (mbufer), example command: ./rtl-sdr -f 96700000 -s 2048000 /dev/stdout |mbuffer -m 32m -P 25 >out.fifo
Cheers
Mathias
________________________________ De : David Basden davidb-sdr@rcpt.to À : osmocom-sdr@lists.osmocom.org Envoyé le : Dimanche 25 mars 2012 16h21 Objet : Contributing to rtl-sdr (fc0012)
Hi!
I'm just wondering what the best way to be able to contribute code into the rtl-sdr project is?
I've added support for the FC0012 tuner (based on the dvb driver and cleaned up some), and would much rather contribute directly rather than fork it just for the sake of the stuff I write.
There's a diff here: https://gist.github.com/2171926 against rtl-sdr a few days back. I've got a couple of fixes that aren't in that patch still to upload (like setting GPIO6 to flip the V/U band filter. Oops.)
Cheers,
David
On Tue, Mar 27, 2012 at 05:17:37AM -0700, Mathias Coinchon wrote:
It works on my Ezcap eztv646 ! Congratulations and thank you.
However I had to tweak main.c and force fc0002 tuner because it was always taking elonics e4000 tuner. This because the Ezcap seems to have clash with the VID&PID, mine is 0BDA:2838, the same codes as for the model with an elonics tuner. I don't know if there's another way to differentiate them. Otherwise, rtl-sdr will need to have a flag to force a certain type of tuner.
It seems that the DVB driver detects the actual tuner types rather than hardcoding them (check_tuner_type in rtl2832u_fe.c). It goes through each type of tuner it knows about, and tries to read a value over the I2C bus at the address it expects that tuner, for a value that will distinguish it (so many different types of tuners use the same I2C address that responding isn't alone enough to distinguish a particular tuner)
It shouldn't be too hard to do. Both the FC0012 and FC0013 will respond to a read from (base 0xc6) address 0x0. After powerup, the FC0012 with return 0xa1, and the FC0013 will return 0xa3. The E4000 will respond to a read from (base 0xc8) address 0x02 with 0x40.
I don't know if it's going to be much use putting in the detection stuff while the rest of the structure is being refactored towards sanity though; I'm trying (and failing) to alter main.c as little as possible.
It works on FM band but with bad performance and I have noticed unwanted images (at +/-400kHz) and also adjacent interference problems.
There is not this problem with the Noxon DAB+ key that has a FC0013 tuner. My interpretation is that the FC0013 has got enhanced filtering (looking at the driver code).
I've updated https://gist.github.com/2171926 just now with some changes I made today that have improved things quite significantly for me. I've also started trying to document the different registers a bit more, and removed code that was never being called, and that may not have as much use to SDR, such as the DTV RSSI LNA auto-adjustment. (If the latter is a mistake, at least the code is in the DTV module still, and some of the more readable in there at that).
At the end of the day, I think you're right about the enhanced filtering in the FC0013. Also, I still haven't fixed the V/U band filter switching, which is bound to be affecting some things.
I've also noticed that my key's tuner occasionally seems to get confused and won't change frequencies without being taken out and plugged in again. I have also been probably feeding it strange inputs more than once though.
There may be ways to adjust gains in FC0012 but there's very few information about this chip unfortunately.
There is actually a fair bit of control over the LNA for the FC0012 at least. Setting register 0x13 will give you from -9.9dB to 19.7dB gain, with at least 20 steps in between. I just noticed FC0012_LNA_GAIN_TABLE in rtl2832u_fe.c of the DVB code (strange place for it; It just happened to be near the tuner detection code) which gives a whole lot of useful values.
Thanks for testing it out!
Cheers,
David