Page 1 of 1
shutdown
Posted: Sat Feb 18, 2006 4:31 am
by xyjamepa
i want to know how can i make command "shutdown"
without IRQ 0x19
Re:shutdown
Posted: Sat Feb 18, 2006 4:42 am
by Pype.Clicker
you know we have a
FAQ, don't you ...
i suggest you check:
http://www.osdev.org/osfaq2/index.php/PowerManagement
http://www.osdev.org/osfaq2/index.php/TimRobinson
APM and ACPI typically offer "shut down" code through BIOS interrupt #15. If that still don't suits you, i suggest you delve into ACPI and APM specifications and see if there's another method, but do not expect to find something like
Code: Select all
POWER_MANAGEMENT equ 0xcafe
SHUTDOWN equ 0xbabe
mov ax, SHUTDOWN
mov dx, POWER_MANAGEMENT
out dx, ax
because this does not exists -- not something that would work on all systems, at least so you're better to switch back to real mode and issue the INT 15 call...
Re:shutdown
Posted: Sat Feb 18, 2006 4:18 pm
by earlz
well see theres a problem with that too, int 15h only does a soft reboot not a turn off
Re:shutdown
Posted: Sat Feb 18, 2006 5:13 pm
by Candy
Jordan3 wrote:
well see theres a problem with that too, int 15h only does a soft reboot not a turn off
There's a byte in non-volatile cmos ram (in the rtc iirc) that indicates to the int15/19 handler (after reboot) what to do. Strictly speaking you're right, but you can instruct it to turn off for you.
Re:shutdown
Posted: Sun Feb 19, 2006 2:27 am
by xyjamepa
i need somthing clear and simple beacuse i didn't understand anything so i need some comments please....
i 'll be so gratefull
Re:shutdown
Posted: Sun Feb 19, 2006 4:23 am
by Pype.Clicker
again:
Shutting down is the matter of ACPI. Check out ACPI BIOS services: it's all in there. It can be hardly clearer than
tim's code once you know how those BIOS call works.
Re:shutdown
Posted: Sun Feb 19, 2006 7:41 am
by distantvoices
Yeah, Tim's code is good.
@abuashraf: you may read the source snippets we point you to more than once. If you don't understand something, you are invited to make clear WHAT you don't get, ok? English isn't you native tongue, is it? Ok, mine it isn't either.
Just to make it clear: we canna read thoughts. So point out what's so difficult for you.