From 0dfed56a13ed1e898759833f02daf36404043619 Mon Sep 17 00:00:00 2001 From: Andrew Sutherland Date: Sun, 17 Jun 2012 16:26:33 -0500 Subject: [PATCH] passion: update input/key configs Change-Id: I7295976fef693ce31f8c9b416bee7f8bf14543b2 --- h2w_headset.kcm | 15 + h2w_headset.kl | 14 + mahimahi-keypad.kcm | 531 +--------------------------------- mahimahi-keypad.kl | 25 +- mahimahi-nav.idc | 20 +- mahimahi-nav.kl | 2 - passion.mk | 12 +- synaptics-rmi-touchscreen.idc | 32 +- synaptics-rmi-touchscreen.kcm | 15 + synaptics-rmi-touchscreen.kl | 18 ++ 10 files changed, 117 insertions(+), 567 deletions(-) create mode 100644 h2w_headset.kcm delete mode 100644 mahimahi-nav.kl create mode 100644 synaptics-rmi-touchscreen.kcm create mode 100644 synaptics-rmi-touchscreen.kl diff --git a/h2w_headset.kcm b/h2w_headset.kcm new file mode 100644 index 0000000..7ee6e5a --- /dev/null +++ b/h2w_headset.kcm @@ -0,0 +1,15 @@ +# Copyright (C) 2010 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +type SPECIAL_FUNCTION diff --git a/h2w_headset.kl b/h2w_headset.kl index 10e9fa4..dea37b3 100644 --- a/h2w_headset.kl +++ b/h2w_headset.kl @@ -1,3 +1,17 @@ +# Copyright (C) 2010 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + key 107 ENDCALL WAKE_DROPPED key 113 MUTE WAKE key 114 VOLUME_DOWN WAKE diff --git a/mahimahi-keypad.kcm b/mahimahi-keypad.kcm index 0ce4a68..7ee6e5a 100644 --- a/mahimahi-keypad.kcm +++ b/mahimahi-keypad.kcm @@ -12,533 +12,4 @@ # See the License for the specific language governing permissions and # limitations under the License. -# -# Key character map for a built-in generic virtual keyboard primarily used -# for instrumentation and testing purposes. -# - -type FULL - -### Basic QWERTY keys ### - -key A { - label: 'A' - base: 'a' - shift, capslock: 'A' - ctrl, alt, meta: none -} - -key B { - label: 'B' - base: 'b' - shift, capslock: 'B' - ctrl, alt, meta: none -} - -key C { - label: 'C' - base: 'c' - shift, capslock: 'C' - alt: '\u00e7' - shift+alt: '\u00c7' - ctrl, meta: none -} - -key D { - label: 'D' - base: 'd' - shift, capslock: 'D' - ctrl, alt, meta: none -} - -key E { - label: 'E' - base: 'e' - shift, capslock: 'E' - alt: '\u0301' - ctrl, meta: none -} - -key F { - label: 'F' - base: 'f' - shift, capslock: 'F' - ctrl, alt, meta: none -} - -key G { - label: 'G' - base: 'g' - shift, capslock: 'G' - ctrl, alt, meta: none -} - -key H { - label: 'H' - base: 'h' - shift, capslock: 'H' - ctrl, alt, meta: none -} - -key I { - label: 'I' - base: 'i' - shift, capslock: 'I' - alt: '\u0302' - ctrl, meta: none -} - -key J { - label: 'J' - base: 'j' - shift, capslock: 'J' - ctrl, alt, meta: none -} - -key K { - label: 'K' - base: 'k' - shift, capslock: 'K' - ctrl, alt, meta: none -} - -key L { - label: 'L' - base: 'l' - shift, capslock: 'L' - ctrl, alt, meta: none -} - -key M { - label: 'M' - base: 'm' - shift, capslock: 'M' - ctrl, alt, meta: none -} - -key N { - label: 'N' - base: 'n' - shift, capslock: 'N' - alt: '\u0303' - ctrl, meta: none -} - -key O { - label: 'O' - base: 'o' - shift, capslock: 'O' - ctrl, alt, meta: none -} - -key P { - label: 'P' - base: 'p' - shift, capslock: 'P' - ctrl, alt, meta: none -} - -key Q { - label: 'Q' - base: 'q' - shift, capslock: 'Q' - ctrl, alt, meta: none -} - -key R { - label: 'R' - base: 'r' - shift, capslock: 'R' - ctrl, alt, meta: none -} - -key S { - label: 'S' - base: 's' - shift, capslock: 'S' - alt: '\u00df' - ctrl, meta: none -} - -key T { - label: 'T' - base: 't' - shift, capslock: 'T' - ctrl, alt, meta: none -} - -key U { - label: 'U' - base: 'u' - shift, capslock: 'U' - alt: '\u0308' - ctrl, meta: none -} - -key V { - label: 'V' - base: 'v' - shift, capslock: 'V' - ctrl, alt, meta: none -} - -key W { - label: 'W' - base: 'w' - shift, capslock: 'W' - ctrl, alt, meta: none -} - -key X { - label: 'X' - base: 'x' - shift, capslock: 'X' - ctrl, alt, meta: none -} - -key Y { - label: 'Y' - base: 'y' - shift, capslock: 'Y' - ctrl, alt, meta: none -} - -key Z { - label: 'Z' - base: 'z' - shift, capslock: 'Z' - ctrl, alt, meta: none -} - -key 0 { - label, number: '0' - base: '0' - shift: ')' - ctrl, alt, meta: none -} - -key 1 { - label, number: '1' - base: '1' - shift: '!' - ctrl, alt, meta: none -} - -key 2 { - label, number: '2' - base: '2' - shift: '@' - ctrl, alt, meta: none -} - -key 3 { - label, number: '3' - base: '3' - shift: '#' - ctrl, alt, meta: none -} - -key 4 { - label, number: '4' - base: '4' - shift: '$' - ctrl, alt, meta: none -} - -key 5 { - label, number: '5' - base: '5' - shift: '%' - ctrl, alt, meta: none -} - -key 6 { - label, number: '6' - base: '6' - shift: '^' - ctrl, alt, meta: none - alt+shift: '\u0302' -} - -key 7 { - label, number: '7' - base: '7' - shift: '&' - ctrl, alt, meta: none -} - -key 8 { - label, number: '8' - base: '8' - shift: '*' - ctrl, alt, meta: none -} - -key 9 { - label, number: '9' - base: '9' - shift: '(' - ctrl, alt, meta: none -} - -key SPACE { - label: ' ' - base: ' ' - ctrl, alt: none - meta: fallback SEARCH -} - -key ENTER { - label: '\n' - base: '\n' - ctrl, alt, meta: none -} - -key TAB { - label: '\t' - base: '\t' - ctrl, alt: none - meta: fallback APP_SWITCH -} - -key COMMA { - label, number: ',' - base: ',' - shift: '<' - ctrl, alt, meta: none -} - -key PERIOD { - label, number: '.' - base: '.' - shift: '>' - ctrl, alt, meta: none -} - -key SLASH { - label, number: '/' - base: '/' - shift: '?' - ctrl, alt, meta: none -} - -key GRAVE { - label, number: '`' - base: '`' - shift: '~' - alt: '\u0300' - alt+shift: '\u0303' - ctrl, meta: none -} - -key MINUS { - label, number: '-' - base: '-' - shift: '_' - ctrl, alt, meta: none -} - -key EQUALS { - label, number: '=' - base: '=' - shift: '+' - ctrl, alt, meta: none -} - -key LEFT_BRACKET { - label, number: '[' - base: '[' - shift: '{' - ctrl, alt, meta: none -} - -key RIGHT_BRACKET { - label, number: ']' - base: ']' - shift: '}' - ctrl, alt, meta: none -} - -key BACKSLASH { - label, number: '\\' - base: '\\' - shift: '|' - ctrl, alt, meta: none -} - -key SEMICOLON { - label, number: ';' - base: ';' - shift: ':' - ctrl, alt, meta: none -} - -key APOSTROPHE { - label, number: '\'' - base: '\'' - shift: '"' - ctrl, alt, meta: none -} - -### Numeric keypad ### - -key NUMPAD_0 { - label, number: '0' - base: fallback INSERT - numlock: '0' - ctrl, alt, meta: none -} - -key NUMPAD_1 { - label, number: '1' - base: fallback MOVE_END - numlock: '1' - ctrl, alt, meta: none -} - -key NUMPAD_2 { - label, number: '2' - base: fallback DPAD_DOWN - numlock: '2' - ctrl, alt, meta: none -} - -key NUMPAD_3 { - label, number: '3' - base: fallback PAGE_DOWN - numlock: '3' - ctrl, alt, meta: none -} - -key NUMPAD_4 { - label, number: '4' - base: fallback DPAD_LEFT - numlock: '4' - ctrl, alt, meta: none -} - -key NUMPAD_5 { - label, number: '5' - base: fallback DPAD_CENTER - numlock: '5' - ctrl, alt, meta: none -} - -key NUMPAD_6 { - label, number: '6' - base: fallback DPAD_RIGHT - numlock: '6' - ctrl, alt, meta: none -} - -key NUMPAD_7 { - label, number: '7' - base: fallback MOVE_HOME - numlock: '7' - ctrl, alt, meta: none -} - -key NUMPAD_8 { - label, number: '8' - base: fallback DPAD_UP - numlock: '8' - ctrl, alt, meta: none -} - -key NUMPAD_9 { - label, number: '9' - base: fallback PAGE_UP - numlock: '9' - ctrl, alt, meta: none -} - -key NUMPAD_LEFT_PAREN { - label, number: '(' - base: '(' - ctrl, alt, meta: none -} - -key NUMPAD_RIGHT_PAREN { - label, number: ')' - base: ')' - ctrl, alt, meta: none -} - -key NUMPAD_DIVIDE { - label, number: '/' - base: '/' - ctrl, alt, meta: none -} - -key NUMPAD_MULTIPLY { - label, number: '*' - base: '*' - ctrl, alt, meta: none -} - -key NUMPAD_SUBTRACT { - label, number: '-' - base: '-' - ctrl, alt, meta: none -} - -key NUMPAD_ADD { - label, number: '+' - base: '+' - ctrl, alt, meta: none -} - -key NUMPAD_DOT { - label, number: '.' - base: fallback FORWARD_DEL - numlock: '.' - ctrl, alt, meta: none -} - -key NUMPAD_COMMA { - label, number: ',' - base: ',' - ctrl, alt, meta: none -} - -key NUMPAD_EQUALS { - label, number: '=' - base: '=' - ctrl, alt, meta: none -} - -key NUMPAD_ENTER { - label: '\n' - base: '\n' fallback ENTER - ctrl, alt, meta: none fallback ENTER -} - -### Special keys on phones ### - -key AT { - label, number: '@' - base: '@' -} - -key STAR { - label, number: '*' - base: '*' -} - -key POUND { - label, number: '#' - base: '#' -} - -key PLUS { - label, number: '+' - base: '+' -} - -### Non-printing keys ### - -key ESCAPE { - base: fallback BACK - meta: fallback HOME - alt: fallback MENU -} +type SPECIAL_FUNCTION diff --git a/mahimahi-keypad.kl b/mahimahi-keypad.kl index d186dd4..6dd0ebd 100644 --- a/mahimahi-keypad.kl +++ b/mahimahi-keypad.kl @@ -1,10 +1,17 @@ -key 116 POWER WAKE -key 115 VOLUME_UP WAKE +# Copyright (C) 2010 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + key 114 VOLUME_DOWN WAKE -key 158 BACK WAKE_DROPPED -key 102 HOME WAKE_DROPPED -key 229 MENU WAKE_DROPPED -key 59 MENU WAKE_DROPPED -key 139 MENU WAKE_DROPPED -key 127 SEARCH WAKE_DROPPED -key 217 SEARCH WAKE_DROPPED +key 115 VOLUME_UP WAKE +key 116 POWER WAKE diff --git a/mahimahi-nav.idc b/mahimahi-nav.idc index b797955..c29e3bf 100644 --- a/mahimahi-nav.idc +++ b/mahimahi-nav.idc @@ -1,4 +1,20 @@ +# Copyright (C) 2010 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# +# Input Device Calibration File for the Passion trackball. +# + cursor.mode = navigation cursor.orientationAware = 1 -keyboard.layout = mahimahi-nav -device.internal = 1 diff --git a/mahimahi-nav.kl b/mahimahi-nav.kl deleted file mode 100644 index 8f61414..0000000 --- a/mahimahi-nav.kl +++ /dev/null @@ -1,2 +0,0 @@ -#key 272 BTN_MOUSE WAKE -key 272 BTN_LEFT WAKE diff --git a/passion.mk b/passion.mk index d91a206..e7a5ffd 100644 --- a/passion.mk +++ b/passion.mk @@ -64,16 +64,22 @@ PRODUCT_PACKAGES += \ sensors.mahimahi \ camera.qsd8k -# Prebuilt files/configs +# Ramdisk PRODUCT_COPY_FILES += \ device/htc/passion/init.mahimahi.rc:root/init.mahimahi.rc \ device/htc/passion/init.mahimahi.usb.rc:root/init.mahimahi.usb.rc \ - device/htc/passion/ueventd.mahimahi.rc:root/ueventd.mahimahi.rc \ + device/htc/passion/ueventd.mahimahi.rc:root/ueventd.mahimahi.rc + +# Prebuilt files/configs +PRODUCT_COPY_FILES += \ + device/htc/passion/h2w_headset.kl:system/usr/keylayout/h2w_headset.kl \ + device/htc/passion/h2w_headset.kcm:system/usr/keychars/h2w_headset.kcm \ device/htc/passion/mahimahi-keypad.kl:system/usr/keylayout/mahimahi-keypad.kl \ device/htc/passion/mahimahi-keypad.kcm:system/usr/keychars/mahimahi-keypad.kcm \ - device/htc/passion/h2w_headset.kl:system/usr/keylayout/h2w_headset.kl \ device/htc/passion/mahimahi-nav.idc:system/usr/idc/mahimahi-nav.idc \ device/htc/passion/synaptics-rmi-touchscreen.idc:system/usr/idc/synaptics-rmi-touchscreen.idc \ + device/htc/passion/synaptics-rmi-touchscreen.kl:system/usr/keylayout/synaptics-rmi-touchscreen.kl \ + device/htc/passion/synaptics-rmi-touchscreen.kcm:system/usr/keychars/synaptics-rmi-touchscreen.kcm \ device/htc/passion/vold.fstab:system/etc/vold.fstab \ device/htc/passion/sysctl.conf:system/etc/sysctl.conf diff --git a/synaptics-rmi-touchscreen.idc b/synaptics-rmi-touchscreen.idc index 8aff6ed..3d4d38f 100644 --- a/synaptics-rmi-touchscreen.idc +++ b/synaptics-rmi-touchscreen.idc @@ -20,13 +20,22 @@ # Refer to the input device calibration documentation for more details. # - # New for ICS +# Basic Parameters touch.deviceType = touchScreen touch.orientationAware = 1 - # Touch Size +# Size +touch.size.calibration = none + +# Touch Size touch.touchSize.calibration = pressure +# Orientation +touch.orientation.calibration = none + +# JumpyTouchFilter +touch.filterTouchEvents = 1 + # Tool Size # Driver reports tool size as a linear width measurement summed over # all contact points. @@ -37,7 +46,6 @@ touch.touchSize.calibration = pressure # is 10px per mm we obtain a scale factor of 10 pixels / unit and # a bias of 160 pixels. In addition, the raw width represents a # sum of all contact area so we note this fact in the calibration. - touch.toolSize.calibration = linear touch.toolSize.linearScale = 10 touch.toolSize.linearBias = 160 @@ -54,24 +62,6 @@ touch.toolSize.isSummed = 1 # reported as having a pressure somewhere in the vicinity of 1.0, # a featherlight touch will be below 1.0 and a heavy or large touch # will be above 1.0. We don't expect these values to be accurate. - touch.pressure.calibration = amplitude touch.pressure.source = default touch.pressure.scale = 0.01 - - # Size -touch.size.calibration = normalized - - # Orientation -touch.orientation.calibration = none - - # JumpyTouchFilter -touch.filterTouchEvents = 1 - - # Keyboard -keyboard.layout = mahimahi-keypad -keyboard.characterMap = Virtual -keyboard.orientationAware = 1 -keyboard.builtIn = 0 - -device.internal = 1 diff --git a/synaptics-rmi-touchscreen.kcm b/synaptics-rmi-touchscreen.kcm new file mode 100644 index 0000000..7ee6e5a --- /dev/null +++ b/synaptics-rmi-touchscreen.kcm @@ -0,0 +1,15 @@ +# Copyright (C) 2010 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +type SPECIAL_FUNCTION diff --git a/synaptics-rmi-touchscreen.kl b/synaptics-rmi-touchscreen.kl new file mode 100644 index 0000000..01d0718 --- /dev/null +++ b/synaptics-rmi-touchscreen.kl @@ -0,0 +1,18 @@ +# Copyright (C) 2011 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +key 102 HOME VIRTUAL +key 139 MENU VIRTUAL +key 158 BACK VIRTUAL +key 217 SEARCH VIRTUAL