LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Keyboard on ~Current: Agetty consoles stuck on en_US. (https://www.linuxquestions.org/questions/slackware-14/keyboard-on-%7Ecurrent-agetty-consoles-stuck-on-en_us-4175735249/)

business_kid 03-24-2024 11:00 AM

Keyboard on ~Current: Agetty consoles stuck on en_US.
 
After the cleanest of clean installs, I'm trying to restore some semblance of normality to my setup. I'm running on ~Current of 2024-03-22 and Willysr's Mate in X.

The en_US keyboard defaults EVERYWHERE are a bugbear for the rest of the world. At the moment, I'm defaulting to runlevel 4 and have a modified to an Irish keyboard set up with things like a € sign, math symbols Gaelic accents etc. that I maintain myself. I'm using en_IE@euro locale.

But if I hit Ctrl_Alt_F2, and go to runlevel 3 consoles, I seem to have some US key mapping installed.There's no keyboard module that I can find; Neither is there a setting in /etc/profile, /etc/profile.d/, rc.local. Anything that I can find now is configured en_IE@euro. But the keyboard still does Shift_2 = @, I’ve no euro sign. Where 'apostrophe & @' should be (Right of ‘;&:’ key, which is right of ‘l&L’) my consoles give me ” How do I purge my consoles of en_US settings? I have done a couple of complete reboots to purge any stored values, and can't find anything else to change.

GazL 03-24-2024 11:24 AM

Have you configured /etc/rc.d/rc.keymap ?


I customise mine a little here. I use this:
Code:

#!/bin/sh

# Stop the kernel complaining about unknown keys for the
# brightness up/down keys on a HP Pavilion laptop.
# (Ensure the keycode (239) is mapped to VoidSymbol in
# the mapfile.

/usr/bin/setkeycodes e02b 239

# Load the console keyboard map.
if [ -x /usr/bin/loadkeys -a -f /etc/keymap.map ]; then
  /usr/bin/loadkeys /etc/keymap.map
fi

Then in /etc/keymap.map, I have:
Code:

#!/usr/bin/loadkeys
#
#  This file will be processed by loadkeys, invoked by
#  /etc/rc.d/rc.keymap during system initialisation.


# Include the standard British layout qwerty PC keymap:
include "/usr/share/kbd/keymaps/i386/qwerty/uk.map"

# Add the European currency 'euro' symbol to AltGr-4:
altgr keycode  5 = euro

# Add the cent symbol to AltGr-c:
altgr keycode  46 = cent

# Make Ctrl-/ send Control_underscore (for emacs undo key):
control keycode 53 = Control_underscore

# Make control-shift-minus send control_underscore (also emacs):
#control keycode 12 = minus
control shift keycode 12 = Control_underscore

# My HP Pavilion laptop generates an additional scancodes when
# the brightness up/down keys are pressed.
keycode 239 = VoidSymbol

# Prevent the backlight brightness up/down function keys generating
# characters (acpi will handle them):
#keycode 224 = VoidSymbol
#keycode 225 = VoidSymbol

# Prevent the mute, volumedown, volumeup function keys generating
# characters (acpi will handle them):
# keycode 113 = VoidSymbol
# keycode 114 = VoidSymbol
# keycode 115 = VoidSymbol

I prefer doing it this way: using the include and then my own modifications in /etc/keymap.map.


BTW, if you compile your own kernel you can embed your chosen keymap into it as a default. I do that on my crux install, but on Slackware I use Pat's kernels.

business_kid 03-24-2024 11:57 AM

Nope. ;redface:

Thanks for the rapid reply. It actually works. You might try the 'ie' map because it's nearly identical and of course, has the *€ sign (AltGr_4), seeing as that's our currency.

What I'd like to know is how you got the keycode nymbers for the keys you were reassigning?

GazL 03-24-2024 12:23 PM

There's a command called 'showkey" that will show you the keycodes/scancodes for the various buttons when you push them.

"dumpkeys" is useful too.

business_kid 03-24-2024 12:30 PM

Thanks. I actually just stuck a line in rc.local, because what you did sounded like work. The default is fine for me.


All times are GMT -5. The time now is 02:20 PM.