Categories: Other Amplifier

Class D Amplifier for ATtiny15L

Recently, the widespread use of amplifiers have high efficiency – 90% or more. The sound signal is converted into a PWM (pulse width modulated), which explains their high efficiency, since the output stage while working in a key mode. Modern designs of such amplifiers – a monolithic chip, integrate processor and powerful output stages. Experiment with them, for example, to change the PWM conversion algorithm is difficult.

These units can get acquainted with one embodiment of the amplifier is Class D. Controller ATtiny15L AVR family firm Atmel is perfectly suited for this purpose, because it contains a ten-digit analog-digital converter (ADC) and a timer with a pulse-width modulator (PWM).

ADC reference voltage is selected voltage (register bits ADMUX REFS1 = 0, REFS0 = 0). Signal input of the controller – one of the inputs of the ADC, in this case, the input – 3 (RS 4). PWM output is – OS timer output 1 (PB 1). Auxiliary outputs: RV0 and PB2 commute positive and negative wave signal -, respectively.

For pre-amplification signal required linear gain stage with gain K = 10, and the voltage at its output in the absence of a signal should be half the supply voltage, so the values ​​of resistors R1 and R2 are equal, and the operational amplifier (op amp) TL071 has a large input resistance.

The program uses two interrupts: the timer overflow T1 and at the end of the cycle of the ADC. ADC is configured to equalize the result to the right. At interruption of the ADC result is read into the working registers and shifted one digit to the right, thus, zero discharge of the high byte is the test switching the positive and negative half-waves. Overflow timer is updated contents of the register PWM.

For the signal required to control the bridge output amplifier is designed gate-4 and not (561LA7). The amplifier incorporates composite transistors KT972A, KT973A.

Adjustment of the amplifier should start with the pre-amplifier assembly, first of all, make sure that the output of op amp there is a voltage close to 2.5 V when powered by 5V

The next stage – the firmware of the microcontroller. To flash microcontroller programmer used Tiny15L PonyProg. It is convenient because it requires no additional power source (powered by the COM port of your computer) and does not contain microcontrollers. After programming the controller serve a test signal of 1 kHz from the generator to the input of op amp so that its output amplitude was less than 2 V. The outputs of the microcontroller RV0 and PB2 must be square wave with the same frequency as in PB1 – PWM signal with a frequency of approximately 100 kHz .

Require high sound quality from the amplifier should not be, the controller used in it are not designed to handle the audio signal.

The firmware file is named Amp_t15.hex , the listing file (for fans of programming) Amp_t15.asm .

For writing the program used the standard software from Atmel – AVRStudio version 4.12, the debugging was done using version 3.14 VMLAB.

Download the archive with the files in the format of the scheme PCAD-2002 and firmware of the controller can be here
source :http://www.rlocman.ru

Amplifier Circuit

Recent Posts

10-100W Class-D Power Audio Amplifier Using MD7120 MOSFET Driver

Class-D Power Audio Amplifier Using MD7120 MOSFET Driver This is the circuit design of Class-D…

3 years ago

Active Antenna Amplifier For FM Radio

This is the circuit diagram of active antenna amplifier for FM radio device. With only…

5 years ago

400 Watt 70 Volt Amplifier

This is the schematic design of 400 Watt 70 Volt amplifier capable to deliver about…

7 years ago

150W Power Amplifier using Transistor

This is the circuit diagram of 150W power amplifier which built using power transistors. The…

7 years ago

1000W Stereo Audio Amplifier with Transistors 2SC5200 and 2SA1943

This is the circuit design of 1000W stereo audio amplifier. It is a very good…

7 years ago

150W Car Audio Amplifier

This is the circuit design of 150W car audio amplifier. The circuit is divided in…

7 years ago