1

I have a Matias wireless mac keyboard (US layout) and while in Mac the fn keys work fine, for example, Fn + F12 works as volume up, however I have switched to linux on my desktop and in Debian (stretch 9.8) this is not the case and registers the key as F12.

What I Tried

  • Using xev to get the keycode and it doesn't change when the fn key is changed or not. F12 will give keycode 96 even if the Fn key is pressed

  • Changing the keyboard layout. I have changed the keyboard layout in the settings in Gnome Settings > Region & Language > Input Sources to various English setting including those with mackintosh in the name.

  • echo 2 > /sys/module/hid_apple/parameters/fnmode I have tried to change the settings as stated in the Arch wiki (https://wiki.archlinux.org/index.php/Apple_Keyboard) and an ls of /sys/module looking for folders with hid gives hid hid_apple hid_generic hidp usbhid However this command does not fix the problem and came up with file not found until I plugged in a real apple keyboard which the function keys work correctly, eg. F12 will give key code 96 but when Fn is pressed it will give 123.

Also, if this issue requires switching to Arch, I would be willing to do so as I use the function keys a lot and usually have ctrl and some function keys mapped to macros.

0

Go into settings then keyboard and then scroll down to the Sound and Media section. In there is Volume up and Volume down, change the key to the key you want. You can set it to a single function key like just F12, or Fn + F12 like you are hoping.

  • I have tried doing that, however the problem is if I try to map Fn+F12, it still registers as F12, not Fn+12 or Media Up – The Cracker Feb 19 at 0:03
  • And your doing the remap from the intended keyboard? So why not just map it to F12 like in the answer? – Michael Prokopec Feb 19 at 3:34
  • Because I would like to have F12 used as just F12 and Fn + F12 used as volume up – The Cracker Feb 19 at 11:09
  • Does the Fn key on the wireless keyboard output the same xev numbers, if not did you configure the function by pressing the Fn and F12 key on the wireless keyboard? – Michael Prokopec Feb 21 at 2:59
  • I have to look into this myself it might just be that it is a measure taken to prevent USB Rubber Ducky, and Bash Bunny type attacks on Linux. Because those devices masquerade as HID devices, and most attacks utilize th Fn or Super/Windows Key or the function keys directly like to call up a terminal then inject code and hit enter. – Michael Prokopec Feb 21 at 3:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.