View Single Post
Posts: 77 | Thanked: 63 times | Joined on Sep 2009
#27
I figured out why other people were not able to replicate my ability to get bluetooth keyboards to work. It was due to residue from some of my early attempts. This post outlines what I believe should work for everyone.

First, let me emphasize that you should not attempt to do this unless you know what you are doing. If you make a mistake and mess up the /usr/share/X11/xkb directory you will brick your device and need to reflash. I know because I did.

This assumes that you have already enabled HID bluetooth by editing /etc/bluetooth/main.conf as described elsewhere. And that you hae already installed /usr/share/X11/xkb-chinook from the tar file that I posted earlier in this thread.

As root do:
# cd /usr/share/X11
# cp -i xkb-chinook/symbols/pc xkb/symbols/.
# cp -i xkb-chinook/symbols/us xkb/symbols/.
# cp -i xkb-chinook/geometry/pc xkb/geometry/.

Make sure that in the above you give cp the -i option and that you do not overwrite any files in /usr/share/X11/xkb/

Then as user do:
$ setxkbmap -device 4 -I -I/usr/share/X11/xkb-chinook -rules base -model pc105 -layout us
Then type a key (any key) on the internal keyboard. Now the external keyboard should work.

I don't know why you need to type a key on the internal keyboard for this to take effect.

The above assume that the keyboard is connected to device 4 which is what usually happens. But you should check first as described earlier in this thread.

You will need to reissue the setxkbmap command (as user) and type a key on the internal keyboard each time you connect the bluetooth keyboard. I find that periodically, the bluetooth connection to the keyboard is dropped and reinitialized. I don't know why this happens. But when it does you need to reissue the setxkbmap command and type a key on the internal keyboard. So I find it useful to have a shell script for it.

If someone else gets this to work, I'd appreciate hearing about it.
 

The Following 12 Users Say Thank You to qobi For This Useful Post: