Re: [RFC] What are the goals for the architecture of an in-kernel IR system?

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Mauro Carvalho Chehab
Date: Friday, March 26, 2010 - 8:17 am

David Härdeman wrote:

TX is a completely different history. It has nothing to do with input event
subsystem. So, another approach should be taken for it.

I haven't seen yet a hardware decoder with such parameters, but maybe I just
don't have enough specs here to adjust them. Anyway, one simple way to avoid
resetting the hardware for every new parameter change would be to use a timer
for reset. This way, an userspace application or script that is touching on 
several parameters would just send the complete RX init sequence and
after some dozens of milliseconds, the hardware will load the new parameters.


There's an interesting discussion about bitmasks x a list of enumerated values
as a way to represent a bitmask into a series of values on sysfs,
at http://lwn.net/Articles/378219/  (see "A critical look at sysfs attribute values"
article there).

That's said, I'm starting to think that the better is to have some differentiation
there between hardware and software decoders. IMO, software decoders are better
handled with an "enabled" attribute, per software decoder, inside each irrcv.

In the case of hardware decoders, just one attribute is enough to control it. I think
it should be a bitmask parameter, but presented with their aliases, like for example:
	$cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors
	ondemand conservative performance 

This is clearly a bitmask, but it is presented as textual values, instead of a
magic number.

So, we may have
	/sys/class/irrcv/irrcv0/supported_protocols

as, for example:
	RC-5 NEC

and allow setting current_protocol as just "RC-5" or, if the hardware supports
more than one decoder at the same time, as "RC-5 NEC".

-- 

Cheers,
Mauro
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [RFC] What are the goals for the architecture of an in ..., Christoph Bartelmus, (Fri Dec 4, 4:01 pm)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Sun Dec 6, 4:46 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Mon Dec 7, 8:36 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Mon Dec 7, 4:44 pm)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Tue Dec 8, 4:17 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Tue Dec 8, 4:23 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Tue Dec 8, 4:58 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Tue Dec 8, 7:07 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Tue Dec 8, 7:13 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Tue Dec 8, 7:56 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Tue Dec 8, 8:41 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Tue Dec 8, 8:49 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Sun Dec 13, 5:14 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Tue Dec 15, 6:33 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Tue Dec 15, 7:19 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Thu Mar 25, 7:42 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Thu Mar 25, 12:00 pm)
Re: [RFC] What are the goals for the architecture of an in ..., David =?iso-8859-1?Q ..., (Fri Mar 26, 4:04 am)
Re: [RFC] What are the goals for the architecture of an in ..., David =?iso-8859-1?Q ..., (Fri Mar 26, 4:27 am)
Re: [RFC] What are the goals for the architecture of an in ..., David =?iso-8859-1?Q ..., (Fri Mar 26, 5:23 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Fri Mar 26, 7:40 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Fri Mar 26, 8:17 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Fri Mar 26, 10:22 am)
Re: [RFC] What are the goals for the architecture of an in ..., David =?iso-8859-1?Q ..., (Fri Mar 26, 12:07 pm)
Re: [RFC] What are the goals for the architecture of an in ..., David =?iso-8859-1?Q ..., (Fri Mar 26, 12:21 pm)
Re: [RFC] What are the goals for the architecture of an in ..., David =?iso-8859-1?Q ..., (Sat Mar 27, 1:27 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Sun Mar 28, 4:22 pm)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Sun Mar 28, 5:51 pm)
Re: [RFC] What are the goals for the architecture of an in ..., David =?iso-8859-1?Q ..., (Tue Mar 30, 4:01 am)
Re: [RFC] What are the goals for the architecture of an in ..., David =?iso-8859-1?Q ..., (Tue Mar 30, 4:09 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Tue Mar 30, 5:43 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Tue Mar 30, 11:01 pm)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Fri Apr 9, 6:01 am)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Fri Apr 9, 4:32 pm)
Re: [RFC] What are the goals for the architecture of an in ..., Mauro Carvalho Chehab, (Fri Apr 9, 6:01 pm)