Keybow : keyboard layout

Hi. Keybow config : Is there a simple way to change the keyboard layout used ? Setting a ‘A’ key in the lua script, I get a ‘Q’ stroke on an Azerty keyboard (the default config is set to QWERTY I guess) - for the number it’s less obvious.
Any hints ?
Thanks.
G.

You would have to change these lines here:

The line SHIFTED_KEYCODES are the keys you would expect to be produced when the shift key is held.

If you figure it out, please share the result! It’s on my TODO list to get some common layouts mapped here and add a function to let users specify which layout they want to use.

Hello, you would have the Italian layout of KEYCODES and SHIFTED_KEYCODES …
I’m going crazy!

:-)

THANK YOU

I’ve no experience using an Italian keyboard layout, how does it work? Are the images you’ve supplied showing the characters produced using “Shift” and then a different modifier key?

Hello, the first keyboard at the top is UK (don’t mind the red, green, blue characters) and if I’m not mistaken it’s the default one in keybow.lua

local KEYCODES = “abcdefghijklmnopqrstuvwxyz1234567890\n\a\b\t -=\#;’`,./”
local SHIFTED_KEYCODES = “ABCDEFGHIJKLMNOPQRSTUVWXYZ!@#$%^&*()\a\a\a\a\a_+{}|~:”~<>?"

I need the keyboard layout below (ITA) which is the same as the UK except for some characters …

For example the minus symbol “-” (in ITA) becomes single quote “” the problem is only in special characters, the rest works well as in the UK, but I do not understand the "\n\a\b\t " and “\a\a\a\a\a” in KEYCODES and in SHIFTED_KEYCODES.

I need only these:

(KEYCODES) \n\a\b\t -=[]\#;’`,./
(SHIFTED_KEYCODES) !@#$%^&*()\a\a\a\a\a_+{}|~:"~<>?

Would you help me?

THANK YOU

The escape sequences- \n etc - map to characters that can’t otherwise be represented in a Lua string.

\n is newline.
\a is basically an unprintable character, to skip ones that don’t have any meaning (a placeholder)
\t is tab
\b is backspace.

In this case the \a\a\a\a is just filling in the gaps where those keys don’t have a shifted state.

I’m hoping to work out a better way to do this, because it’s confusing to read, difficult to maintain, and even more difficult to create new layouts for new languages. Even US/British English differences are a nuisance!

Hello! I have the same problem. I am using a Slovenian keyboard layout and I have trouble setting up a keybow.lua file in a way to produce satisfactory result. It is not just a simple case of switching some letters in 3rd and 4th line as suggested, since different alphabets have different number of letters (Slovenian keyboard additionally uses letters “čćžšđ”), while some symbols are not available only through shifting. Namely, the “@” symbol on Slovenian keyboard is obtained through AltGr+V combination. Also, a symbol " is also used, which seems to break the code if I try to use it, as it closes the argument in line 4.

I tried matching UK symbol order with Slovenian, but just a simple task of writing out an email address proves impossible. Please, provide a useful way to customize the keyboard layout, otherwise the Keybow is not usable by anybody that doesn’t have UK keyboard layout.

So far I have bought several Pimoroni / Raspberry Pi kits and all have proven useful and fun, however without this patch the Keybow remains just a novelty number keypad.

Please, help!
teo