• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

Tutorial - How to change your bluetooth keyboard layout

Search This thread

samstheman42

Senior Member
Nov 24, 2010
332
59
Boulder, CO
I've been searching/researching this topic for a while, and finally was able to get this working tonight. What follows is the result of my hard work, and some advice that was provided to me by some other members (credited later). This tutorial is designed to show how to change from the standard QWERTY layout to another of your choosing, be it AZERTY or Dvorak (as was my case) or perhaps even another.

I originally wanted to remap my bluetooth keyboard from QWERTY to Dvorak but couldn't find an easy way to do this. What follows is simple if you follow the directions step by step, but you'll want to be careful with how you do this.

Tools:
-Root Explorer
-A text editor (such as Notepad in Windows)

Once you have paired your bluetooth keyboard to your tablet, a keyboard layout file will be created in the /system/usr/keylayout/ folder of your system.

If you are a newbie, once you open Root Explorer, click Menu > Bookmarks > Root Folder > system > usr > keylayout

(If you want to save some time later on, before you enter the keylayout folder, long press the keylayout folder and select "Add Bookmark." This will allow you to quickly get back to this folder when it is time to copy/paste our modified .kl files later on.)

This will give you access to the file/s that we will want to edit in order to remap your keyboard. You should see files like Generic.kl, qwerty.kl, and hopefully one or more files that start with "Vendor_" that also have the .kl file extension.

Next we need to determine which of these Vendor_xxxx_Product_xxxx.kl files is the appropriate one for your keyboard.

Each keyboard has a specific Vendor ID as well as Product ID. The Vendor ID can be located at this address for most popular brands of bluetooth keyboard. In my case, since I was using a Motorola keyboard, my Vendor ID is 22b8.

In the /system/usr/keylayout/ folder, find the .kl file with your Vendor ID. There should only be one .kl file for your keyboard. For me the file was named: Vendor_22b8_Product_093d.kl

Using Root Explorer, long press the Vendor_xxxx_Product_xxxx.kl file for your keyboard and select copy. Now, click Menu > Bookmarks > sdcard and click the "paste" button.

From here, copy this file to your computer using whatever method you prefer. Open your text editor (I used Notepad though many suggest Notepad++) and drag and drop the Vendor_xxxx_Product_xxxx.kl file inside.

This is what mine looked like:
# 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.

#
# Motorola Bluetooth Wireless Keyboard.
#

key 1 BACK
key 2 1
key 3 2
key 4 3
key 5 4
key 6 5
key 7 6
key 8 7
key 9 8
key 10 9
key 11 0
key 12 MINUS
key 13 EQUALS
key 14 DEL
key 15 TAB
key 16 Q
key 17 W
key 18 E
key 19 R
key 20 T
key 21 Y
key 22 U
key 23 I
key 24 O
key 25 P
key 26 LEFT_BRACKET
key 27 RIGHT_BRACKET
key 28 ENTER
key 29 CTRL_LEFT
key 30 A
key 31 S
key 32 D
key 33 F
key 34 G
key 35 H
key 36 J
key 37 K
key 38 L
key 39 SEMICOLON
key 40 APOSTROPHE
key 41 GRAVE
key 42 SHIFT_LEFT
key 43 BACKSLASH
key 44 Z
key 45 X
key 46 C
key 47 V
key 48 B
key 49 N
key 50 M
key 51 COMMA
key 52 PERIOD
key 53 SLASH
key 54 SHIFT_RIGHT
key 56 ALT_LEFT
key 57 SPACE
key 58 CAPS_LOCK
key 59 F1
key 60 F2
key 61 F3
key 62 F4
key 63 F5
key 64 F6
key 65 F7
key 66 F8
key 67 F9
key 68 F10
key 87 F11
key 88 F12
key 97 CTRL_RIGHT
key 102 HOME
key 103 DPAD_UP
key 105 DPAD_LEFT
key 106 DPAD_RIGHT
key 107 MOVE_END
key 108 DPAD_DOWN
key 111 FORWARD_DEL
key 113 VOLUME_MUTE
key 114 VOLUME_DOWN
key 115 VOLUME_UP
key 125 MENU
key 127 SEARCH
key 163 MEDIA_NEXT
key 164 MEDIA_PLAY_PAUSE
key 165 MEDIA_PREVIOUS
key 166 MEDIA_STOP
# key 226 tbd reserved key

I highly suggest opening a second text editor window and copy/pasting everything into that for reference while editing your keys. It may also be helpful to bring up an image of the keyboard layout that you wish to map to in a separate window somewhere else.

From here, we will want to change the individual letters and symbols for each key. The general layout will look like this: key x CMD [opt]

This means that key x will perform CMD command and [opt] option.

For my case, lets say that I want to change the letter "Q" to the symbol ' (yes, that's an apostrophe)

On my QWERTY keyboard, "Q" is key 16, so my edit to the entry for key 16 will go from this:

and will change to this

My full edited list (slightly condensed to really only show the keys that were changed) looks like this:
key 1 BACK
key 2 1
key 3 2
key 4 3
key 5 4
key 6 5
key 7 6
key 8 7
key 9 8
key 10 9
key 11 0
key 12 LEFT_BRACKET
key 13 RIGHT_BRACKET
key 14 DEL
key 15 TAB
key 16 APOSTROPHE
key 17 COMMA
key 18 PERIOD
key 19 P
key 20 Y
key 21 F
key 22 G
key 23 C
key 24 R
key 25 L
key 26 SLASH
key 27 EQUALS
key 28 ENTER
key 29 CTRL_LEFT
key 30 A
key 31 O
key 32 E
key 33 U
key 34 I
key 35 D
key 36 H
key 37 T
key 38 N
key 39 S
key 40 MINUS
key 41 GRAVE
key 42 SHIFT_LEFT
key 43 BACKSLASH
key 44 SEMICOLON
key 45 Q
key 46 J
key 47 K
key 48 X
key 49 B
key 50 M
key 51 W
key 52 V
key 53 Z
key 54 SHIFT_RIGHT

It's important to note that the other keys (1-15 and 55 onwards) are still there, I chose not to include them since they were not changed. If you delete the entries for these keys, you'll have half of a keyboard where the buttons don't do anything.

From here, once you are done editing your re-mapped keyboard, save the file in your text editor and copy it back to your sd card. Now, open Root Explorer and go back to the /system/usr/keylayout/ folder and delete your Vendor_xxxx_Product_xxxx_.kl file. If you do not, this will not work and you will have to replace your modded file with a copy of the original to fix the fact that your keyboard won't work at ALL anymore.

After you have deleted the .kl file, navigate back to your sd card in Root Explorer. (Newbies can Menu > Bookmarks > SD Card) Long press your modded copy of the .kl file and select "copy" from the menu that pops up. Now, Menu > Bookmarks > keylayout (or just take the long way and navigate your way there) and paste.

You are now done and can enjoy your newly re-mapped keyboard :)

Special thanks go to:
tkolev for writing This Tutorial for how to map usb keyboards.
 

baldbear

Senior Member
Jul 18, 2006
76
5
Can you remap the keys that don't work on the Motorola keyboard to the Acer equivalents? I can't remember which ones right now (I'm at work), but I know some of the special function keys on top don't do anything.
 

uli68

Senior Member
Dec 28, 2009
84
4
i have the official german acer bluetooth keypboard but for some reason it wont get identified as such, means QWERTY instead of QWERTZ layout. acer support recommends to switch to xt9-mode (which for some strange reason works with german umlaute) but this surely can't be the solution.

someone knows the cause of this problem? and how to fix it on stock rom 3.2?
 

samstheman42

Senior Member
Nov 24, 2010
332
59
Boulder, CO
Can you remap the keys that don't work on the Motorola keyboard to the Acer equivalents? I can't remember which ones right now (I'm at work), but I know some of the special function keys on top don't do anything.

Yes it is possible to re map them to execute new commands. Is there a particular function that you want it to do?

Sent from my LG-P999 using Tapatalk
 

samstheman42

Senior Member
Nov 24, 2010
332
59
Boulder, CO
i have the official german acer bluetooth keypboard but for some reason it wont get identified as such, means QWERTY instead of QWERTZ layout. acer support recommends to switch to xt9-mode (which for some strange reason works with german umlaute) but this surely can't be the solution.

someone knows the cause of this problem? and how to fix it on stock rom 3.2?

This is possible to fix using the stock ROM as long as you have root access to the tablet. If you follow the above process, you can re map the letter keys to pretty much any configuration that you want.

Sent from my LG-P999 using Tapatalk
 

uli68

Senior Member
Dec 28, 2009
84
4
This is possible to fix using the stock ROM as long as you have root access to the tablet. If you follow the above process, you can re map the letter keys to pretty much any configuration that you want.

Sent from my LG-P999 using Tapatalk


so a rooted device is mandatory? too bad, i had hopes i could fix this while keeping up my warranty. is there a way to get a rooted device back to factory settings?
 

samstheman42

Senior Member
Nov 24, 2010
332
59
Boulder, CO
so a rooted device is mandatory? too bad, i had hopes i could fix this while keeping up my warranty. is there a way to get a rooted device back to factory settings?

It's actually quite easy. If you follow this post on How To Root An Acer Iconia A500 you'll find that not only can you get root access very easily, but reverting back to "factory settings" where the tablet is "unrooted" is as easy as the touch of a button. (covered later in the thread)
 

Mazarin07

Senior Member
Mar 11, 2012
87
4
Too complicated

On the mobileread forums thread=159538 there is adescription that seems much more simple to me.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 5
    I've been searching/researching this topic for a while, and finally was able to get this working tonight. What follows is the result of my hard work, and some advice that was provided to me by some other members (credited later). This tutorial is designed to show how to change from the standard QWERTY layout to another of your choosing, be it AZERTY or Dvorak (as was my case) or perhaps even another.

    I originally wanted to remap my bluetooth keyboard from QWERTY to Dvorak but couldn't find an easy way to do this. What follows is simple if you follow the directions step by step, but you'll want to be careful with how you do this.

    Tools:
    -Root Explorer
    -A text editor (such as Notepad in Windows)

    Once you have paired your bluetooth keyboard to your tablet, a keyboard layout file will be created in the /system/usr/keylayout/ folder of your system.

    If you are a newbie, once you open Root Explorer, click Menu > Bookmarks > Root Folder > system > usr > keylayout

    (If you want to save some time later on, before you enter the keylayout folder, long press the keylayout folder and select "Add Bookmark." This will allow you to quickly get back to this folder when it is time to copy/paste our modified .kl files later on.)

    This will give you access to the file/s that we will want to edit in order to remap your keyboard. You should see files like Generic.kl, qwerty.kl, and hopefully one or more files that start with "Vendor_" that also have the .kl file extension.

    Next we need to determine which of these Vendor_xxxx_Product_xxxx.kl files is the appropriate one for your keyboard.

    Each keyboard has a specific Vendor ID as well as Product ID. The Vendor ID can be located at this address for most popular brands of bluetooth keyboard. In my case, since I was using a Motorola keyboard, my Vendor ID is 22b8.

    In the /system/usr/keylayout/ folder, find the .kl file with your Vendor ID. There should only be one .kl file for your keyboard. For me the file was named: Vendor_22b8_Product_093d.kl

    Using Root Explorer, long press the Vendor_xxxx_Product_xxxx.kl file for your keyboard and select copy. Now, click Menu > Bookmarks > sdcard and click the "paste" button.

    From here, copy this file to your computer using whatever method you prefer. Open your text editor (I used Notepad though many suggest Notepad++) and drag and drop the Vendor_xxxx_Product_xxxx.kl file inside.

    This is what mine looked like:
    # 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.

    #
    # Motorola Bluetooth Wireless Keyboard.
    #

    key 1 BACK
    key 2 1
    key 3 2
    key 4 3
    key 5 4
    key 6 5
    key 7 6
    key 8 7
    key 9 8
    key 10 9
    key 11 0
    key 12 MINUS
    key 13 EQUALS
    key 14 DEL
    key 15 TAB
    key 16 Q
    key 17 W
    key 18 E
    key 19 R
    key 20 T
    key 21 Y
    key 22 U
    key 23 I
    key 24 O
    key 25 P
    key 26 LEFT_BRACKET
    key 27 RIGHT_BRACKET
    key 28 ENTER
    key 29 CTRL_LEFT
    key 30 A
    key 31 S
    key 32 D
    key 33 F
    key 34 G
    key 35 H
    key 36 J
    key 37 K
    key 38 L
    key 39 SEMICOLON
    key 40 APOSTROPHE
    key 41 GRAVE
    key 42 SHIFT_LEFT
    key 43 BACKSLASH
    key 44 Z
    key 45 X
    key 46 C
    key 47 V
    key 48 B
    key 49 N
    key 50 M
    key 51 COMMA
    key 52 PERIOD
    key 53 SLASH
    key 54 SHIFT_RIGHT
    key 56 ALT_LEFT
    key 57 SPACE
    key 58 CAPS_LOCK
    key 59 F1
    key 60 F2
    key 61 F3
    key 62 F4
    key 63 F5
    key 64 F6
    key 65 F7
    key 66 F8
    key 67 F9
    key 68 F10
    key 87 F11
    key 88 F12
    key 97 CTRL_RIGHT
    key 102 HOME
    key 103 DPAD_UP
    key 105 DPAD_LEFT
    key 106 DPAD_RIGHT
    key 107 MOVE_END
    key 108 DPAD_DOWN
    key 111 FORWARD_DEL
    key 113 VOLUME_MUTE
    key 114 VOLUME_DOWN
    key 115 VOLUME_UP
    key 125 MENU
    key 127 SEARCH
    key 163 MEDIA_NEXT
    key 164 MEDIA_PLAY_PAUSE
    key 165 MEDIA_PREVIOUS
    key 166 MEDIA_STOP
    # key 226 tbd reserved key

    I highly suggest opening a second text editor window and copy/pasting everything into that for reference while editing your keys. It may also be helpful to bring up an image of the keyboard layout that you wish to map to in a separate window somewhere else.

    From here, we will want to change the individual letters and symbols for each key. The general layout will look like this: key x CMD [opt]

    This means that key x will perform CMD command and [opt] option.

    For my case, lets say that I want to change the letter "Q" to the symbol ' (yes, that's an apostrophe)

    On my QWERTY keyboard, "Q" is key 16, so my edit to the entry for key 16 will go from this:

    and will change to this

    My full edited list (slightly condensed to really only show the keys that were changed) looks like this:
    key 1 BACK
    key 2 1
    key 3 2
    key 4 3
    key 5 4
    key 6 5
    key 7 6
    key 8 7
    key 9 8
    key 10 9
    key 11 0
    key 12 LEFT_BRACKET
    key 13 RIGHT_BRACKET
    key 14 DEL
    key 15 TAB
    key 16 APOSTROPHE
    key 17 COMMA
    key 18 PERIOD
    key 19 P
    key 20 Y
    key 21 F
    key 22 G
    key 23 C
    key 24 R
    key 25 L
    key 26 SLASH
    key 27 EQUALS
    key 28 ENTER
    key 29 CTRL_LEFT
    key 30 A
    key 31 O
    key 32 E
    key 33 U
    key 34 I
    key 35 D
    key 36 H
    key 37 T
    key 38 N
    key 39 S
    key 40 MINUS
    key 41 GRAVE
    key 42 SHIFT_LEFT
    key 43 BACKSLASH
    key 44 SEMICOLON
    key 45 Q
    key 46 J
    key 47 K
    key 48 X
    key 49 B
    key 50 M
    key 51 W
    key 52 V
    key 53 Z
    key 54 SHIFT_RIGHT

    It's important to note that the other keys (1-15 and 55 onwards) are still there, I chose not to include them since they were not changed. If you delete the entries for these keys, you'll have half of a keyboard where the buttons don't do anything.

    From here, once you are done editing your re-mapped keyboard, save the file in your text editor and copy it back to your sd card. Now, open Root Explorer and go back to the /system/usr/keylayout/ folder and delete your Vendor_xxxx_Product_xxxx_.kl file. If you do not, this will not work and you will have to replace your modded file with a copy of the original to fix the fact that your keyboard won't work at ALL anymore.

    After you have deleted the .kl file, navigate back to your sd card in Root Explorer. (Newbies can Menu > Bookmarks > SD Card) Long press your modded copy of the .kl file and select "copy" from the menu that pops up. Now, Menu > Bookmarks > keylayout (or just take the long way and navigate your way there) and paste.

    You are now done and can enjoy your newly re-mapped keyboard :)

    Special thanks go to:
    tkolev for writing This Tutorial for how to map usb keyboards.