How to drive a 8 ohm 0.5 W speaker with a Nano?

Hi,
I have a IR alarm system on the door to my room. Right now I am using a Arduino Nano to drive a watch piezo for the alarm, but you can hardly hear it -- certainly not a startling siren.
I am hoping to hook up a 8 ohm .5 W speaker instead.
What would be the best circuit to amp up the output of my Nano to drive the speaker at a respectable volume?
I do not want to buy to to many (or preferably any [smiley=thumbsup.gif]) components, but I like scrounging so I have quite a few on hand ;).

Thanks

Just google around for audio amplifier, I came up with this 3 - 5 Watt Class-A Audio Amplifier - RED - Page80 which is as good as anything.

do not want to buy to to many (or preferably any Smiley) components

You can't get away with no extra components as the arduino's outputs do not provide enough power.

Thanks for the link. Because I am only amplifying a tone, I don't really need the fidelity of a Class-A amplifier, and my power requirements are also much lower than what that circuit can handle.

Would it work to just run the digital output from the Arduino into the base of an NPN transistor? I would be getting modulated DC at the speaker, rather than an AC signal, but shouldn't that still work for generating a tone?

Is there another reason it wouldn't work to use a transistor in this fashion?

Thanks for your help,
G33K

Because I am only amplifying a tone

It makes little difference what you are amplifying you need the same sort of thing.

Would it work to just run the digital output from the Arduino into the base of an NPN transistor?

With a 8R speaker it would draw too much current if it were just in the collector as a load. You are better off with a push pull circuit and AC coupling into the speaker with a large capacitor. You could also do this with a single transistor and have say a 100R collector load but your tone will sound very harsh.

I suggest you this page which have several amplifier circuits:
http://www.techlib.com/electronics/audioamps.html#LM386

I think I'll build the LM386-based one cause it's very popular and fits power requirements..

the 386 setup at a gain of 200 sounds like nails on a chalkboard, i suggest you look at other setups for that IC on page 5 of the datasheet

http://www.national.com/ds/LM/LM386.pdf

removing the 10uf cap sets the gain at its lowest (20) and its as loud as a telephone answering machine

Hey Osgeld,
thank you for the tip, good pun! a gain of 200 is really overkill.
Now I have to found some cheap speakers plus case and I wonder if it's cheaper to grab some cheap USB PC speakers and fit the LM386 circuit into them. I'll have 9V current available and I think I would fry the built-in amplifier since it's designed to run at 5V