[linux-dvb] re: megasky does it actualy tune then???

Andrew Waldram andy at samuri.demon.co.uk
Wed Oct 25 18:05:46 CEST 2006

had a look at qt1010.h and it doesn't make sense to me.

the base frequency for Crystal palace is 505833333 and QT_MIN_Step is

and we have this chunk of code

        if (freq % QT1010_MIN_STEP)
                printk("frequency not supported.\n");

        div = (freq - QT1010_MIN_FREQ) / QT1010_MIN_STEP;
        mod = (div + 16 - 9) % 16;

then obviously we get freq not supported even though its a valid

I've tried adding 16667 to freq which clears the error and can see the
megasky is tuning but of cause cannot get a lock as the wrong freq is

It appears that this is hard coded throughout to set tuning of the
megasky so it looks like this tuner can only tune in the country of
origin of the original developer.
Unfortunately I am not clever enough to go any further as I don't have
enough experience of USB or C.
I did get a usbsnoop when changing channels from the windows driver but
it was just tons of hex. 

On Thu, 2006-10-19 at 18:02 -0400, Michael Krufky wrote:
> Andrew Waldram wrote:
> > On Thu, 2006-10-19 at 17:04 -0400, Michael Krufky wrote:
> >>>> The problem is not in the megasky m920x / gl861 driver itself -- rather,
> >>>> the qt1010 code is not complete.  There are some pending patches on the
> >>>> linux-dvb list that you should feel welcome to try.  I have not applied
> >>>> these yet, because I am unsure as to whether or not they are appropriate.
> >>
> >> Even still, I dont think those patches will solve it entirely.  As I
> >> understand it, the qt1010 code was reverse engineered...  This means that
> >> as it is now, it will probably only work for the tv standards used by the
> >> author who did that reverse engineering.
> >>
> >> If you're feeling adventurous, it might be a good idea to sniff usb
> >> traffic from the windows driver, and see how the tuner is being controlled.
> > 
> > How right you are
> > 
> > these patches do not help at all
> > it does look like Malcolm could well be right.
> > 
> > Is there any good documentation where to start sniffing/reverse
> > engineering (I'm not stupid but pretty vague at times;-) )
> Markus has some useful information on his wiki page:
> http://linuxtv.org/v4lwiki/index.php/Em2820
> When reading this page, please keep in mind that the examples on it are all
> em28xx-based usb devices, so naturally not all of the information will apply
> exactly.  However, the scripts in his v4l_experimental/em2880 directory are
> useful for any usb device.  If you end up using the scripts in his tree
> (located at http://linuxtv.org/hg/~mrechberger/v4l-dvb) , just remember to
> use the modules from the megasky tree.  :-)
> Good Luck,
> Mike

More information about the linux-dvb mailing list