Skip to main content
GameDev.net gamedev.net
🔒 Locked

Shutdown Computer

Started by UriKiller Oct 30, 2005 at 8:49 AM 2 replies 400+ views
Original Post
UriKiller
UriKiller
Hello, Which assembler interrupt shuts down the computer if I'm in my own OS. I tried int 0x15, ax = 0x5307, bx = 0, cx = 3. This did nothing... Is there any other way?
ZQJ
ZQJ
I think reboot is relatively straightforward but shutdown I don't think is. You'll have to do it through power management, i.e. either APM or ACPI.
sit
sit
you're aware this will not work in any modern operating system right?
crudbreeder
crudbreeder
According to the "interrupt list" you should use int 15h with BX=0001h (device id for all APM devices)
and either CX=0001h for "standby", CX=0002h for "suspend" (both for APM 1.0 and higher) or CX=0003h for "shutdown" (for APM 1.2 or higher)

Edit: AX should be 5307h in all cases

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.