Detecting headset button press

Ruben Leote Mendes ruben at
Thu Apr 30 01:27:36 CEST 2009

Em Qua, Abril 29, 2009 09:47, Helge Hafting escreveu:
> Ruben Leote Mendes wrote:
>> Hi,
>> I followed the Freerunner schematics and the heaset button seems to be
>> connected to EINT7/GPF7 so it seems it is possible to find out in
>> software
>> if the button is pressed.
>> What is the best way to do it?
> Check to see if it is interpreted as a normal key already.
> enlightenment can assign some actions to keys, that is how the two
> regular buttons are handled. Go into that setup, press the key and see
> if you get a keycode.  If so, you can assign an enlightenment action.
> If you want to use it outside of e, run something like "xev" to check
> what keycode is produced. Then write software to listen for it.

Thanks. I'll try that when I get my hands on a 2.5" 4-ring jack.
I currently do not own a compatible headset, but have an application
in mind that needs a push button because touchscreen is not an option.

Rúben Leote Mendes -- ruben at

More information about the community mailing list