fn+f8 switch video mode does not work (keycodes scancodes keymaps)

Dimitar Toshev mo6eeeb at gmail.com
Wed Oct 12 03:11:50 PDT 2011


On 9 October 2011 21:01, =JeffH <Jeff.Hodges at kingsmountain.com> wrote:
> Hi,
>
> I have a Dell E6500 (with nvidia Quadro NVS 160M GPU) with (k)ubuntu 10.04
> installed (and up-to-date), and upon which I've installed the proprietary
> nvidia driver (which seems to work fine (and sleep works)).
>
> Out-of-the-box most everything seems to work (sound & sound buttons,
> dim/brighten display, sleep button (fn+f1)), however, the display video
> switch
> fn+f8 does not work.
>
> I've groveled through the ubuntu forums and web at large and see that other
> people have noted this but don't (yet) see a documented fix.
>
> fwiw, I also have a Dell D820 upon which I've run (k)ubuntu since ubuntu
> 6.10,
> and it's fn+f8 sleep button has always worked, and upon which I also am
> running
> ubuntu 10.04.
>
>
> So, I've done some poking about on both the D820 and the E6500 trying to
> figure
> out what is going on and what changed between the two systems that might be
> causing this.
>
> AFAICT, at least part of the issue is that they keyboard scan codes emitted
> by
> the E6500 keyboard are different (for at least some of the keys, fn+f8 in
> particular) than they are on the D820. It appears that the ACPI sleep
> initiation is not properly mapped to the  scancodes emitted by the E6500
> keyboard.
>
> For example, if a command shell is the active task (i.e. the insertion point
> is
> sitting at a command prompt), and one presses fn+f8, a character "p" is
> placed
> at the command prompt, as if one had typed "p".
>
> Using acpi_listen to investigate...
>
>  > sudo acpi_listen -c 1
> p
> ^C
>
> The above command should have exited on it's own after receiving an acpi
> event
> for fn+f8, but instead just a letter "p" was echoed and then I cntl-C'd out
> of
> it. For comparison, if I use acpi_listen again and press fn+upArrow (LCD
> brighten)...
>
>  > sudo acpi_listen -c 1
> video LCD 00000086 00000000
>  >
>
> ..the event is received, displayed, and acpi_listen properly exits.
>
> So it seems the that an ACPI event isn't even being generated for fn+f8 on
> the
> E6500. Further poking about shows that the /lib/udev/keymaps/dell file is
> the
> same on both the D820 and the E6500 (should it be? (I'm doubting it)), and
> also
> that some of the various outputs of "dumpkeys" are the same on both systems.
>
> However, using "showkey" on both systems gives markedly different results,
> which are shown below.
>
> Does anyone know what might be going on and what I can do to get fn+f8 to
> properly switch video display on the E6500 ?
>
> thanks,
>
> =JeffH
> ------
>
>
> On the D820:
> ------------
>
>  > sudo showkey -s         # I pressed and released fn-f8 once
> kb mode was RAW
> [ if you are trying this under X, it might not work
> since the X server is also reading /dev/console ]
>
> press any key (program terminates 10s after last keypress)...
> 0xe0 0x56 0xe0 0xd6 0xe0 0x56 0xe0 0xd6
> 0xe0 0x56 0xe0 0xd6
>
>  > sudo showkey           # pressed and released fn-f8 once, after releasing
> enter key
> kb mode was RAW
> [ if you are trying this under X, it might not work
> since the X server is also reading /dev/console ]
>
> press any key (program terminates 10s after last keypress)...
> keycode  28 release    # Enter key release
> keycode 227 press      # pressed fn and nothing showed up here
>                        #  until I also pressed fn8
> keycode 227 release    # while fn was still pressed,
>                        # quickly released and got all three "press-release"
> keycode 227 press      # pairs listed here
> keycode 227 release
> keycode 227 press
> keycode 227 release
>
>
>
>
> On the E6500:
> -------------
>
>  > sudo showkey -s         # I pressed and released fn-f8 once
> kb mode was RAW
> [ if you are trying this under X, it might not work
> since the X server is also reading /dev/console ]
>
> press any key (program terminates 10s after last keypress)...
> 0x9c
> p0xe0 0x5b 0x19 0x99      # Note the "p" char
> 0xe0 0xdb
>
>
>  > sudo showkey
> kb mode was RAW
> [ if you are trying this under X, it might not work
> since the X server is also reading /dev/console ]
>
> press any key (program terminates 10s after last keypress)...
> keycode  28 release  # Enter key release (?)   scancode 0x9c ?
> pkeycode 125 press   # fn ?  scancodes 0xe0 0x5b ?
> keycode  25 press    # f8 ?  scancode 0x19 ?
> keycode  25 release  # f8 ?  scancode 0x99 ?
> keycode 125 release  # fn release ?  scancodes 0xe0 0xdb ?
>
>
> ---
> end
>
> _______________________________________________
> xorg at lists.freedesktop.org: X.Org support
> Archives: http://lists.freedesktop.org/archives/xorg
> Info: http://lists.freedesktop.org/mailman/listinfo/xorg
> Your subscription address: mo6eeeb at gmail.com
>

Hi. My guess would be that fn+f8 sends winkey + p, since that is the
standard "presentation mode" shortcut on windows 7. This would also
explain the 'p' you're seeing.

P.S. sorry for duplicate mail, forgot to cc the mailing list.



More information about the xorg mailing list