Key-repeat or release magic in RCU drivers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Marko M?kel? wrote:
> On Sun, Jan 29, 2006 at 10:36:32PM +0000, Darren Salt wrote:
> > > For what it is worth, the driver of the bundled Hauppauge Nova-T RCU in the
> > > Linux kernel 2.6.12 and later will even map key-repeat to a timer. That is,
> > > if it gets a repeated RC5 frame within the timeout, it will keep generating
> > > key-repeat events, at a different rate.
> > 
> > > This makes many things inaccurate, such as scrolling in menus.
> > 
> > I don't see how: with the unmodified budget-ci, it's slow enough...
> 
> RC5 frames are repeated every 113.8 ms (64*T, T=16/9 ms).  The key-release
> timeout in cx88-input.c is 120 ms.  I can't locate the repeat timer value in
> the sources now, but I think it was less than 100 ms.  In your patch, you
> have defined IR_MIN_REPEAT_PERIOD to 133, so it should not be a problem.
> However, you also have IR_MIN_REPEAT_DELAY equal to 250 ms, which means that
> the first repeated RC5 frame will not result in any event.
> 
> > > I would very much like to have a direct correspondence between repeated RC5
> > > frames and key-repeat events, but I could not figure out how to do this in
> > > cx88-input.c
> > 
> > cx88? That'd be the newer Nova-T, not the Nova-T :-)
> 
> Well, Nova-T 90002 REV C176, then. :-)
> 
> > I've posted a set of patches to the v4l list which should be of some help;
> > you should have a look at budget-ci after applying the patches, which you can
> > also get from here:
> >   <URL:http://ymbj/progs/linux/dvb-ir-20060129.patch.tar.gz>
> 
> Hmm, I may be mistaken, but it looks to me as if your patches try to do the
> same thing for older cards as the new Nova-T driver already does.  What I
> would really like to have is to map every RC5 frame either to a key-press or
> to a key-repeat, and a timer for generating key-release events.  Does any
> existing driver (or patch) do that?

The av7110 driver does it exactly this way. I did a lot of testing to
find the optimal method. ;-)

(1) The repeat timer of the input layer must be turned off, and
    the natural repeat rate of the RC5 frames should be used.
    Anything else will result in inaccurate operation.

(2) The key-up timeout should be set to 280ms or higher (>= 2x repeat
    rate). This will allow for one missing RC5 frame which may happen
    due to transmission errors.

Oliver

-- 
--------------------------------------------------------
VDR Remote Plugin available at
http://www.escape-edv.de/endriss/vdr/
--------------------------------------------------------


[Index of Archives]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Util Linux NG]     [Xfree86]     [Big List of Linux Books]     [Fedora Users]     [Fedora Women]     [ALSA Devel]     [Linux USB]

  Powered by Linux