avr Control 5V buzzer using mcu and a single 5 V power supply


Posted on Feb 6, 2014

A PB-12N23PW-05Q buzzer and I`m trying to use it with ATmega 162. I can`t connect it directly to pin, because from what I`ve read from 162`s datasheet, it can source at most 20 mA. The buzzer takes 50 (or around 25, if we take a look at the graph), so I don`t think I can just directly connect it to the microcontroller. My initial idea was to connect it to a transistor and use the transistor as a switch. Unfortunately,


avr Control 5V buzzer using mcu and a single 5 V power supply
Click here to download the full size of the above Circuit.

it didn`t work. I used BD237 and my idea was that the microcontroler will pull the pin connected to the base high and the transistor will operate the buzzer. In my setup, I had buzzer connected to Vcc, buzzer`s negative port connected to collector, GND connected to the emitter and 162 connected to the base. Transistor is of NPN type. Somewhere I read that this way some problems related to the voltage drop on the transistor can be mitigated, but to me it looks like the voltage drop is the main problem here. @AndrejaKo The micro does not have a resistor inside the pin. It only has a maximum specified output current which, when exceeded, may release magic smoke. Use Ohm`s law to specify the resistor. joeforker Feb 14 `11 at 22:59 Thank you for posting and linking to exactly which sound-maker you are trying to use: the PB-12N23PW-05Q self-oscillating buzzer. (If you had a raw piezo disk, or a coil speaker, we would use a different drive circuit). If you insist on using a NPN such as the BD237, you need to add a external resistor between the MCU and the base of the NPN, as joeforker mentioned: 1 KOhm should be adequate. But no matter what resistor or silicon NPN transistor you use, you will end up with (at best) a V_ce_sat voltage drop of around 0. 6 V, so the voltage across the buzzer is about 4. 4 V - which is technically outside the "guaranteed-to-work" "4. 5 to 5. 5 V" operating range in the buzzer datasheet. If I were you,...




Leave Comment

characters left:

Related Circuits

  • New Circuits

    .

     


    Popular Circuits

    Password Based Door Locking
    Cold Atom Control System for PC
    Lie detector
    Unijunction metronome
    Simple 2M 6M Transverter Circuit
    lm3914 ic based on simple battery tester
    light activated led scr
    KIA7217AP 5.8W AUDIO POWER AMPLIFIER. CAR STEREO CAR RADIO OUTPUT
    7-segment display counter
    Receiver schematic design using MC3335PSSB



    Top