Active Buzzer
ioRef component number:
0498
Kind:
Active buzzers
Phys Comp Lab location:
Output: Sound
Description:
Makes a high-pitched beeping sound when powered with a steady (direct current) power source.
Available in the lab:
19
Backstock:
0
Supplier:
Adafruit
Cost:
$0.86
Jump to section:
Active Buzzer
About

Active buzzers have a built-in frequency and loudness, and thus are simple to wire: they only need power and ground. You should power them with DC (not AC, as they need a constant current to produce sound). These are mainly useful for signaling or an alarm.

Getting started
Active buzzer schematic for code below
Active buzzer schematic for code below
const int buzzerPin = 8;

void setup() {
  pinMode(buzzerPin, OUTPUT); // initialize digital pin 8 as an output
}

void loop() {
  digitalWrite(buzzerPin, HIGH); // turn the buzzer on (HIGH is the voltage level)
  delay(1000); // wait for a second
  digitalWrite(buzzerPin, LOW); // turn the buzzer off by making the voltage LOW
  delay(1000); // wait for a second
}
Resources
  • https://www.instructables.com/ACTIVE-BUZZER-WITH-ARDUINO-UNO-R3/
Related parts