OESF Portables Forum

Model Specific Forums => Cosmo Communicator => Cosmo Communicator - Linux => Topic started by: darkmage1975 on October 29, 2020, 06:50:19 am

Title: Bad keyboard mapping for some keyboard localizations
Post by: darkmage1975 on October 29, 2020, 06:50:19 am
Hi there. Nice to meet you, this is my first post.

I got a Cosmo with an Italian keyboard. I installed Linux and followed instructions on PS site to configure the keyboard. But, setting "Planet | Planet Computers Cosmo Communicator" as keyboard model and Italian as language, cause the "b" and "n" key to not work at all.

After some tries, I think that something is messed up with the "brightnessDown" and "brightnessUp" features (that doesn't work on Linux) that, at least in my layout, are sticked with the b and n keys. But b and n keys doesn't work even using the Alt or Fn keys.

If I change keyboard model OR language, b and n works without a problem, but then the layout is messed up.

The weird thing is that if I check what happens using xev, I see this for a working key (let's say "v"):

Code: [Select]
KeyPress event, serial 40, ...

KeyRelease event, serial 40, ...

but if I press "b":

Code: [Select]
FocusOut event, serial 40, ...

FocusIn event, serial 40, ...

KeymapNotify event, serial 40, ...

KeyRelease event, serial 40, ...

Do this means something?

There's only another keys binding that shows those messages: Fn + ESC.

Could you please give me some advice? I really don't know how to start. Thank you.

Title: Re: Bad keyboard mapping for some keyboard localizations
Post by: cge on January 31, 2021, 08:47:28 am
Many keyboard layouts I have tried don't actually work, primarily with this problem (eg, gr has it, and dvorak, after fixing other problems, also has it).  My assumption is that it is a bug in symbols/planet_vndr/cosmo in xkeyboard-config, but it isn't immediately obvious as to what differs between layouts that work and layouts that don't.

I was planning on figuring out how to fix this today, but because of the horrible battery life, and some bug in suspending that requires my password in order to suspend, the battery ran out overnight, and now something freezes while booting, and I can't figure out how to turn off the splash screen / remove quiet from the kernel parameters.  So it might be a while...
Title: Re: Bad keyboard mapping for some keyboard localizations
Post by: cge on January 31, 2021, 10:32:45 am
Actually, the problem wasn't there: KDE (specifically kglobalaccel) was configured to eat a number of keys.  See https://github.com/gemian/kglobalaccel/commit/34c52a58b12bc76eb1fb4d0832f2f13bef39fb7f (https://github.com/gemian/kglobalaccel/commit/34c52a58b12bc76eb1fb4d0832f2f13bef39fb7f).

It appears to be fixed, but not in v3.  Try running sudo apt update; sudo apt dist-upgrade and rebooting.
Title: Re: Bad keyboard mapping for some keyboard localizations
Post by: einar on February 20, 2021, 04:12:16 pm
I have the same problem with the Norwegian keyboard layout. To be more specific, c, v, b, and n does not work once I have logged in and set the keyboardlayout to no as to the instructions from Planet Computers. I have hooked up an external USB keyboard via the USB-C dock as well and the same keys do not work even then. What is strange is that when the screen locker goes on, I am able to log in with the default password "cosmo", so c works once the screen locker goes on.

Another problem I have is that Fn is interpreted as the Super key which means that the special key combinations with Fn do not work either. Instead I get the menu in KDE opening. If I then hit c, v, b or n, it closes again. If I want the menu to launch Konsole, I can hit Fn and type Ko, but when I get to n, the menu closes.

If I set the keyboard layout back to us (setxkbmap -model planetcosmo -layout us), the problem with c, v, b and n is still there. It also persists if I try to set it back (I obviously cannot type setxkbmap -model planetcosmo -layout no, but I can use the up arrow to find previous commands.)

I just noticed that t does not work either. I am trying to write sudo apt install in Konsole and it doesn't work.

After a reboot it reverts to the US keyboard and things generally works, except the Fn-key combinations and all the Norwegian glyphs (æøå). With my external USB keyboard, I am able to type - and _ in the way they are usually typed on a US keyboard (+ and shift+ on the physical Norwegian layout), but not on the Cosmo since it requires Fn.

I just updated everything (sudo apt update && sudo apt upgrade) and the problem is still here. I also tried with dist-upgrade but it does nothing since this is the newest Debian Stable already.