7

I am trying to get the Fn+F5 and Fn+F6 buttons to work on my ASUS UX305F laptop running Ubuntu 14.04. I have tried adding all of the following to /etc/default/grub without success:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_backlight=vendor"
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_osi=Linux"
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_osi="

I have even tried mixing and matching some of them. Each time I ran sudo update-grub and restarted my computer only to be disappointed yet again. I also found that running acpi_listen produced no output when I pressed the keys leading me to believe that they are not captured. How can I fix this issue?

EDIT:

acpi_listen pressing F5:

^[[15~

acpi_listen pressing Fn+F5:

No output

xev pressing F5:

KeyPress event, serial 37, synthetic NO, window 0x5000001,
    root 0x9b, subw 0x0, time 41144271, (1,436), root:(783,488),
    state 0x0, keycode 71 (keysym 0xffc2, F5), same_screen YES,
    XLookupString gives 0 bytes: 
    XmbLookupString gives 0 bytes: 
    XFilterEvent returns: False

KeyRelease event, serial 37, synthetic NO, window 0x5000001,
    root 0x9b, subw 0x0, time 41144399, (1,436), root:(783,488),
    state 0x0, keycode 71 (keysym 0xffc2, F5), same_screen YES,
    XLookupString gives 0 bytes: 
    XFilterEvent returns: False

xev pressing Fn+F5:

No output

EDIT 2:

Bug filed here for reference: https://bugs.launchpad.net/bugs/1458351

15
  • 1
    What do you mean by Fn+5 key? Do you mean you are pressing Fn key (which is alongside the Alt or Ctrl key) and the 5 numeric key? It will not send any special signal to your system. It will only send 5 to your system. Fn keys are hardware encoded. They don't work this way.
    – shivams
    May 26, 2015 at 5:07
  • @shivams: You might post your comment as an answer. This is not the first time that the question of mapping Fn has come up, and it's always the same answer.
    – harrymc
    May 26, 2015 at 6:07
  • @harrymc Wonder why he has awarded a bounty for that. Anyways, I'll post an answer.
    – shivams
    May 26, 2015 at 6:39
  • @shivams Please see edit May 26, 2015 at 11:10
  • @cabellicar123 Okay i got that.
    – shivams
    May 26, 2015 at 13:19

2 Answers 2

6
+25

This is not how Fn keys work. If you press Fn+5, it is not going to send any special signal to the system. It is only going to send 5 as the keystroke.

The thing to understand here is that Fn keys are hardcoded in your laptop keyboard. So, if you press Fn key with, let's say F5 key, and if F5 key has a small icon below it marked as mute, then it is going to send a special signal (which will mute your speakers, if everything is properly set).

If you combine your Fn key with any other key on the keyboard which have no special markings for Fn key, it is not going to send any special signal.

6
  • Fn+F10 (mute), Fn+F11 (vol down), Fn+F12 (vol up) all function correctly and have recorded signals in acpi_listen along with other function keys May 26, 2015 at 11:06
  • In addition the F6 key and F7 key both have little icons and worked correctly with the Fn key when running windows May 26, 2015 at 11:14
  • @cabellicar123: For most laptops, Fn+F10 etc. get translated by the keyboard firmware into a virtual-key code. You cannot map Fn, but you can map these virtual-key codes. Unfortunately, only some Fn combinations are handled by the keyboard firmware, and for the rest the result is undefined and most probably not what you are looking for.
    – harrymc
    May 26, 2015 at 14:29
  • @harrymc My question is why the keys worked then for windows. Wouldn't that indicate the keys were being mapped and that somehow Ubuntu isn't recognizing these codes? May 26, 2015 at 14:39
  • You might add more information about what works on Windows that doesn't on Ubuntu. It might however be that Windows is relying less on the keyboard firmware than Ubuntu and so is using lower-level keyboard functions.
    – harrymc
    May 26, 2015 at 14:43
2

Can you set your brightness without using keyboard shortcuts? If yes it's not a grub or acpi issue.

You actually need to set keybindings to brightness functions, common media keybindings are included by default, but in your case your brightness keybindings are not. Configure them by using Dconf Editor.

https://wiki.ubuntu.com/Keybindings

2
  • I can set brightness in system settings but shouldn't acpi log the events? May 26, 2015 at 16:19
  • @cabellicar123: After Windows boots, the BIOS/UEFI is almost totally unused. Maybe that's the difference with Ubuntu.
    – harrymc
    May 26, 2015 at 19:16

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .