Fernando Laudares Camargos | 15 Feb 2011 21:27
Picon

IR for remote control not working for Hauppauge WinTV-HVR-1150 (SAA7134)

Hello,

I have a Hauppauge WinTV-HVR-1150 (model 67201) pci tv tuner working
(video and audio) under Ubuntu 10.10 and kernel 2.6.35-25. But the IR
sensor is not being detected and no input device is being created at
/proc/bus/input.

I have tried to follow the information from Jarod Wilson and Mauro
Carvalho Chehab in https://bugzilla.redhat.com/show_bug.cgi?id=665870
(regarding Fedora 14) but couldn't resolve it myself.

I'm not a kernel/driver specialist but from looking at the code I've
noticed that *perphaps* the support for the HVR-1150 has not been
finished yet. Here are two examples that leaded to this observation
(IMHO):

drivers/media/video/saa7134/saa7134-cards.c
-------------------------------------------------------------------------------
(...)
int saa7134_board_init1(struct saa7134_dev *dev)
{
(...)
       case SAA7134_BOARD_HAUPPAUGE_HVR1150:           *NO
INSTRUCTIONS FOR THIS CASE*
        case SAA7134_BOARD_HAUPPAUGE_HVR1120:
                /* GPIO 26 high for digital, low for analog */
                saa7134_set_gpio(dev, 26, 0);
                msleep(1);

                saa7134_set_gpio(dev, 22, 0);
(Continue reading)

Jarod Wilson | 15 Feb 2011 23:04
Picon
Favicon

Re: IR for remote control not working for Hauppauge WinTV-HVR-1150 (SAA7134)

First off, video4linux-list is dead, you want linux-media (added to cc).

On Tue, Feb 15, 2011 at 06:27:29PM -0200, Fernando Laudares Camargos wrote:
> Hello,
> 
> I have a Hauppauge WinTV-HVR-1150 (model 67201) pci tv tuner working
> (video and audio) under Ubuntu 10.10 and kernel 2.6.35-25. But the IR
> sensor is not being detected and no input device is being created at
> /proc/bus/input.
> 
> I have tried to follow the information from Jarod Wilson and Mauro
> Carvalho Chehab in https://bugzilla.redhat.com/show_bug.cgi?id=665870
> (regarding Fedora 14) but couldn't resolve it myself.
> 
> I'm not a kernel/driver specialist but from looking at the code I've
> noticed that *perphaps* the support for the HVR-1150 has not been
> finished yet. Here are two examples that leaded to this observation
> (IMHO):
> 
> drivers/media/video/saa7134/saa7134-cards.c
> -------------------------------------------------------------------------------
> (...)
> int saa7134_board_init1(struct saa7134_dev *dev)
> {
> (...)
>        case SAA7134_BOARD_HAUPPAUGE_HVR1150:           *NO
> INSTRUCTIONS FOR THIS CASE*

No. It falls through and uses the same config as the HVR1120. Similar case
for all other instances you've referenced.
(Continue reading)

Jarod Wilson | 15 Feb 2011 23:18
Picon
Favicon

Re: IR for remote control not working for Hauppauge WinTV-HVR-1150 (SAA7134)

On Tue, Feb 15, 2011 at 05:04:33PM -0500, Jarod Wilson wrote:
> First off, video4linux-list is dead, you want linux-media (added to cc).
> 
> On Tue, Feb 15, 2011 at 06:27:29PM -0200, Fernando Laudares Camargos wrote:
> > Hello,
> > 
> > I have a Hauppauge WinTV-HVR-1150 (model 67201) pci tv tuner working
> > (video and audio) under Ubuntu 10.10 and kernel 2.6.35-25. But the IR
> > sensor is not being detected and no input device is being created at
> > /proc/bus/input.

Reading over the code some more, I don't see dev->has_remote set for the
HVR1150, so it appears the IR receiver on that hardware isn't actually yet
supported, so the patch I was thinking of may not help here. I failed to
notice the part where you said no input device was being created, that
patch only mattered if you were getting an rc input device created.

--

-- 
Jarod Wilson
jarod <at> redhat.com

Devin Heitmueller | 16 Feb 2011 17:33
Gravatar

Re: IR for remote control not working for Hauppauge WinTV-HVR-1150 (SAA7134)

On Tue, Feb 15, 2011 at 5:18 PM, Jarod Wilson <jarod <at> redhat.com> wrote:
> On Tue, Feb 15, 2011 at 05:04:33PM -0500, Jarod Wilson wrote:
>> First off, video4linux-list is dead, you want linux-media (added to cc).
>>
>> On Tue, Feb 15, 2011 at 06:27:29PM -0200, Fernando Laudares Camargos wrote:
>> > Hello,
>> >
>> > I have a Hauppauge WinTV-HVR-1150 (model 67201) pci tv tuner working
>> > (video and audio) under Ubuntu 10.10 and kernel 2.6.35-25. But the IR
>> > sensor is not being detected and no input device is being created at
>> > /proc/bus/input.
>
> Reading over the code some more, I don't see dev->has_remote set for the
> HVR1150, so it appears the IR receiver on that hardware isn't actually yet
> supported, so the patch I was thinking of may not help here. I failed to
> notice the part where you said no input device was being created, that
> patch only mattered if you were getting an rc input device created.

I looked at this a few months ago.  The IR isn't supported at all on
that board.  It's basically an IR receiver diode tied directly
directly to a GPIO, and it relies on interrupt edge timing to compute
the codes.

I played with it for a couple of hours and couldn't get it working.
It needs some TLC from somebody who actually has the board.

Devin

--

-- 
Devin J. Heitmueller - Kernel Labs
(Continue reading)

Fernando Laudares Camargos | 16 Feb 2011 17:54
Picon

Re: IR for remote control not working for Hauppauge WinTV-HVR-1150 (SAA7134)

Thanks, Jarod, for re-directing the message and explaining why the fix
from Mauro's wouldn't suffice here.

Devin: I was hoping they (Hauppauge) had used the same componentry as
of the predecessor board (HVR-1120) for the IR, looks that's not the
case. I would like to help to get the card supported but unless
there's a procedure documented somewhere showing what to do I guess I
don't qualify for the job (don't even understand what you meant by
"TLC"). But if I can help somehow, I would be glad to do it.

Regards,

Fernando

On Wed, Feb 16, 2011 at 2:33 PM, Devin Heitmueller
<dheitmueller <at> kernellabs.com> wrote:
> On Tue, Feb 15, 2011 at 5:18 PM, Jarod Wilson <jarod <at> redhat.com> wrote:
>> On Tue, Feb 15, 2011 at 05:04:33PM -0500, Jarod Wilson wrote:
>>> First off, video4linux-list is dead, you want linux-media (added to cc).
>>>
>>> On Tue, Feb 15, 2011 at 06:27:29PM -0200, Fernando Laudares Camargos wrote:
>>> > Hello,
>>> >
>>> > I have a Hauppauge WinTV-HVR-1150 (model 67201) pci tv tuner working
>>> > (video and audio) under Ubuntu 10.10 and kernel 2.6.35-25. But the IR
>>> > sensor is not being detected and no input device is being created at
>>> > /proc/bus/input.
>>
>> Reading over the code some more, I don't see dev->has_remote set for the
>> HVR1150, so it appears the IR receiver on that hardware isn't actually yet
(Continue reading)

Devin Heitmueller | 16 Feb 2011 18:03
Gravatar

Re: IR for remote control not working for Hauppauge WinTV-HVR-1150 (SAA7134)

On Wed, Feb 16, 2011 at 11:54 AM, Fernando Laudares Camargos
<fernando.laudares.camargos <at> gmail.com> wrote:
> Thanks, Jarod, for re-directing the message and explaining why the fix
> from Mauro's wouldn't suffice here.
>
> Devin: I was hoping they (Hauppauge) had used the same componentry as
> of the predecessor board (HVR-1120) for the IR, looks that's not the
> case. I would like to help to get the card supported but unless
> there's a procedure documented somewhere showing what to do I guess I
> don't qualify for the job (don't even understand what you meant by
> "TLC"). But if I can help somehow, I would be glad to do it.

It is the same layout as the 1120 (I cheated and just looked at the
schematic), but despite some user having submitted the patch, it
wasn't working at least for me.  Hence, the fact that you see code in
the driver referencing the 1120 doesn't mean it actually works.

There is no real documented procedure for adding this sort of support.
 It needs to be investigated by an actual driver developer familiar
with the underlying hardware design.  "TLC" is just an English
expression for "Tender Love and Care", an expression that is
synonymous with "giving something the requisite attention".

I've got the board, but just need to find a few hours to debug the IRQ handler.

Devin

--

-- 
Devin J. Heitmueller - Kernel Labs
http://www.kernellabs.com
(Continue reading)

Fernando Laudares Camargos | 17 Feb 2011 12:24
Picon

Re: IR for remote control not working for Hauppauge WinTV-HVR-1150 (SAA7134)

Ok, Devin.

I'm not sure about how it would went but if you think it would be
worth trying to get info about the components of the 1150 directly
from Hauppauge, I can give them a call and see what happens. I've just
ordered 20 of those boards for a project that initially wouldn't relly
on RC but since the IR seems to be there. I'm not saying they would
help, it would be just a try if you think it could help...

Regards,

Fernando

On Wed, Feb 16, 2011 at 3:03 PM, Devin Heitmueller
<dheitmueller <at> kernellabs.com> wrote:
> On Wed, Feb 16, 2011 at 11:54 AM, Fernando Laudares Camargos
> <fernando.laudares.camargos <at> gmail.com> wrote:
>> Thanks, Jarod, for re-directing the message and explaining why the fix
>> from Mauro's wouldn't suffice here.
>>
>> Devin: I was hoping they (Hauppauge) had used the same componentry as
>> of the predecessor board (HVR-1120) for the IR, looks that's not the
>> case. I would like to help to get the card supported but unless
>> there's a procedure documented somewhere showing what to do I guess I
>> don't qualify for the job (don't even understand what you meant by
>> "TLC"). But if I can help somehow, I would be glad to do it.
>
> It is the same layout as the 1120 (I cheated and just looked at the
> schematic), but despite some user having submitted the patch, it
> wasn't working at least for me.  Hence, the fact that you see code in
(Continue reading)

Jarod Wilson | 17 Feb 2011 15:18
Picon
Favicon

Re: IR for remote control not working for Hauppauge WinTV-HVR-1150 (SAA7134)

On Thu, Feb 17, 2011 at 09:24:27AM -0200, Fernando Laudares Camargos wrote:
> Ok, Devin.
> 
> I'm not sure about how it would went but if you think it would be
> worth trying to get info about the components of the 1150 directly
> from Hauppauge, I can give them a call and see what happens.

I'm pretty sure Devin already has access to all the necessary info about
the components, and contacting someone at Hauppauge would be entirely
redundant... :)

--

-- 
Jarod Wilson
jarod <at> redhat.com

Fernando Laudares Camargos | 3 Mar 2011 14:51
Picon

Re: IR for remote control not working for Hauppauge WinTV-HVR-1150 (SAA7134)

Hello Jarod and Devin,

as I said previously I don't qualify for driver development nor I'm
familiar with design of underlying hardware but anyway I followed some
tips from your posts trying to at least bring more information to the
discussion.

I've made some changes in the saa7134-input.c and saa7134-cards.c
files from the latest v4l-dvb tree as per the .diff files attached;
also attached is the output of dmesg with debug flags on for the
module. Devin has warned the IR is not supported yet but I wanted to
at least try to get an input device for it under /proc :

I: Bus=0018 Vendor=0000 Product=0000 Version=0000
N: Name="i2c IR (HVR 1150)"
P: Phys=i2c-1/1-0071/ir0
S: Sysfs=/devices/virtual/rc/rc0/input4
U: Uniq=
H: Handlers=kbd event4
B: EV=100003
B: KEY=100fc312 214a802 0 0 0 0 18000 41a8 4801 9e1680 0 0 10000ffc

Of course, it did not worked since the device is probably not a i2c
remote as was HVR-1110. That makes me wondering what have changed at
the IR level from the HVR-1110 to 1120 and then to 1150 and if the
remote control is working for anybody having the 1120 board.

I would be glad to make any tests you judge that could be helpful.

Regards,
(Continue reading)

Devin Heitmueller | 3 Mar 2011 15:51
Gravatar

Re: IR for remote control not working for Hauppauge WinTV-HVR-1150 (SAA7134)

On Thu, Mar 3, 2011 at 8:51 AM, Fernando Laudares Camargos
<fernando.laudares.camargos <at> gmail.com> wrote:
> Of course, it did not worked since the device is probably not a i2c
> remote as was HVR-1110. That makes me wondering what have changed at
> the IR level from the HVR-1110 to 1120 and then to 1150 and if the
> remote control is working for anybody having the 1120 board.

From a design standpoint, it is identical to the 1120 (IR receiver
diode tied directly to a GPIO).  But as I said in my previous email, I
believe that the code is broken for the 1120 as well.

So the upside is that once you fix it for the 1150, the 1120 should
start working properly again as well.  The downside is that you will
have to actually debug the IRQ handler for the GPIO edge timing to
find the underlying bug.  This isn't something as easy as just adding
a couple of lines somewhere for the board profile.

Devin

--

-- 
Devin J. Heitmueller - Kernel Labs
http://www.kernellabs.com

Gmane