LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 05-03-2003, 11:33 PM   #1
Brain Drop
Member
 
Registered: Feb 2003
Location: just outside reality
Distribution: balanced
Posts: 752

Rep: Reputation: 35
how to do standby or suspend with acpi


i normally dont ask to many questions but this has me stumped, ive read all the man pages i can find but cant find anything on this.
i have an hp pavilion xt118 laptop and got acpi working ( have batt meter and will power down ok now) what i want to do is go into standby, suspend and hibernate. in the kde control panel under laptop batt there is a button to setup acpi when i click on it there are three check boxes, standby, suspend, and hibernate. beside each check box is a text box that has a default message that reads 'how to enter standby' or suspend or hibernate. what am i supposed to enter in these boxes? or am i supposed to enter a new event in the /etc/acpi/event? and how would i do that? the one that is in there after install and is called an 'example' is the power button one to call a halt when the power button is pressed. it works fine but i dont know how to add any other event things in there.

and as for hibernate, the only reference i have come across is one that was stating that you need a seperate partition to use to go into hibernate mode but that with kernal 2.5 you can use the swap partition. any information you can tell me about that would be cool too.

and of course ive tried all the sites that are supposed to be for linux on laptops and acpi sites but unless im missing something all the info there seems to be rather dated.
 
Old 05-04-2003, 12:51 AM   #2
rch
Member
 
Registered: Feb 2003
Location: Santa Clara,CA
Distribution: Mandriva
Posts: 909

Rep: Reputation: 48
Re: how to do standby or suspend with acpi

Quote:
Originally posted by Brain Drop
i normally dont ask to many questions but this has me stumped, ive read all the man pages i can find but cant find anything on this.
i have an hp pavilion xt118 laptop and got acpi working ( have batt meter and will power down ok now) what i want to do is go into standby, suspend and hibernate. in the kde control panel under laptop batt there is a button to setup acpi when i click on it there are three check boxes, standby, suspend, and hibernate. beside each check box is a text box that has a default message that reads 'how to enter standby' or suspend or hibernate. what am i supposed to enter in these boxes? or am i supposed to enter a new event in the /etc/acpi/event? and how would i do that? the one that is in there after install and is called an 'example' is the power button one to call a halt when the power button is pressed. it works fine but i dont know how to add any other event things in there.

and as for hibernate, the only reference i have come across is one that was stating that you need a seperate partition to use to go into hibernate mode but that with kernal 2.5 you can use the swap partition. any information you can tell me about that would be cool too.

and of course ive tried all the sites that are supposed to be for linux on laptops and acpi sites but unless im missing something all the info there seems to be rather dated.
A good question I have got after quite a long time.Many come here for answers without searching for them and ask stupid questions
like(how to make a boot floppy).
Yours is a good q!
I have not used the kde acpi crap(i never liked kde) and so i suggest for your kde queries you try their site
First thing first :ACPI is in experimental stage that may mean that it may not work in your machine or make it unstable
So if you are comfortable with APM i suggest you to stick with APM
now things you have to do is to run a acpi deamon :
use a deamon like acpid
get it from rpmseek
next add it in your init script
do a ntsysv and add acpid
now i will tell you about the different stages in acpi
ie the sleep states ,processor states
/proc/acpi would give you the current acpi configuration
the entries in the /proc/acpi will include sleep and CPU0 or simply 0 which controls the
throttling in CPU
what exactly you are seeking is /proc/acpi/sleep
first do a cat /proc/acpi/sleep
it should give you the output like
S0 S1 S4 S5
which prints the ACPI sleep states your system can support
The state S1 is like the suspend state in your windows system
S4 is like the hibernate state in your windows system
now to make your system go to suspend
do
echo 1 > /proc/acpi/sleep
it will print something like this
hwsleep ..blah blah
now your computer is suspended
but you might say your moniter is still on
that is becoz your moniter is not supposed to turn off in suspend stage
you could use the DPMS mode to enable your moniter to suspend or you can manually switch off
the moniter button
to wake up from suspend just press any key and your computer is back in action
i have tried the hibernate stage(doesn't require extra partition) but it did not work in
my computer
(Remember ACPI is in development stage)
There is very few documentation available in the net about linux ACPI if you find one
maybe you can tell me
(or if you are a programmer like me :suggest reading the kernel source to understand its action;
it is usually full of comments so that we could understand what is going on; remember also that intel is
currently supporting acpi in linux;that might mean that other motherboards /chipsets/processor might not work
remember that you have been warned)
 
Old 05-04-2003, 10:42 AM   #3
Brain Drop
Member
 
Registered: Feb 2003
Location: just outside reality
Distribution: balanced
Posts: 752

Original Poster
Rep: Reputation: 35
thanks for your answer, thats what i was looking for.
my system comes back with s0 s3 s4 s5 but writing any of them to sleep is not effective except if i write echo 5 > /proc/acpi/sleep then i lose my cursor. so io guess im going to take the hard road and dig through the kernel a little. or maybe go with software suspend for a hibernate type setup but its just not quite the same.
 
Old 05-04-2003, 11:26 PM   #4
rch
Member
 
Registered: Feb 2003
Location: Santa Clara,CA
Distribution: Mandriva
Posts: 909

Rep: Reputation: 48
Quote:
Originally posted by Brain Drop
thanks for your answer, thats what i was looking for.
my system comes back with s0 s3 s4 s5 but writing any of them to sleep is not effective except if i write echo 5 > /proc/acpi/sleep then i lose my cursor. so io guess im going to take the hard road and dig through the kernel a little. or maybe go with software suspend for a hibernate type setup but its just not quite the same.
I know some guys who use the SysRq key frequently .As for me I have got no idea about the key and its functions.Anyway nice to hear from you.Incidentally what is your machine's specification?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Dell Inspiron 600m ACPI standby/suspend jfromcanada Linux - Laptop and Netbook 1 03-11-2011 02:39 PM
ACPI suspend/standby "not supported" according to KLaptop zensufi Linux - Laptop and Netbook 0 08-03-2004 05:53 PM
Can't suspend or standby!!!!! SlipAway172 Linux - Newbie 1 06-29-2004 08:53 AM
Suspend/Standby hangs in 9.2 thane777 Mandriva 2 10-25-2003 11:26 PM
Coming out ot suspend/standby? Eyecannon Linux - General 2 10-07-2002 09:46 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 05:46 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration