Site icon Circuit Ideas for You

Jingle Bell Song Circuit with Arduino and Piezo Buzzer

Christmas time feels more fun when music plays, as this project plays the Jingle Bells tune using Arduino Uno.

With Arduino and small buzzer, we can make Jingle Bells tune at home, also its very easy circuit, with very happy sound and is good project for beginners and kids.

Arduino Code:

int buzzer = 10;
int led = 13;

int melody[] = {659,659,659,659,659,659,659,784,523,587,659};
int duration[] = {250,250,500,250,250,500,250,250,250,250,500};

void setup() {
pinMode(buzzer,OUTPUT);
pinMode(led,OUTPUT);
}

void loop() {
for(int i=0;i<11;i++){
tone(buzzer,melody[i]);
digitalWrite(led,HIGH);
delay(duration[i]);
noTone(buzzer);
digitalWrite(led,LOW);
delay(50);
}
}

Code Explanation:

Circuit Working:

Jingle Bell Song Circuit Diagram with Arduino and Piezo Buzzer

Parts List:

ComponentsQuantity
Resistor 150Ω1
Arduino Uno1
RED LED 5mm 20mA1
Piezo Buzzer Small1
5V DC Power supply1

To begin with, the above circuit is an easy project one should give it a try.

Arduino sends sound signals to piezo buzzer from pin 10 and then buzzer vibrates and makes musical notes.

After that, LED blinks at the same time from pin 13 and then R1 resistor stops extra current from reaching the LED; also 5V powers the LED and buzzer and GND completes the circuit.

Formulas with Calculations:

General formula for LED resistor in Jingle Bells Arduino circuit:

Red LED forward voltage = 2V

Safe LED current = 20mA (0.02A)

Arduino output = 5V

Resistor formula:

R = (Vsource – Vled) / I

So R = (5V – 2V) / 0.02A

R = 3V / 0.02A

R = 150 ohms

How to Build:

To build a Jingle Bell Song Circuit with Arduino and Piezo Buzzer follow the below steps:

Conclusion:

To conclude, this project is Jingle Bell Song Circuit with Arduino and Piezo Buzzer, which is with easy steps and short code.

Furthermore, the circuit is good for beginners and school projects and we can change melody numbers to play other songs, which shows how buzzer and LED work with Arduino.

Exit mobile version