rebinding keys to functions

Mel Flynn mel.flynn+fbsd.questions at mailing.thruhere.net
Tue Sep 15 10:40:14 UTC 2009


On Tuesday 15 September 2009 09:01:00 Roland Smith wrote:
> On Tue, Sep 15, 2009 at 01:38:18AM +0200, Mel Flynn wrote:
> > > Not all of them. My laptop is based on a quite modern cantiga (aka
> > >  centrino2) PM45 chipset (from 2008, according to Wikipedia). The
> > > function keys for changing the creen brightness and sound volume work
> > > OK with FreeBSD, even though xev doesn't see them. So that signal seems
> > > to go directly to the hardware.
> >
> > Most likely not entirely. Having acpidump(8)ed a few laptops, I have seen
> > references to multimedia keys in there. However I know not nearly enough
> > about ACPI to know if the OS can intercept/reroute the bindings. A gamble
> > I would take is to let FreeBSD post itself as a windows variant to acpi,
> > by setting hw.acpi.osname="Windows 2001" in /boot/loader.conf. Then
> > recheck xev.
> 
> What would you see in the acpidump that indicates those keys?

Example, HPDV9000:

                If (LEqual (Local1, 0x07))
                {
                    Store ("Fn+F7 Pressed", Debug)
                    If (LEqual (OSYS, 0x07D6))
                    {
                        If (IGDS)
                        {
                            Notify (\_SB.PCI0.GFX0.DD04, 0x87)
                        }
                        Else
                        {
                            Notify (\_SB.PCI0.PEGP.VGA.LCD, 0x87)
                        }
                    }
                    Else
                    {
                        Store (0x15, SMIF)
                        Store (0x00, TRP0)
                    }


Fn+F7 = screen darker. See the ref to OSYS.
Also:

                    Method (_Q16, 0, NotSerialized)
                    {
                        Store ("!!! DVD/Music Button pressed !!!", Debug)
                        If (LEqual (OSYS, 0x07D6))
                        {
And:
                    If (\_OSI ("Windows 2006"))
                    {
                        Store (0x07D6, OSYS)
                    }

-- 
Mel


More information about the freebsd-questions mailing list