kernelnewbies.kernelnewbies.org archive mirror
 help / color / mirror / Atom feed
* Missing Key-codes from input.h file.
@ 2012-06-25 13:22 Dharam Kumar
  2012-06-25 17:17 ` anish kumar
  0 siblings, 1 reply; 10+ messages in thread
From: Dharam Kumar @ 2012-06-25 13:22 UTC (permalink / raw)
  To: kernelnewbies

Hi,
I'm working on a module which is an input device and hence it needs to
report certain key events.

While browsing through the <linux/input.h>, I did find most of the
key-codes(which I need to use)already defined but not all.

Few of the KEY_xxx which i could not find are:

a.) A Key for going to the previous channel.
b.) Keys for Moving upper-right, lower-right, upper-left and lower-left
direction(probably a GUI(grid of icons),where you move diagonally)
d.) A key for Subpicture (this 'subpicture' key is defined in CEA-931C).

Does anybody have any idea about this?

-
Dharam
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20120625/423c67ad/attachment.html 

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Missing Key-codes from input.h file.
  2012-06-25 13:22 Missing Key-codes from input.h file Dharam Kumar
@ 2012-06-25 17:17 ` anish kumar
  2012-06-25 17:54   ` Dharam Kumar
  0 siblings, 1 reply; 10+ messages in thread
From: anish kumar @ 2012-06-25 17:17 UTC (permalink / raw)
  To: kernelnewbies

On Mon, 2012-06-25 at 18:52 +0530, Dharam Kumar wrote:
> Hi,
> I'm working on a module which is an input device and hence it needs to
> report certain key events.
> 
> While browsing through the <linux/input.h>, I did find most of the
> key-codes(which I need to use)already defined but not all.
> 
> 
> Few of the KEY_xxx which i could not find are:
> 
> 
> a.) A Key for going to the previous channel.
> b.) Keys for Moving upper-right, lower-right, upper-left and
> lower-left direction(probably a GUI(grid of icons),where you move
> diagonally)
> d.) A key for Subpicture (this 'subpicture' key is deeined in
> CEA-931C).
I think you are interested in the user space implementation of 
the keys reported by the input subsystem of kernel.
Keys reported by the driver->input subsystem->reported to user space.

I am not sure about linux way of reporting keys but in android the key
is reported at a particular sysfs file and this sysfs file is read by
eventhub.cpp.This file in turn is responsible for sending the events
to particular application and it is the responsibility of the
application how they interpret this keys.It can interpret events by
moving diagonally a pointer/touch or going left/right.

Not sure if this is what you are interested in but would have been
better if you had described the problem in more detail.
> 
> 
> Does anybody have any idea about this?
> 
> 
> -
> Dharam
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies at kernelnewbies.org
> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Missing Key-codes from input.h file.
  2012-06-25 17:17 ` anish kumar
@ 2012-06-25 17:54   ` Dharam Kumar
  2012-06-26  6:32     ` anish kumar
  0 siblings, 1 reply; 10+ messages in thread
From: Dharam Kumar @ 2012-06-25 17:54 UTC (permalink / raw)
  To: kernelnewbies

On Mon, Jun 25, 2012 at 10:47 PM, anish kumar
<anish198519851985@gmail.com> wrote:
> On Mon, 2012-06-25 at 18:52 +0530, Dharam Kumar wrote:
>> Hi,
>> I'm working on a module which is an input device and hence it needs to
>> report certain key events.
>>
>> While browsing through the <linux/input.h>, I did find most of the
>> key-codes(which I need to use)already defined but not all.
>>
>>
>> Few of the KEY_xxx which i could not find are:
>>
>>
>> a.) A Key for going to the previous channel.
>> b.) Keys for Moving upper-right, lower-right, upper-left and
>> lower-left direction(probably a GUI(grid of icons),where you move
>> diagonally)
>> d.) A key for Subpicture (this 'subpicture' key is deeined in
>> CEA-931C).
> I think you are interested in the user space implementation of
> the keys reported by the input subsystem of kernel.
> Keys reported by the driver->input subsystem->reported to user space.
>
> I am not sure about linux way of reporting keys but in android the key
> is reported at a particular sysfs file and this sysfs file is read by
> eventhub.cpp.This file in turn is responsible for sending the events
> to particular application and it is the responsibility of the
> application how they interpret this keys.It can interpret events by
> moving diagonally a pointer/touch or going left/right.
>
Thanks Anish ! To be clear, i just want to know the key-code
which will be used by the Input Subsytem of the Kernel.

For example, in <linux/input.h> file you will find a lot of #defines
like the below,mapping different kind of key events to some key-code
or value :
#define KEY_UP                 0xXYZ
#define KEY_DOWN         0xABC and so on...

Now, I'm looking for key events like:
#define KEY_PREVIOUSCHANNEL   <???>
#define KEY_RIGHTUP                         <???>
#define kEY_RIGHTLEFT                     <???>
#define kEY_SUBPICTURE                 <???> and so on...

You are probably right , that Userspace reads the key-events/key-codes
from certain sysfs entries exported by Android Linux Kernel and these
key-codes/events will be handled accordingly by the respective
Framework/Application. But  I'm really not interested in how and what
Userspace gets from Kernel.
I'm interested in what values the Kernel or input subsystem will
provide to such keys..

> Not sure if this is what you are interested in but would have been
> better if you had described the problem in more detail.
>>
>>
>> Does anybody have any idea about this?
>>
>>
>> -
>> Dharam
>> _______________________________________________
>> Kernelnewbies mailing list
>> Kernelnewbies at kernelnewbies.org
>> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>
>

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Missing Key-codes from input.h file.
  2012-06-25 17:54   ` Dharam Kumar
@ 2012-06-26  6:32     ` anish kumar
  2012-06-26  6:47       ` Dharam Kumar
  0 siblings, 1 reply; 10+ messages in thread
From: anish kumar @ 2012-06-26  6:32 UTC (permalink / raw)
  To: kernelnewbies

On Mon, 2012-06-25 at 23:24 +0530, Dharam Kumar wrote:
> On Mon, Jun 25, 2012 at 10:47 PM, anish kumar
> <anish198519851985@gmail.com> wrote:
> > On Mon, 2012-06-25 at 18:52 +0530, Dharam Kumar wrote:
> >> Hi,
> >> I'm working on a module which is an input device and hence it needs to
> >> report certain key events.
> >>
> >> While browsing through the <linux/input.h>, I did find most of the
> >> key-codes(which I need to use)already defined but not all.
> >>
> >>
> >> Few of the KEY_xxx which i could not find are:
> >>
> >>
> >> a.) A Key for going to the previous channel.
> >> b.) Keys for Moving upper-right, lower-right, upper-left and
> >> lower-left direction(probably a GUI(grid of icons),where you move
> >> diagonally)
> >> d.) A key for Subpicture (this 'subpicture' key is deeined in
> >> CEA-931C).
> > I think you are interested in the user space implementation of
> > the keys reported by the input subsystem of kernel.
> > Keys reported by the driver->input subsystem->reported to user space.
> >
> > I am not sure about linux way of reporting keys but in android the key
> > is reported at a particular sysfs file and this sysfs file is read by
> > eventhub.cpp.This file in turn is responsible for sending the events
> > to particular application and it is the responsibility of the
> > application how they interpret this keys.It can interpret events by
> > moving diagonally a pointer/touch or going left/right.
> >
> Thanks Anish ! To be clear, i just want to know the key-code
> which will be used by the Input Subsytem of the Kernel.
> 
> For example, in <linux/input.h> file you will find a lot of #defines
> like the below,mapping different kind of key events to some key-code
> or value :
> #define KEY_UP                 0xXYZ
> #define KEY_DOWN         0xABC and so on...
> 
> Now, I'm looking for key events like:
> #define KEY_PREVIOUSCHANNEL   <???>
> #define KEY_RIGHTUP                         <???>
> #define kEY_RIGHTLEFT                     <???>
> #define kEY_SUBPICTURE                 <???> and so on...
> 
> You are probably right , that Userspace reads the key-events/key-codes
> from certain sysfs entries exported by Android Linux Kernel and these
> key-codes/events will be handled accordingly by the respective
> Framework/Application. But  I'm really not interested in how and what
> Userspace gets from Kernel.
> I'm interested in what values the Kernel or input subsystem will
> provide to such keys..
Do you have such keys in your device KEY_RIGHTUP?

> > Not sure if this is what you are interested in but would have been
> > better if you had described the problem in more detail.
> >>
> >>
> >> Does anybody have any idea about this?
> >>
> >>
> >> -
> >> Dharam
> >> _______________________________________________
> >> Kernelnewbies mailing list
> >> Kernelnewbies at kernelnewbies.org
> >> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
> >
> >

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Missing Key-codes from input.h file.
  2012-06-26  6:32     ` anish kumar
@ 2012-06-26  6:47       ` Dharam Kumar
  2012-06-26  7:43         ` Matthias Brugger
  0 siblings, 1 reply; 10+ messages in thread
From: Dharam Kumar @ 2012-06-26  6:47 UTC (permalink / raw)
  To: kernelnewbies

On Tue, Jun 26, 2012 at 12:02 PM, anish kumar
<anish198519851985@gmail.com> wrote:
> On Mon, 2012-06-25 at 23:24 +0530, Dharam Kumar wrote:
>> On Mon, Jun 25, 2012 at 10:47 PM, anish kumar
>> <anish198519851985@gmail.com> wrote:
>> > On Mon, 2012-06-25 at 18:52 +0530, Dharam Kumar wrote:
>> >> Hi,
>> >> I'm working on a module which is an input device and hence it needs to
>> >> report certain key events.
>> >>
>> >> While browsing through the <linux/input.h>, I did find most of the
>> >> key-codes(which I need to use)already defined but not all.
>> >>
>> >>
>> >> Few of the KEY_xxx which i could not find are:
>> >>
>> >>
>> >> a.) A Key for going to the previous channel.
>> >> b.) Keys for Moving upper-right, lower-right, upper-left and
>> >> lower-left direction(probably a GUI(grid of icons),where you move
>> >> diagonally)
>> >> d.) A key for Subpicture (this 'subpicture' key is deeined in
>> >> CEA-931C).
>> > I think you are interested in the user space implementation of
>> > the keys reported by the input subsystem of kernel.
>> > Keys reported by the driver->input subsystem->reported to user space.
>> >
>> > I am not sure about linux way of reporting keys but in android the key
>> > is reported at a particular sysfs file and this sysfs file is read by
>> > eventhub.cpp.This file in turn is responsible for sending the events
>> > to particular application and it is the responsibility of the
>> > application how they interpret this keys.It can interpret events by
>> > moving diagonally a pointer/touch or going left/right.
>> >
>> Thanks Anish ! To be clear, i just want to know the key-code
>> which will be used by the Input Subsytem of the Kernel.
>>
>> For example, in <linux/input.h> file you will find a lot of #defines
>> like the below,mapping different kind of key events to some key-code
>> or value :
>> #define KEY_UP ? ? ? ? ? ? ? ? 0xXYZ
>> #define KEY_DOWN ? ? ? ? 0xABC and so on...
>>
>> Now, I'm looking for key events like:
>> #define KEY_PREVIOUSCHANNEL ? <???>
>> #define KEY_RIGHTUP ? ? ? ? ? ? ? ? ? ? ? ? <???>
>> #define kEY_RIGHTLEFT ? ? ? ? ? ? ? ? ? ? <???>
>> #define kEY_SUBPICTURE ? ? ? ? ? ? ? ? <???> and so on...
>>
>> You are probably right , that Userspace reads the key-events/key-codes
>> from certain sysfs entries exported by Android Linux Kernel and these
>> key-codes/events will be handled accordingly by the respective
>> Framework/Application. But ?I'm really not interested in how and what
>> Userspace gets from Kernel.
>> I'm interested in what values the Kernel or input subsystem will
>> provide to such keys..
> Do you have such keys in your device KEY_RIGHTUP?
>
Yes, my device is supposed to support such keys:
RIGHTUP --> moves cursor upper-right direction.
RIGHTDOWN ---> moves cursor lower-right direction.
and similar keys for upper-left and lower-left cursor direction.
Sadly, I could not find any #define in input.h file for such key events.
>> > Not sure if this is what you are interested in but would have been
>> > better if you had described the problem in more detail.
>> >>
>> >>
>> >> Does anybody have any idea about this?
>> >>
>> >>
>> >> -
>> >> Dharam
>> >> _______________________________________________
>> >> Kernelnewbies mailing list
>> >> Kernelnewbies at kernelnewbies.org
>> >> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>> >
>> >
>
>

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Missing Key-codes from input.h file.
  2012-06-26  6:47       ` Dharam Kumar
@ 2012-06-26  7:43         ` Matthias Brugger
  2012-06-26  8:00           ` anish kumar
  2012-06-27  5:50           ` Dharam Kumar
  0 siblings, 2 replies; 10+ messages in thread
From: Matthias Brugger @ 2012-06-26  7:43 UTC (permalink / raw)
  To: kernelnewbies

On 06/26/2012 08:47 AM, Dharam Kumar wrote:
> On Tue, Jun 26, 2012 at 12:02 PM, anish kumar
> <anish198519851985@gmail.com> wrote:
>> On Mon, 2012-06-25 at 23:24 +0530, Dharam Kumar wrote:
>>> On Mon, Jun 25, 2012 at 10:47 PM, anish kumar
>>> <anish198519851985@gmail.com> wrote:
>>>> On Mon, 2012-06-25 at 18:52 +0530, Dharam Kumar wrote:
>>>>> Hi,
>>>>> I'm working on a module which is an input device and hence it needs to
>>>>> report certain key events.
>>>>>
>>>>> While browsing through the <linux/input.h>, I did find most of the
>>>>> key-codes(which I need to use)already defined but not all.
>>>>>
>>>>>
>>>>> Few of the KEY_xxx which i could not find are:
>>>>>
>>>>>
>>>>> a.) A Key for going to the previous channel.
>>>>> b.) Keys for Moving upper-right, lower-right, upper-left and
>>>>> lower-left direction(probably a GUI(grid of icons),where you move
>>>>> diagonally)
>>>>> d.) A key for Subpicture (this 'subpicture' key is deeined in
>>>>> CEA-931C).
>>>> I think you are interested in the user space implementation of
>>>> the keys reported by the input subsystem of kernel.
>>>> Keys reported by the driver->input subsystem->reported to user space.
>>>>
>>>> I am not sure about linux way of reporting keys but in android the key
>>>> is reported at a particular sysfs file and this sysfs file is read by
>>>> eventhub.cpp.This file in turn is responsible for sending the events
>>>> to particular application and it is the responsibility of the
>>>> application how they interpret this keys.It can interpret events by
>>>> moving diagonally a pointer/touch or going left/right.
>>>>
>>> Thanks Anish ! To be clear, i just want to know the key-code
>>> which will be used by the Input Subsytem of the Kernel.
>>>
>>> For example, in <linux/input.h> file you will find a lot of #defines
>>> like the below,mapping different kind of key events to some key-code
>>> or value :
>>> #define KEY_UP                 0xXYZ
>>> #define KEY_DOWN         0xABC and so on...
>>>
>>> Now, I'm looking for key events like:
>>> #define KEY_PREVIOUSCHANNEL   <???>
>>> #define KEY_RIGHTUP                         <???>
>>> #define kEY_RIGHTLEFT                     <???>
>>> #define kEY_SUBPICTURE                 <???> and so on...
>>>
>>> You are probably right , that Userspace reads the key-events/key-codes
>>> from certain sysfs entries exported by Android Linux Kernel and these
>>> key-codes/events will be handled accordingly by the respective
>>> Framework/Application. But  I'm really not interested in how and what
>>> Userspace gets from Kernel.
>>> I'm interested in what values the Kernel or input subsystem will
>>> provide to such keys..
>> Do you have such keys in your device KEY_RIGHTUP?
>>
> Yes, my device is supposed to support such keys:
> RIGHTUP --> moves cursor upper-right direction.
> RIGHTDOWN ---> moves cursor lower-right direction.
> and similar keys for upper-left and lower-left cursor direction.
> Sadly, I could not find any #define in input.h file for such key events.

 From your response I interpret that you have some kind of custom 
key-pad, or anything similar which is not a standard keyboard.

If there are no such defines in the Kernel, it's probably because no one 
has had the need for them up to now.

I think the implementation should be done as Anish described beforehand. 
Anyway you can add some defines to your Kernel if this is a requirement 
for you.

Regards,
Matthias

>>>> Not sure if this is what you are interested in but would have been
>>>> better if you had described the problem in more detail.
>>>>>
>>>>>
>>>>> Does anybody have any idea about this?
>>>>>
>>>>>
>>>>> -
>>>>> Dharam
>>>>> _______________________________________________
>>>>> Kernelnewbies mailing list
>>>>> Kernelnewbies at kernelnewbies.org
>>>>> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>>>>
>>>>
>>
>>
>
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies at kernelnewbies.org
> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Missing Key-codes from input.h file.
  2012-06-26  7:43         ` Matthias Brugger
@ 2012-06-26  8:00           ` anish kumar
  2012-06-27  6:06             ` Dharam Kumar
  2012-06-27  5:50           ` Dharam Kumar
  1 sibling, 1 reply; 10+ messages in thread
From: anish kumar @ 2012-06-26  8:00 UTC (permalink / raw)
  To: kernelnewbies

On Tue, 2012-06-26 at 09:43 +0200, Matthias Brugger wrote:
> On 06/26/2012 08:47 AM, Dharam Kumar wrote:
> > On Tue, Jun 26, 2012 at 12:02 PM, anish kumar
> > <anish198519851985@gmail.com> wrote:
> >> On Mon, 2012-06-25 at 23:24 +0530, Dharam Kumar wrote:
> >>> On Mon, Jun 25, 2012 at 10:47 PM, anish kumar
> >>> <anish198519851985@gmail.com> wrote:
> >>>> On Mon, 2012-06-25 at 18:52 +0530, Dharam Kumar wrote:
> >>>>> Hi,
> >>>>> I'm working on a module which is an input device and hence it needs to
> >>>>> report certain key events.
> >>>>>
> >>>>> While browsing through the <linux/input.h>, I did find most of the
> >>>>> key-codes(which I need to use)already defined but not all.
> >>>>>
> >>>>>
> >>>>> Few of the KEY_xxx which i could not find are:
> >>>>>
> >>>>>
> >>>>> a.) A Key for going to the previous channel.
> >>>>> b.) Keys for Moving upper-right, lower-right, upper-left and
> >>>>> lower-left direction(probably a GUI(grid of icons),where you move
> >>>>> diagonally)
> >>>>> d.) A key for Subpicture (this 'subpicture' key is deeined in
> >>>>> CEA-931C).
> >>>> I think you are interested in the user space implementation of
> >>>> the keys reported by the input subsystem of kernel.
> >>>> Keys reported by the driver->input subsystem->reported to user space.
> >>>>
> >>>> I am not sure about linux way of reporting keys but in android the key
> >>>> is reported at a particular sysfs file and this sysfs file is read by
> >>>> eventhub.cpp.This file in turn is responsible for sending the events
> >>>> to particular application and it is the responsibility of the
> >>>> application how they interpret this keys.It can interpret events by
> >>>> moving diagonally a pointer/touch or going left/right.
> >>>>
> >>> Thanks Anish ! To be clear, i just want to know the key-code
> >>> which will be used by the Input Subsytem of the Kernel.
> >>>
> >>> For example, in <linux/input.h> file you will find a lot of #defines
> >>> like the below,mapping different kind of key events to some key-code
> >>> or value :
> >>> #define KEY_UP                 0xXYZ
> >>> #define KEY_DOWN         0xABC and so on...
> >>>
> >>> Now, I'm looking for key events like:
> >>> #define KEY_PREVIOUSCHANNEL   <???>
> >>> #define KEY_RIGHTUP                         <???>
> >>> #define kEY_RIGHTLEFT                     <???>
> >>> #define kEY_SUBPICTURE                 <???> and so on...
> >>>
> >>> You are probably right , that Userspace reads the key-events/key-codes
> >>> from certain sysfs entries exported by Android Linux Kernel and these
> >>> key-codes/events will be handled accordingly by the respective
> >>> Framework/Application. But  I'm really not interested in how and what
> >>> Userspace gets from Kernel.
> >>> I'm interested in what values the Kernel or input subsystem will
> >>> provide to such keys..
> >> Do you have such keys in your device KEY_RIGHTUP?
> >>
> > Yes, my device is supposed to support such keys:
> > RIGHTUP --> moves cursor upper-right direction.
> > RIGHTDOWN ---> moves cursor lower-right direction.
> > and similar keys for upper-left and lower-left cursor direction.
> > Sadly, I could not find any #define in input.h file for such key events.
> 
>  From your response I interpret that you have some kind of custom 
> key-pad, or anything similar which is not a standard keyboard.
> 
> If there are no such defines in the Kernel, it's probably because no one 
> has had the need for them up to now.
> 
> I think the implementation should be done as Anish described beforehand. 
> Anyway you can add some defines to your Kernel if this is a requirement 
and probably submit your first patch to the kernel but I am not clear
about the policy regarding adding new keys in the kernel.However sending
the patch would be better than speculating.
> for you.
> 
> Regards,
> Matthias
> 
> >>>> Not sure if this is what you are interested in but would have been
> >>>> better if you had described the problem in more detail.
> >>>>>
> >>>>>
> >>>>> Does anybody have any idea about this?
> >>>>>
> >>>>>
> >>>>> -
> >>>>> Dharam
> >>>>> _______________________________________________
> >>>>> Kernelnewbies mailing list
> >>>>> Kernelnewbies at kernelnewbies.org
> >>>>> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
> >>>>
> >>>>
> >>
> >>
> >
> > _______________________________________________
> > Kernelnewbies mailing list
> > Kernelnewbies at kernelnewbies.org
> > http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
> >
> 
> 

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Missing Key-codes from input.h file.
  2012-06-26  7:43         ` Matthias Brugger
  2012-06-26  8:00           ` anish kumar
@ 2012-06-27  5:50           ` Dharam Kumar
  2012-06-27 11:49             ` anish kumar
  1 sibling, 1 reply; 10+ messages in thread
From: Dharam Kumar @ 2012-06-27  5:50 UTC (permalink / raw)
  To: kernelnewbies

On Tue, Jun 26, 2012 at 1:13 PM, Matthias Brugger
<matthias.bgg@googlemail.com> wrote:
> On 06/26/2012 08:47 AM, Dharam Kumar wrote:
>>
>> On Tue, Jun 26, 2012 at 12:02 PM, anish kumar
>> <anish198519851985@gmail.com> wrote:
>>>
>>> On Mon, 2012-06-25 at 23:24 +0530, Dharam Kumar wrote:
>>>>
>>>> On Mon, Jun 25, 2012 at 10:47 PM, anish kumar
>>>> <anish198519851985@gmail.com> wrote:
>>>>>
>>>>> On Mon, 2012-06-25 at 18:52 +0530, Dharam Kumar wrote:
>>>>>>
>>>>>> Hi,
>>>>>> I'm working on a module which is an input device and hence it needs to
>>>>>> report certain key events.
>>>>>>
>>>>>> While browsing through the <linux/input.h>, I did find most of the
>>>>>> key-codes(which I need to use)already defined but not all.
>>>>>>
>>>>>>
>>>>>> Few of the KEY_xxx which i could not find are:
>>>>>>
>>>>>>
>>>>>> a.) A Key for going to the previous channel.
>>>>>> b.) Keys for Moving upper-right, lower-right, upper-left and
>>>>>> lower-left direction(probably a GUI(grid of icons),where you move
>>>>>> diagonally)
>>>>>> d.) A key for Subpicture (this 'subpicture' key is deeined in
>>>>>> CEA-931C).
>>>>>
>>>>> I think you are interested in the user space implementation of
>>>>> the keys reported by the input subsystem of kernel.
>>>>> Keys reported by the driver->input subsystem->reported to user space.
>>>>>
>>>>> I am not sure about linux way of reporting keys but in android the key
>>>>> is reported at a particular sysfs file and this sysfs file is read by
>>>>> eventhub.cpp.This file in turn is responsible for sending the events
>>>>> to particular application and it is the responsibility of the
>>>>> application how they interpret this keys.It can interpret events by
>>>>> moving diagonally a pointer/touch or going left/right.
>>>>>
>>>> Thanks Anish ! To be clear, i just want to know the key-code
>>>> which will be used by the Input Subsytem of the Kernel.
>>>>
>>>> For example, in <linux/input.h> file you will find a lot of #defines
>>>> like the below,mapping different kind of key events to some key-code
>>>> or value :
>>>> #define KEY_UP ? ? ? ? ? ? ? ? 0xXYZ
>>>> #define KEY_DOWN ? ? ? ? 0xABC and so on...
>>>>
>>>> Now, I'm looking for key events like:
>>>> #define KEY_PREVIOUSCHANNEL ? <???>
>>>> #define KEY_RIGHTUP ? ? ? ? ? ? ? ? ? ? ? ? <???>
>>>> #define kEY_RIGHTLEFT ? ? ? ? ? ? ? ? ? ? <???>
>>>> #define kEY_SUBPICTURE ? ? ? ? ? ? ? ? <???> and so on...
>>>>
>>>> You are probably right , that Userspace reads the key-events/key-codes
>>>> from certain sysfs entries exported by Android Linux Kernel and these
>>>> key-codes/events will be handled accordingly by the respective
>>>> Framework/Application. But ?I'm really not interested in how and what
>>>> Userspace gets from Kernel.
>>>> I'm interested in what values the Kernel or input subsystem will
>>>> provide to such keys..
>>>
>>> Do you have such keys in your device KEY_RIGHTUP?
>>>
>> Yes, my device is supposed to support such keys:
>> RIGHTUP --> moves cursor upper-right direction.
>> RIGHTDOWN ---> moves cursor lower-right direction.
>> and similar keys for upper-left and lower-left cursor direction.
>> Sadly, I could not find any #define in input.h file for such key events.
>
>
> From your response I interpret that you have some kind of custom key-pad, or
> anything similar which is not a standard keyboard.
>
You are right that it is not a standard keyboard. In fact, these are
Remote Controller(or Remote Control) keys as  defined in MHL
Specifications(www.mhltech.org).
Now, MHL Specs is closely related to HDMI specifications.Hence, my
assumption is that such keys might be the part of HDMI-CEC
specifications and would have been picked from there to MHL Specs.

Although the current MHL specs does not shed much light on how these
'missing' Remote Control Keys will be handled by the device, what is
still notable that these remote controller keys(if 'they' are part of
HDMI-CEC standards) has not been added to Linux Kernel.
As you said, it is highly possible that nobody had encountered the use
of these keys. In any case, I need to dig more.

Thanks for your response !

> If there are no such defines in the Kernel, it's probably because no one has
> had the need for them up to now.
>
> I think the implementation should be done as Anish described beforehand.
> Anyway you can add some defines to your Kernel if this is a requirement for
> you.
>
> Regards,
> Matthias
>
>
>>>>> Not sure if this is what you are interested in but would have been
>>>>> better if you had described the problem in more detail.
>>>>>>
>>>>>>
>>>>>>
>>>>>> Does anybody have any idea about this?
>>>>>>
>>>>>>
>>>>>> -
>>>>>> Dharam
>>>>>> _______________________________________________
>>>>>> Kernelnewbies mailing list
>>>>>> Kernelnewbies at kernelnewbies.org
>>>>>> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>>>>>
>>>>>
>>>>>
>>>
>>>
>>
>> _______________________________________________
>> Kernelnewbies mailing list
>> Kernelnewbies at kernelnewbies.org
>> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>>
>
>

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Missing Key-codes from input.h file.
  2012-06-26  8:00           ` anish kumar
@ 2012-06-27  6:06             ` Dharam Kumar
  0 siblings, 0 replies; 10+ messages in thread
From: Dharam Kumar @ 2012-06-27  6:06 UTC (permalink / raw)
  To: kernelnewbies

On Tue, Jun 26, 2012 at 1:30 PM, anish kumar
<anish198519851985@gmail.com> wrote:
> On Tue, 2012-06-26 at 09:43 +0200, Matthias Brugger wrote:
>> On 06/26/2012 08:47 AM, Dharam Kumar wrote:
>> > On Tue, Jun 26, 2012 at 12:02 PM, anish kumar
>> > <anish198519851985@gmail.com> wrote:
>> >> On Mon, 2012-06-25 at 23:24 +0530, Dharam Kumar wrote:
>> >>> On Mon, Jun 25, 2012 at 10:47 PM, anish kumar
>> >>> <anish198519851985@gmail.com> wrote:
>> >>>> On Mon, 2012-06-25 at 18:52 +0530, Dharam Kumar wrote:
>> >>>>> Hi,
>> >>>>> I'm working on a module which is an input device and hence it needs to
>> >>>>> report certain key events.
>> >>>>>
>> >>>>> While browsing through the <linux/input.h>, I did find most of the
>> >>>>> key-codes(which I need to use)already defined but not all.
>> >>>>>
>> >>>>>
>> >>>>> Few of the KEY_xxx which i could not find are:
>> >>>>>
>> >>>>>
>> >>>>> a.) A Key for going to the previous channel.
>> >>>>> b.) Keys for Moving upper-right, lower-right, upper-left and
>> >>>>> lower-left direction(probably a GUI(grid of icons),where you move
>> >>>>> diagonally)
>> >>>>> d.) A key for Subpicture (this 'subpicture' key is deeined in
>> >>>>> CEA-931C).
>> >>>> I think you are interested in the user space implementation of
>> >>>> the keys reported by the input subsystem of kernel.
>> >>>> Keys reported by the driver->input subsystem->reported to user space.
>> >>>>
>> >>>> I am not sure about linux way of reporting keys but in android the key
>> >>>> is reported at a particular sysfs file and this sysfs file is read by
>> >>>> eventhub.cpp.This file in turn is responsible for sending the events
>> >>>> to particular application and it is the responsibility of the
>> >>>> application how they interpret this keys.It can interpret events by
>> >>>> moving diagonally a pointer/touch or going left/right.
>> >>>>
>> >>> Thanks Anish ! To be clear, i just want to know the key-code
>> >>> which will be used by the Input Subsytem of the Kernel.
>> >>>
>> >>> For example, in <linux/input.h> file you will find a lot of #defines
>> >>> like the below,mapping different kind of key events to some key-code
>> >>> or value :
>> >>> #define KEY_UP ? ? ? ? ? ? ? ? 0xXYZ
>> >>> #define KEY_DOWN ? ? ? ? 0xABC and so on...
>> >>>
>> >>> Now, I'm looking for key events like:
>> >>> #define KEY_PREVIOUSCHANNEL ? <???>
>> >>> #define KEY_RIGHTUP ? ? ? ? ? ? ? ? ? ? ? ? <???>
>> >>> #define kEY_RIGHTLEFT ? ? ? ? ? ? ? ? ? ? <???>
>> >>> #define kEY_SUBPICTURE ? ? ? ? ? ? ? ? <???> and so on...
>> >>>
>> >>> You are probably right , that Userspace reads the key-events/key-codes
>> >>> from certain sysfs entries exported by Android Linux Kernel and these
>> >>> key-codes/events will be handled accordingly by the respective
>> >>> Framework/Application. But ?I'm really not interested in how and what
>> >>> Userspace gets from Kernel.
>> >>> I'm interested in what values the Kernel or input subsystem will
>> >>> provide to such keys..
>> >> Do you have such keys in your device KEY_RIGHTUP?
>> >>
>> > Yes, my device is supposed to support such keys:
>> > RIGHTUP --> moves cursor upper-right direction.
>> > RIGHTDOWN ---> moves cursor lower-right direction.
>> > and similar keys for upper-left and lower-left cursor direction.
>> > Sadly, I could not find any #define in input.h file for such key events.
>>
>> ?From your response I interpret that you have some kind of custom
>> key-pad, or anything similar which is not a standard keyboard.
>>
>> If there are no such defines in the Kernel, it's probably because no one
>> has had the need for them up to now.
>>
>> I think the implementation should be done as Anish described beforehand.
>> Anyway you can add some defines to your Kernel if this is a requirement
> and probably submit your first patch to the kernel but I am not clear
> about the policy regarding adding new keys in the kernel.However sending
Hmm..If I do add some defines to my Kernel and submit the patch to the
Open source kernel, I need to be very clear
about how these keys will be used(which driver, use-case ,source of
these keys etc..).
I think I'm not at that stage right now..hopefully I can complete the
driver and kernel patches in some time and submit it :)

Thanks for your time and patience !!
>> for you.
>>
>> Regards,
>> Matthias
>>
>> >>>> Not sure if this is what you are interested in but would have been
>> >>>> better if you had described the problem in more detail.
>> >>>>>
>> >>>>>
>> >>>>> Does anybody have any idea about this?
>> >>>>>
>> >>>>>
>> >>>>> -
>> >>>>> Dharam
>> >>>>> _______________________________________________
>> >>>>> Kernelnewbies mailing list
>> >>>>> Kernelnewbies at kernelnewbies.org
>> >>>>> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>> >>>>
>> >>>>
>> >>
>> >>
>> >
>> > _______________________________________________
>> > Kernelnewbies mailing list
>> > Kernelnewbies at kernelnewbies.org
>> > http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>> >
>>
>>
>
>

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Missing Key-codes from input.h file.
  2012-06-27  5:50           ` Dharam Kumar
@ 2012-06-27 11:49             ` anish kumar
  0 siblings, 0 replies; 10+ messages in thread
From: anish kumar @ 2012-06-27 11:49 UTC (permalink / raw)
  To: kernelnewbies

On Wed, 2012-06-27 at 11:20 +0530, Dharam Kumar wrote:
> On Tue, Jun 26, 2012 at 1:13 PM, Matthias Brugger
> <matthias.bgg@googlemail.com> wrote:
> > On 06/26/2012 08:47 AM, Dharam Kumar wrote:
> >>
> >> On Tue, Jun 26, 2012 at 12:02 PM, anish kumar
> >> <anish198519851985@gmail.com> wrote:
> >>>
> >>> On Mon, 2012-06-25 at 23:24 +0530, Dharam Kumar wrote:
> >>>>
> >>>> On Mon, Jun 25, 2012 at 10:47 PM, anish kumar
> >>>> <anish198519851985@gmail.com> wrote:
> >>>>>
> >>>>> On Mon, 2012-06-25 at 18:52 +0530, Dharam Kumar wrote:
> >>>>>>
> >>>>>> Hi,
> >>>>>> I'm working on a module which is an input device and hence it needs to
> >>>>>> report certain key events.
> >>>>>>
> >>>>>> While browsing through the <linux/input.h>, I did find most of the
> >>>>>> key-codes(which I need to use)already defined but not all.
> >>>>>>
> >>>>>>
> >>>>>> Few of the KEY_xxx which i could not find are:
> >>>>>>
> >>>>>>
> >>>>>> a.) A Key for going to the previous channel.
> >>>>>> b.) Keys for Moving upper-right, lower-right, upper-left and
> >>>>>> lower-left direction(probably a GUI(grid of icons),where you move
> >>>>>> diagonally)
> >>>>>> d.) A key for Subpicture (this 'subpicture' key is deeined in
> >>>>>> CEA-931C).
> >>>>>
> >>>>> I think you are interested in the user space implementation of
> >>>>> the keys reported by the input subsystem of kernel.
> >>>>> Keys reported by the driver->input subsystem->reported to user space.
> >>>>>
> >>>>> I am not sure about linux way of reporting keys but in android the key
> >>>>> is reported at a particular sysfs file and this sysfs file is read by
> >>>>> eventhub.cpp.This file in turn is responsible for sending the events
> >>>>> to particular application and it is the responsibility of the
> >>>>> application how they interpret this keys.It can interpret events by
> >>>>> moving diagonally a pointer/touch or going left/right.
> >>>>>
> >>>> Thanks Anish ! To be clear, i just want to know the key-code
> >>>> which will be used by the Input Subsytem of the Kernel.
> >>>>
> >>>> For example, in <linux/input.h> file you will find a lot of #defines
> >>>> like the below,mapping different kind of key events to some key-code
> >>>> or value :
> >>>> #define KEY_UP                 0xXYZ
> >>>> #define KEY_DOWN         0xABC and so on...
> >>>>
> >>>> Now, I'm looking for key events like:
> >>>> #define KEY_PREVIOUSCHANNEL   <???>
> >>>> #define KEY_RIGHTUP                         <???>
> >>>> #define kEY_RIGHTLEFT                     <???>
> >>>> #define kEY_SUBPICTURE                 <???> and so on...
> >>>>
> >>>> You are probably right , that Userspace reads the key-events/key-codes
> >>>> from certain sysfs entries exported by Android Linux Kernel and these
> >>>> key-codes/events will be handled accordingly by the respective
> >>>> Framework/Application. But  I'm really not interested in how and what
> >>>> Userspace gets from Kernel.
> >>>> I'm interested in what values the Kernel or input subsystem will
> >>>> provide to such keys..
> >>>
> >>> Do you have such keys in your device KEY_RIGHTUP?
> >>>
> >> Yes, my device is supposed to support such keys:
> >> RIGHTUP --> moves cursor upper-right direction.
> >> RIGHTDOWN ---> moves cursor lower-right direction.
> >> and similar keys for upper-left and lower-left cursor direction.
> >> Sadly, I could not find any #define in input.h file for such key events.
> >
> >
> > From your response I interpret that you have some kind of custom key-pad, or
> > anything similar which is not a standard keyboard.
> >
> You are right that it is not a standard keyboard. In fact, these are
> Remote Controller(or Remote Control) keys as  defined in MHL
> Specifications(www.mhltech.org).
> Now, MHL Specs is closely related to HDMI specifications.Hence, my
> assumption is that such keys might be the part of HDMI-CEC
> specifications and would have been picked from there to MHL Specs.
> 
> Although the current MHL specs does not shed much light on how these
> 'missing' Remote Control Keys will be handled by the device, what is
> still notable that these remote controller keys(if 'they' are part of
> HDMI-CEC standards) has not been added to Linux Kernel.
> As you said, it is highly possible that nobody had encountered the use
case which is unlikely.You can really maximise your chances by sending
mail to LKML and V4L2 group.
> of these keys. In any case, I need to dig more.
> 
> Thanks for your response !
> 
> > If there are no such defines in the Kernel, it's probably because no one has
> > had the need for them up to now.
> >
> > I think the implementation should be done as Anish described beforehand.
> > Anyway you can add some defines to your Kernel if this is a requirement for
> > you.
> >
> > Regards,
> > Matthias
> >
> >
> >>>>> Not sure if this is what you are interested in but would have been
> >>>>> better if you had described the problem in more detail.
> >>>>>>
> >>>>>>
> >>>>>>
> >>>>>> Does anybody have any idea about this?
> >>>>>>
> >>>>>>
> >>>>>> -
> >>>>>> Dharam
> >>>>>> _______________________________________________
> >>>>>> Kernelnewbies mailing list
> >>>>>> Kernelnewbies at kernelnewbies.org
> >>>>>> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
> >>>>>
> >>>>>
> >>>>>
> >>>
> >>>
> >>
> >> _______________________________________________
> >> Kernelnewbies mailing list
> >> Kernelnewbies at kernelnewbies.org
> >> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
> >>
> >
> >

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2012-06-27 11:49 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-06-25 13:22 Missing Key-codes from input.h file Dharam Kumar
2012-06-25 17:17 ` anish kumar
2012-06-25 17:54   ` Dharam Kumar
2012-06-26  6:32     ` anish kumar
2012-06-26  6:47       ` Dharam Kumar
2012-06-26  7:43         ` Matthias Brugger
2012-06-26  8:00           ` anish kumar
2012-06-27  6:06             ` Dharam Kumar
2012-06-27  5:50           ` Dharam Kumar
2012-06-27 11:49             ` anish kumar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).