After the main problem is solved <a href="https://stackoverflow.com/questions...rom-multiple-hid-inputs-raspberry-pi/47247208">try to read from multiple HID inputs</a> I open here a new question for the following (and different) problem:
I installed <a href="https://minibianpi.wordpress.com" rel="nofollow noreferrer">minibian</a> on a RaspPi. The entire system is running on
, in details:
and
and also python
says
.
There is no X running (because it's not installed):
says
and
says
.
But there is the following problem: I have a German keyboard connected, which writes german as expected in console, but is recognized as english from evdev. I am using these scripts, <a href="https://khanhicetea.com/post/read_input_from_usb_keyboard_in_linux/" rel="nofollow noreferrer">read input from usb keyboard in linux</a> in combination with <a href="http://python-evdev.readthedocs.io/...ing-events-from-multiple-devices-using-select" rel="nofollow noreferrer">reading events from multiple devices</a> which works as expected, except the language. My
keystroke is recognized as
, my
keystroke as
, my
as
and so on. But everything, so far I can see, is set to
.
This script (the evdev part only)
says
for
keystrokes.
What's wrong here ?
I installed <a href="https://minibianpi.wordpress.com" rel="nofollow noreferrer">minibian</a> on a RaspPi. The entire system is running on
Code:
'de_DE'
Code:
[email protected]:~# locale
LANG=de_DE.UTF-8
LANGUAGE=
LC_CTYPE="de_DE.UTF-8"
LC_NUMERIC="de_DE.UTF-8"
LC_TIME="de_DE.UTF-8"
LC_COLLATE="de_DE.UTF-8"
LC_MONETARY="de_DE.UTF-8"
LC_MESSAGES="de_DE.UTF-8"
LC_PAPER="de_DE.UTF-8"
LC_NAME="de_DE.UTF-8"
LC_ADDRESS="de_DE.UTF-8"
LC_TELEPHONE="de_DE.UTF-8"
LC_MEASUREMENT="de_DE.UTF-8"
LC_IDENTIFICATION="de_DE.UTF-8"
LC_ALL=
and
Code:
[email protected]:~# grep -v ^# /etc/locale.gen
de_DE.UTF-8 UTF-8
and also python
Code:
locale.getdefaultlocale()
Code:
'de_DE','utf-8'
There is no X running (because it's not installed):
Code:
ps -aux | grep X
Code:
1297 0.0 0.1 4212 1828 pts/0 S+ 10:13 0:00 grep X
Code:
systemctl get-default
Code:
multi-user.target
But there is the following problem: I have a German keyboard connected, which writes german as expected in console, but is recognized as english from evdev. I am using these scripts, <a href="https://khanhicetea.com/post/read_input_from_usb_keyboard_in_linux/" rel="nofollow noreferrer">read input from usb keyboard in linux</a> in combination with <a href="http://python-evdev.readthedocs.io/...ing-events-from-multiple-devices-using-select" rel="nofollow noreferrer">reading events from multiple devices</a> which works as expected, except the language. My
Code:
Y
Code:
KEY_Z
Code:
Z
Code:
KEY_Y
Code:
ß
Code:
KEY_MINUS
Code:
de_DE
This script (the evdev part only)
Code:
from evdev import InputDevice, categorize, ecodes
dev = InputDevice('/dev/input/event0')
print(dev)
#device /dev/input/event1, name "Dell Dell USB Keyboard", phys "usb-0000:00:12.1-2/input0"
for event in dev.read_loop():
if event.type == ecodes.EV_KEY:
print(categorize(event))
says
Code:
key event at 1510568613.966220, 44 (KEY_Z), down
key event at 1510568614.039341, 44 (KEY_Z), up
key event at 1510568614.926334, 21 (KEY_Y), down
key event at 1510568614.998331, 21 (KEY_Y), up
key event at 1510568615.799577, 12 (KEY_MINUS), down
key event at 1510568615.863569, 12 (KEY_MINUS), up
for
Code:
yzß
What's wrong here ?