Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have some battery problems with my MacBook Pro so i found out, that a battery calibration might be helpful (my battery has only 300 cycles jet.) The apple support advice (http://support.apple.com/kb/HT1490)

First I have to charge it full, then rest, then use all the battery have. So my question is how to reduce the battery as fast as possible. using much power by working is one way, but can't the machine do this. I think arround nested for-loops, but might there are better ways.

thanks for your creative ideas Simon

share|improve this question

migrated from stackoverflow.com Jun 29 '10 at 18:07

This question came from our site for professional and enthusiast programmers.

    
Play some video through Flash .. –  stuartd Jun 29 '10 at 18:03
2  
I doubt it helps: shouldn't calibration teach the processor on your battery how the battery behaves in normal conditions? Going into extremes might give you the wrong calibration, if you'd ask me. –  Arjan Jun 29 '10 at 18:13
    
Grab your download history, then in one thread go through it downloading every page and placing them on a stack, and in (number of processors - 1) threads go through each page doing complex maths on them. Use a wireless connection, and output data as fast as you can. –  Phoshi Jun 29 '10 at 19:50

7 Answers 7

This should peg your CPU at 100% with no problem. That should cause some heat generation and then your fans will kick in. The only downside is that your computer will become next to un-usable.

Code is C#:

static void Main(string[] args)
{
    int a = 0;

    while(true)
    {
        if(a == 0)
        {
            Thread t = new Thread(() =>
            {
                while (true)
                {
                    a = 1;
                }
            });

            t.Start();
        }
    }
}
share|improve this answer
    
Hehe, neat! With migrated questions I can vote on answers twice - once in the old site, once in the new one. :) –  Vilx- Jun 29 '10 at 18:13

I found running the fans at maximum speed was a fairly fast way to drain the batteries. You'll probably need an external app to do that (I used http://www.macupdate.com/info.php/id/23137/fan-control). Try to max both the fan and cpu speed and that should do the trick.

share|improve this answer
    
Along the way you might also exercise other components as well. Try doing a lot of hard drive seeking, turn up the monitor brightness, run some heavy metal music from a CD/DVD at maximum volume. If the computer has a decent VGA (sorry, I'm not an Apple guy) you could run some 3D benchmark as well. –  Vilx- Jun 29 '10 at 18:24

in a few different terminal tabs, type

echo 'scale=100000; 4 * a(1)' | bc -l

might as well compute some pi while draining the battery

share|improve this answer

In the Powah programming language:

Jets.MaximumBurn()!
share|improve this answer

Besides just CPU usage remember any wireless will also drain the battery pretty fast. If you have a wireless card download a linux distro. If you have bluetooth sync a big file with your phone.

Adjust power settings to not let monitor turn off, display can be a huge drain. Plug in as many external USB devices as you can which use power.

There's a ton of things you an do besides just running the CPU at max.

share|improve this answer

Something that puts your laptop CPU at 100% for hours is also likely to overheat it if you aren't careful. I would also avoid anything that writes to the hard disk because you don't want it active when the machine runs out of juice. Just pop in a DVD an put it on repeat. Spinning the disk and displaying video are good draws. Also set the display brightness to maximum (In my experience the display uses the most power after the CPU.)

share|improve this answer

Put your brightness at maximum and turn Bluetooth on. Stream a lot of YouTube videos and play some graphic-intensive Flash games to pass the time.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.