Hi All. This is my first post so be gentle with me
I'm building a PCB using an Atmega1284 (essentially it's an Arduino) and have need of an audio amplifier.
Previously, I was using a very simple amplifier arrangement using a single transistor and an 8ohm speaker.
Schematic below:
However, using a single 150mah lipo battery, the battery would only last on average for 40 minutes.
If I remove the amplifier and speaker from the circuit, then the battery lasts for 8.5 hours on average.
Clearly, my current amplifier setup is extremely inefficient so I'm looking for a better circuit.
I found that if I replace the speaker with an electromagnetic buzzer (and include a flywheel diode - schematic below), then I get 1 hour 40 minutes out of the battery (more than double the battery life with a speaker).
Using an LM386 instead of the transistor, I get nearly 4 hours of the battery. So battery life is fantastic, but there is very little amplification and it requires many external components which is a big concern given the extremely limited space on my PCB.
I've also tried an Adafruit PAM8302 breakout. This gives the loudest sound from the buzzer but battery life is poor at just under an hour.
Using a TPA2005D1DGN I get slightly over an hour. I was very surprised by both of these given that they are class D amplifiers.
So as it is, the best solution I have is a single transistor and flywheel diode across the buzzer.
So this brings me to my question. I've been reading about class A, B and AB amplifiers and from what I've understood it should be fairly easy and without too many components to modify my original circuit and make it a class AB amplifier. However, what I haven't been able to understand is how to calculate resistor and capacitor values for the class A or class AB amplifier and wondered if somebody could help me here?
If a kind person could do the calculations for me and explain how they did it then that would be amazing! Some values which might help here:
Thanks in advance,
Glyn
I'm building a PCB using an Atmega1284 (essentially it's an Arduino) and have need of an audio amplifier.
Previously, I was using a very simple amplifier arrangement using a single transistor and an 8ohm speaker.
Schematic below:
However, using a single 150mah lipo battery, the battery would only last on average for 40 minutes.
If I remove the amplifier and speaker from the circuit, then the battery lasts for 8.5 hours on average.
Clearly, my current amplifier setup is extremely inefficient so I'm looking for a better circuit.
I found that if I replace the speaker with an electromagnetic buzzer (and include a flywheel diode - schematic below), then I get 1 hour 40 minutes out of the battery (more than double the battery life with a speaker).
Using an LM386 instead of the transistor, I get nearly 4 hours of the battery. So battery life is fantastic, but there is very little amplification and it requires many external components which is a big concern given the extremely limited space on my PCB.
I've also tried an Adafruit PAM8302 breakout. This gives the loudest sound from the buzzer but battery life is poor at just under an hour.
Using a TPA2005D1DGN I get slightly over an hour. I was very surprised by both of these given that they are class D amplifiers.
So as it is, the best solution I have is a single transistor and flywheel diode across the buzzer.
So this brings me to my question. I've been reading about class A, B and AB amplifiers and from what I've understood it should be fairly easy and without too many components to modify my original circuit and make it a class AB amplifier. However, what I haven't been able to understand is how to calculate resistor and capacitor values for the class A or class AB amplifier and wondered if somebody could help me here?
If a kind person could do the calculations for me and explain how they did it then that would be amazing! Some values which might help here:
- I'm using a single Lipo battery so typical output is 3.7v.
- The Atmega1284 is using a single pin to generate the audio signal (a square wave). Max RMS current draw on the pin is 20ma, absolute max is 40ma.
- I haven't yet decided which buzzer I'm going to use, but typical resistance seems about 25ohms. If I can make the amplifier more efficient then I may go back to my original speaker.
- The transistor I'm currently using is a MMBT2222A but I can change this if required. This is an NPN and I haven't looked for a matched PNP.
Thanks in advance,
Glyn