You are not logged in.

#1 2019-08-26 12:02:56

Jannis3005
Member
Registered: 2019-08-15
Posts: 10

Arch with KDE on HUAWEI Matebook

Hey there,

I'm using Arch for a while now on my Convertible HUAWEI Matebook E. Before that, I had Manjaro installed, and I'm having the same issue I had with Manjaro also on Arch. I can only lower my brightness with my keyboard, but I cannot rise it. I went to the KDE System settings and checked my hotkeys, they are set to Monitor Brightness Down and Monitor Brightness Up, so all set correctly.

However, when I press the FN Key, my Brightness gets lowered too. Same for the Brightness Up Key. So when I click on change hotkey for brightness up and then press the brightness up key, it shows as Monitor Brightness down.

They all have the same keycode (showkey):

keycode 224 press
keycode 224 release
keycode 224 press
keycode 224 release
keycode 224 press
keycode 224 release

Except for the Multiple Monitor Key, which works properly, my other Multimedia-Keys like Wifi and Microphone Toggle, Volume control etc. don't even show up with showkey.

For some additional information:

hwinfo --keyboard:

13: USB 00.0: 10800 Keyboard                                    
  [Created at usb.122]
  Unique ID: 2UT6.H_+HStFlrc1
  Parent ID: k4bc.2DFUsyrieMD
  SysFS ID: /devices/pci0000:00/0000:00:14.0/usb1/1-3/1-3:1.0
  SysFS BusID: 1-3:1.0
  Hardware Class: keyboard
  Model: "Huawei USB-HID KB MS"
  Hotplug: USB
  Vendor: usb 0x12d1 "Huawei Technologies Co., Ltd."
  Device: usb 0x1097 "USB-HID KB MS"
  Revision: "2.00"
  Driver: "usbhid"
  Driver Modules: "usbhid"
  Device File: /dev/input/event4
  Device Files: /dev/input/event4, /dev/input/by-path/pci-0000:00:14.0-usb-0:3:1.0-event-kbd, /dev/input/by-id/usb-HOLTEK_USB-HID_KB_MS-event-kbd
  Device Number: char 13:68
  Speed: 12 Mbps
  Module Alias: "usb:v12D1p1097d0200dc00dsc00dp00ic03isc01ip01in00"
  Driver Info #0:
    XkbRules: xfree86
    XkbModel: pc104
  Config Status: cfg=new, avail=yes, need=no, active=unknown
  Attached to: #14 (Hub)

19: PS/2 00.0: 10800 Keyboard
  [Created at input.226]
  Unique ID: 9ui9.+49ps10DtUF
  Hardware Class: keyboard
  Model: "AT Translated Set 2 keyboard"
  Vendor: 0x0001 
  Device: 0x0001 "AT Translated Set 2 keyboard"
  Compatible to: int 0x0211 0x0001
  Device File: /dev/input/event3
  Device Files: /dev/input/event3, /dev/input/by-path/platform-i8042-serio-0-event-kbd
  Device Number: char 13:67
  Driver Info #0:
    XkbRules: xfree86
    XkbModel: pc104
  Config Status: cfg=new, avail=yes, need=no, active=unknown

lsmod | grep -Ei 'kbd|wmi|laptop|i8042|serio':

huawei_wmi             16384  0
wmi_bmof               16384  0
ledtrig_audio          16384  3 snd_hda_codec_generic,huawei_wmi,snd_hda_codec_realtek
intel_wmi_thunderbolt    20480  0
wmi                    36864  3 intel_wmi_thunderbolt,huawei_wmi,wmi_bmof
sparse_keymap          16384  3 intel_hid,huawei_wmi,intel_vbtn
serio_raw              20480  0
atkbd                  36864  0
libps2                 20480  1 atkbd
i8042                  32768  0
serio                  28672  4 serio_raw,atkbd,i8042

After some more research while using TTY i figured out the Scancodes for the keys:

Scancodes:

Monitor Brightness Down: 	0x3b 0xbb
Monitor Brightness Up:	 	0x3c 0xbc
Keyboard Brightness:	 	0x3d 0xbd
Volume Mute:			 	0x3e 0xbe
Volume Down:			 	0x3f 0xbf
Volume Up:				0x40 0xc0
Microphone Mute:		 	0x41 0xc1
Screen Mirror Mode:		0x42 0xc2
Wifi Toggle:			 	0x43 0xc3
Matebook Manager:		0x44 0xc4

I tried editing /usr/lib/udev/hwdb.d/60-keyboard.hwdb, going to the HUAWEI section and using evdev:name:HUAWEI WMI hotkeys:dmi:bvn*:bvr*:bd*:svnHUAWEI*:pnHUAWEIMatebookE:rvr* as selector and remapping the keys like this:

KEYBOARD_KEY_3c=brightnessup

But that didnt work

Last edited by Jannis3005 (2019-08-26 13:18:13)

Offline

#2 2019-08-26 14:16:16

Ailen
Member
Registered: 2014-05-01
Posts: 32

Re: Arch with KDE on HUAWEI Matebook

https://github.com/kelp/arch-matebook-x … ttons-work

Do not know if this will help. You could also look for alternative input drivers for the keyboard.

Offline

#3 2019-08-26 14:20:03

Ailen
Member
Registered: 2014-05-01
Posts: 32

Re: Arch with KDE on HUAWEI Matebook

Ailen wrote:

You could also look for alternative input drivers for the keyboard.

It looks like huawei drivers have been included in the mainline Kernel. Ensure that your system is using the proper drivers. You could also try using the development drivers here https://github.com/aymanbagabas/Huawei-WMI.

Here is the commit log for the inclusion in the kernel. https://git.kernel.org/pub/scm/linux/ke … 272ac12c53

Last edited by Ailen (2019-08-26 14:20:16)

Offline

#4 2019-08-27 06:21:29

Jannis3005
Member
Registered: 2019-08-15
Posts: 10

Re: Arch with KDE on HUAWEI Matebook

Hey,

im on Kernel 5.2.9, which is greater than 5.0 I guess, and I checked for /sys/devices/platform/huawei-wmi like mentioned in the GitHub you send, however, that directory is missing, so I guess the drivers are not installed. How do I check if I'm using the correct driver that is integrated into the kernel?

I tried the driver from GitHub, which seems to be more targeted at the MateBook X, and it didn't work, even though it shows up as a loaded kernel module after installing and restarting. Since im still not very experienced with Linux and I don't have any experience in C or driver development to fix this myself, I just send the developer a message if/how I can help him include the MateBook E. I guess that is the better solution than finding a temporary fix for this issue

Last edited by Jannis3005 (2019-08-27 06:37:05)

Offline

#5 2019-08-27 07:19:33

Jannis3005
Member
Registered: 2019-08-15
Posts: 10

Re: Arch with KDE on HUAWEI Matebook

I guess it loads the correct drivers:

[    3.808556] acpi PNP0C14:02: duplicate WMI GUID 05901221-D566-11D1-B2F0-00A0C9062910 (first instance was on PNP0C14:01)
[    4.504544] input: Huawei WMI hotkeys as /devices/platform/huawei-wmi/input/input20
[    4.516281] input: Huawei WMI hotkeys as /devices/platform/huawei-wmi/input/input21

Offline

Board footer

Powered by FluxBB