

A Piezo Speaker is a type of audio output device that uses the piezoelectric effect to produce sound. It converts electrical signals into mechanical vibrations, generating sound waves. These speakers are known for their compact size, low power consumption, and ability to produce a range of frequencies.








| Parameter | Value |
|---|---|
| Operating Voltage | 3V to 12V |
| Operating Current | Typically < 20mA |
| Frequency Range | 2 kHz to 5 kHz (varies by model) |
| Sound Pressure Level | ~85 dB at 10 cm (varies by model) |
| Dimensions | Compact, typically 10-30 mm |
| Mounting Type | PCB mount or wire leads |
| Pin Name | Description |
|---|---|
| Positive (+) | Connects to the positive terminal of the power supply or signal source. |
| Negative (-) | Connects to the ground or negative terminal of the power supply. |
Basic Connection:
Driving with a Microcontroller:
Example Circuit:
Microcontroller Output Pin ---- Resistor ---- Positive Pin of Piezo Speaker
Ground ------------------------- Negative Pin of Piezo Speaker
Below is an example of how to use a Piezo Speaker with an Arduino UNO to generate a tone:
// Piezo Speaker connected to pin 8
const int piezoPin = 8;
void setup() {
// No setup required for basic tone generation
}
void loop() {
// Generate a 1 kHz tone for 500 ms
tone(piezoPin, 1000, 500); // tone(pin, frequency, duration)
delay(1000); // Wait for 1 second before repeating
// Generate a 2 kHz tone for 300 ms
tone(piezoPin, 2000, 300);
delay(1000); // Wait for 1 second before repeating
}
tone(pin, frequency, duration): Generates a square wave on the specified pin at the given frequency (in Hz) for the specified duration (in milliseconds).delay(ms): Pauses the program for the specified time in milliseconds.No Sound Output:
Distorted Sound:
Low Volume:
Overheating:
Q: Can I use a Piezo Speaker without a microcontroller?
A: Yes, you can use a signal generator or a simple oscillator circuit to drive the speaker.
Q: What is the difference between a Piezo Speaker and a Piezo Buzzer?
A: A Piezo Speaker requires an external signal to produce sound, while a Piezo Buzzer has a built-in oscillator and produces sound when powered.
Q: Can I generate multiple tones with a Piezo Speaker?
A: Yes, by varying the frequency of the input signal, you can produce different tones.
Q: Is it safe to connect a Piezo Speaker directly to a microcontroller?
A: Yes, as long as the current and voltage are within the microcontroller's and speaker's limits. Use a resistor if needed for protection.