In TidBITS #183, I gave a brief account of a simple solution to a common Duo problem - poor contact between the battery and the Duo, resulting in frequent shutdowns. The solution, to rehash for a moment, was to reach into the Duo with a small, non-metallic object and carefully bend the power leads up so they would make firmer contact. And it worked.
For a while, anyway. One day, my Duo shut down again, and I cleverly thought, "Aha! The leads need a little more encouragement."
Well, I learned something. I learned that it is, in fact, possible to bend one of the leads just far enough that, when you push the battery in, the lead will bend the wrong way and flatten against the back of the battery chamber. It is then very difficult to bend it back. So be warned that this little fix can fix you but good.
Now, you might be interested in a bit more helpful info on the problem. Some Duos do indeed have a problem with the battery connections. Apple knows about it, but hasn't deigned to tell the world. Apparently the foam pad under the leads isn't quite thick enough in some cases, and doesn't provide enough resistance. However, if you call Apple at 800/SOS-APPL and describe your problem, they will send you a prepaid shipping box and return your machine in several working days, (in my case anyway) complete with a new logic board and new rubber bumpers for the sides of your machine. The woman I spoke to was extremely friendly and helpful, and my machine arrived back a day earlier than expected.
Also, you may be suffering from this shutdown problem even if there isn't anything wrong with your power leads. Apple sanctions this fix (they just forgot to put it in the manual), so try it without fear (if you're still nervous, talk it over with Apple first):
Take your battery out.
Note that the battery shutter appears to be all the way in the "open" position.
Ignore this fact, and slide it another quarter-inch in the "open" direction. You will have to pull hard the first few times, but it loosens up later. You'll hear a loud snap, and then the shutter will stop again.
Resting it on a table or some such object, tilt the Duo carefully back onto its back edge.
Carefully slide the battery most of the way into the compartment, then drop it the last half-inch. Really. That's how Apple's repair folks do it.
When finished, the seam between the battery and the Duo's case should be indistinguishable from the seam on the other side of the mouse button.
If you don't follow these steps, the battery does not seat correctly, and you get - surprise! - poor contact with the leads.
I apologize for the bad advice last time and hope nobody suffered from it. Give the battery trick a try and see what happens. If you still have problems, call Apple and have your machine fixed, quickly and for free. I did, and I didn't turn to dust without my machine, much to my surprise.