1

I'm running a raspberry pi 3.0 on rasbian jessie lite and using a flat mac keyboard with the number pad on the right side. I do not have a GUI interface.

I went to change my keyboard layout because it was not correct (I couldn't use |). To do this, i installed console-common which let me select my layout from a list.

sudo apt-get install console-common

I selected mac / Unknown / US american / Standard / Standard. I think I should've chosen extended, but I'm still unsure about this part.

This was the incorrect layout and my keyboard is completely bonked. It seems like every key is mapped randomly. Does anyone have a suggestion of how i can revert this, other than manually writing out my new mapping, which is my last resort

2

To reconfigure the keyboard in Debian, run (as root, or using sudo):

dpkg-reconfigure keyboard-configuration

Link to official Debian documentation here.

If your keys are "random" (I have been there, not fun!), try to find the characters needed to execute the command above.

  • Thanks! I'm making some progress on the front. So far I got j = enter, , = backspace, m = `. I really just need to find up because this was my last command – Chris Nov 19 '16 at 18:51
  • welp i gave up and just wiped raspbian ¯_(ツ)_/¯ – Chris Nov 19 '16 at 19:05
0

If you have access to another computer you can ssh to your Pi and reset the keyboard that way.

I cannot give you a recommended keyboard layout for a direct console connection because that varies from keyboard to keyboard and I don't have a Mac keyboard to test against.

0

I've come up with an alternate solution to my problem. Ultimately, my issue was the keyboard was registered as gb (great britain) instead of us.

To fix this, I had the prerequisites of keyboard-configuration and console-setup installed (not sure if the latter is actually necessary) and changed the file /etc/default/keyboard. A quick script to do this

sed -i 's/gb/us/g' /etc/default/keyboard
service keyboard-setup restart

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.