Skip to content

Instantly share code, notes, and snippets.

@Joao-Peterson
Last active October 10, 2024 05:07
Show Gist options
  • Save Joao-Peterson/dbd6ee1abe480afd6094d266af7ab051 to your computer and use it in GitHub Desktop.
Save Joao-Peterson/dbd6ee1abe480afd6094d266af7ab051 to your computer and use it in GitHub Desktop.
Using GMK67 keyboard in linux. Function keys not working with Fn!

GMK67 with Archlinux!

Recently i bought a zuoya gmk67 keyboard, it doesn't have a function keys row and has a knob for volume control. Unfortunately, if you plug your gmk67 in a archlinux machine you will notice that using fn+1 will not produce f1 as expected, it will produce a screen brightness decrease, and if you change the physical switch in the back for the macOS mode, the function keys now work, but the modifier keys don't, quite stressful.

Fear not, you can either alter your system configuration so the keyboard functions normally, as in this gist, or remap the keys, as seen in the gist Using GMK67 keyboard in linux with key remaps!.

For this gist we are going to alter the configuration for the apple hid driver on archlinux, since this keyboard uses it, and alter the functionality of the Fn key.

This is tested on archlinux, for any other distro you might have to figure out yourself the correponding commands!

First write the following file as root:

/etc/modprobe.d/hid_apple.conf:

options hid_apple fnmode=2

Then rebuild the initramfs:

$ sudo mkinitcpio -p linux 

And boom, know everything should work as intended, thanks @butterdori for the tip!. More info on the arch wiki:

Apple Keyboard - Function keys do not work

@Joao-Peterson
Copy link
Author

Thanks for the info. I renamed this to just Archlinux since this is the distro I found the problem. Glad to know it works out of the box in Ubuntu!

@jai343272
Copy link

On ubuntu 22.04, u just need to change the keyboard language to English (US, intl. with dead keys) and everything works fine.

Is your keyboard knob working properly? Mine does not have any response.

@nozonyan
Copy link

hello I have tried to switch almost every fnmode but my gmk67 still refused to use proper fn functions while in windows mode. Is key remapping the only way?
The keyboard works fine while in USB mode tho.

@George759
Copy link

For Ubuntu 22.04, the only change I made to get it working is found in this page https://help.ubuntu.com/community/AppleKeyboard under Corrections > Change Function Key behavior

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment