Jeff Brown | 590a9d6 | 2011-06-30 12:55:34 -0700 | [diff] [blame] | 1 | <!-- |
| 2 | Copyright 2011 The Android Open Source Project |
| 3 | |
| 4 | Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | you may not use this file except in compliance with the License. |
| 6 | You may obtain a copy of the License at |
| 7 | |
| 8 | http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | |
| 10 | Unless required by applicable law or agreed to in writing, software |
| 11 | distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | See the License for the specific language governing permissions and |
| 14 | limitations under the License. |
| 15 | --> |
| 16 | |
| 17 | # Migration Guide # |
| 18 | |
| 19 | This document contains a few helpful tips when migrating to new Android releases. |
| 20 | |
| 21 | ## Migrating to Android Gingerbread 2.3 ## |
| 22 | |
| 23 | In Gingerbread, we added the concept of input device configuration files |
| 24 | (also referred to as input device calibration files in this release). |
| 25 | |
| 26 | Make sure to provide an input device configuration file for all touch screens. |
| 27 | In particular, it is worth spending time providing a calibration reference for |
| 28 | touch size information. |
| 29 | |
| 30 | ## Migrating to Android Honeycomb 3.0 ## |
| 31 | |
| 32 | In Honeycomb, we revised the key character map file format and started making |
| 33 | greater use of input device configuration files. We also added support for full |
| 34 | PC-style keyboards and introduced a new "Generic" key map, which |
| 35 | replaced the older emulator-specific "qwerty" key map (which was never |
| 36 | intended to be used as a general-purpose key map.) |
| 37 | |
| 38 | Make sure to update all of your key character map files to use the new syntax. |
| 39 | |
| 40 | If your peripherals relied on the old "qwerty" key map, then you |
| 41 | may need to provide new device-specific key maps to emulate the old behavior. |
| 42 | You should create a new key map for each device identified either by |
| 43 | USB product id / vendor id or by device name. |
| 44 | |
| 45 | It is especially important to provide key character map files for all special |
| 46 | function input devices. These files should simple contain a line to set |
| 47 | the keyboard type to `SPECIAL_FUNCTION`. |
| 48 | |
| 49 | A good way to ensure that all built-in input devices are appropriately configured |
| 50 | is to run [Dumpsys](/tech/input/dumpsys.html) and look for devices that |
| 51 | are inappropriately using `Generic.kcm`. |
| 52 | |
| 53 | ## Migrating to Android Honeycomb 3.2 ## |
| 54 | |
| 55 | In Honeycomb 3.2, we added support for joysticks and extended the key layout file |
| 56 | format to enable joystick axis mapping. |
| 57 | |
| 58 | ## Migrating to Android Ice Cream Sandwich 4.0 ## |
| 59 | |
| 60 | In Ice Cream Sandwich 4.0, we changed the device driver requirements for touch screens |
| 61 | to follow the standard Linux multitouch input protocol and added support for |
| 62 | protocol "B". We also support digitizer tablets and stylus-based touch devices. |
| 63 | |
| 64 | You will probably need to update your input device driver to implement the Linux |
| 65 | multitouch input protocol correctly according to the standard. |
| 66 | |
| 67 | You will also need to update your input device configuration files because some |
| 68 | properties have been changed to be simpler and more systematic. |
| 69 | |
| 70 | Refer to [Touch Devices](/tech/input/touch-devices.html) for more details about |
| 71 | driver requirements. |