Quote:
Originally Posted by ixtab
Some of the event devices (unfortunately not all, and probably not those that you want  ) also have symbolic names:
Code:
[root@kindle input]# ls -la
drwxr-xr-x 3 root root 160 Mar 10 18:15 .
drwxr-xr-x 16 root root 1120 Mar 11 15:15 ..
drwxr-xr-x 2 root root 100 Mar 10 18:15 by-path
crw-r----- 1 root root 13, 64 Mar 10 18:15 event0
crw-r----- 1 root root 13, 65 Mar 10 18:15 event1
crw-r----- 1 root root 13, 66 Mar 10 18:15 event2
crw-r----- 1 root root 13, 67 Mar 10 18:15 event3
crw-r----- 1 root root 13, 68 Mar 10 18:15 event4
[root@kindle input]# ls -la by-path/
drwxr-xr-x 2 root root 100 Mar 10 18:15 .
drwxr-xr-x 3 root root 160 Mar 10 18:15 ..
lrwxrwxrwx 1 root root 9 Mar 10 18:15 platform-soc-audio.1-event -> ../event1
lrwxrwxrwx 1 root root 9 Mar 10 18:15 platform-whitney-button-event -> ../event2
lrwxrwxrwx 1 root root 9 Mar 10 18:15 platform-zforce.0-event -> ../event4
Still, that would mean only figuring out what the remaining two are, instead of guessing what all 5 are.
|
I want my code to work on different firmware versions, booted from either partition, on any eInk-based kindle.
Those "by-path" names (such as "whitney") look rather device-specific. For all we *should* care, that HOME button on a touch is just a keyboard button.
I am a firm believer in the
KISS principle:
http://en.wikipedia.org/wiki/KISS_principle
But we also need to follow the
Einstein principle too:
http://c2.com/cgi/wiki?EinsteinPrinciple
Perhaps I just want my code to be
TOO simple.