Subject: Re: ATX power button
To: Michal Pasternak <michal@pasternak.w.lub.pl>
From: Manuel Bouyer <bouyer@antioche.eu.org>
List: port-i386
Date: 04/27/2002 12:43:31
On Sat, Apr 27, 2002 at 10:37:35AM +0000, Micha? Pasternak wrote:
> Manuel Bouyer [Sat, Apr 27, 2002 at 12:14:58PM +0200]:
> > On Fri, Apr 26, 2002 at 11:31:18PM +0200, Julio Merino wrote:
> [...]
> > > And the real question: could I change the button function to do a
> > > 'shutdown -p halt' instead of the suspend?
> > Rigth now I'm not sure it's possible.
> 
> I notice, that NetBSD pops out a message on console, when I press the power
> button, then the computer shuts.. so it seems possible for me, at least on
> my box.

Yes, the event is probably reported by APM. But I don't think you can get
the button event itself, only APM events. When you get the APM event
I suspect it's too late, the machine is already in process of being powered
down of put in suspend mode.

-- 
Manuel Bouyer <bouyer@antioche.eu.org>
--