Jump to content

Closing the lid on my Dell Latitude


epretorious
 Share

Recommended Posts

Hello, All:

 

I've installed MandrakeLinux 10.0 on my Dell Latitude and have been super impressed. :D

 

There is one nagging problem, however: How can I make my laptop go to sleep when I close the lid? ACPI is enabled at boot time (acpi=on), ACPI & ACPID are both started by default (/etc/init.d/acpi & /etc/init.d/acpid).

Link to comment
Share on other sites

When I boot into Gentoo (this is a dual-boot Mandrake/Gentoo box) it suspends quite normally (without any options passed to the kernel at startup) so I checked the kernel options and found that I compiled APM into the kernel and did not compile APCI into the kernel. So that leaves me asking one question: How do I make APM work on Mandrake?

Link to comment
Share on other sites

Don't use apm!

acpi lets you speedstep the cpu, prolonging battery life!

apm is quite rudimentary, of acpi works, use that.

 

Normally, in kde, you should get an icon on the tray, right click and configure it. You have to initialise it to be able to use all options, just go to the last tab and click the button for the setup. You will have to enter the root password, then you have the options in the other tabs on what to do when you close the lid, etc..

Link to comment
Share on other sites

you can do it all manually too, of course. try it, it's fun :). look in /etc/acpi/events and /etc/acpi/scripts (i think...I'm not in front of a Linux box right now). basically you can put little scripts in events which will get run when certain events happen - power cord plugged / unplugged, power button pressed, lid closed - and in turn will call a bigger script to actually do stuff. This is a brilliantly flexible system that lets you do all sorts of stuff. When I unplug my laptop the CPU throttles down to 3/4 full speed, the backlight is set to its dimmest level, and my hard disk is set to spin down after 30 seconds of no activity (instead of the default 15 mins or so). I can try and post more detailed info later, but you can work it all out yourself with a little hacking about and some google skills :). Start off at http://acpi.sourceforge.net/ .

Link to comment
Share on other sites

  • 1 month later...
BIOS control of things means using apm, if you want acpi (and yes, you want that) your OS will have to deal with things.

 

epretorious, have you managed?

After reviewing the output of `dmesg` I passed the kernel a few arguments at start-up...

%> cat /proc/cmdline
root=/dev/hda1 pci=noacpi acpi=off

...and turned-off apmd...

chkconfig --level 2345 apmd off

...and things usually work as-expected. Sometimes, though (e.g., If my USB mouse is plugged-in) things don't work as-expected. I'm still workin' out the kinks. I may eventually re-compile the kerel. Either way, I'll post the results here for future generations.

Edited by epretorious
Link to comment
Share on other sites

After reviewing the output of `dmesg` I passed the kernel a few arguments at start-up...

%> cat /proc/cmdline
root=/dev/hda1 pci=noacpi acpi=off

...and turned-off apmd...

chkconfig --level 2345 apmd off

...and things usually work as-expected. Sometimes, though (e.g., If my USB mouse is plugged-in) things don't work as-expected. I'm still workin' out the kinks. I may eventually re-compile the kerel. Either way, I'll post the results here for future generations.

I've had increasingly good luck with ACPI lately: Through trial-and-error experimentation I've discovered hotplug seems to be most of the problem (so I disabled it)...

 

chkconfig --level 2345 hotplug off

...and that as long as I change to a TTY before closing the lid the laptop enters sleepmode when the lid is closed and awakens when the lid is opened. (If I close the lid while using X I have to restart X - i.e., Ctrl-Alt-Back - to re-awaken X on TTY7.) Also, if I have a USB mouse plugged-in when I close the lid, it's no longer available after re-awakening. I can live with having to un-plug the mouse before closing the lid, though. :D

Edited by epretorious
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...