

A piezo speaker is a type of loudspeaker that uses the piezoelectric effect to produce sound. It converts electrical energy into mechanical energy, creating sound waves. These speakers are known for their compact size, low power consumption, and ability to produce a range of frequencies.
The Piezo Speaker 2 is a versatile component commonly used in various applications, including:
Its simplicity and efficiency make it a popular choice for hobbyists and professionals alike.








Below are the key technical details for the Piezo Speaker 2:
| Parameter | Value |
|---|---|
| Operating Voltage | 3V to 12V |
| Operating Current | < 20mA |
| Resonant Frequency | 2 kHz to 4 kHz |
| Sound Pressure Level | 85 dB (at 10 cm, 5V input) |
| Dimensions | 20 mm diameter, 10 mm height |
| Weight | ~5 grams |
The Piezo Speaker 2 typically has two pins for connection:
| Pin | Description |
|---|---|
| Positive (+) | Connect to the positive voltage supply or signal output. |
| Negative (-) | Connect to ground (GND). |
Below is an example of how to connect and program the Piezo Speaker 2 with an Arduino UNO to produce a simple tone:
// Piezo Speaker Example with Arduino UNO
// This code generates a tone on pin 9 using the tone() function.
#define PIEZO_PIN 9 // Define the pin connected to the piezo speaker
void setup() {
// No setup required for tone() function
}
void loop() {
tone(PIEZO_PIN, 1000); // Generate a 1 kHz tone on the piezo speaker
delay(500); // Wait for 500 milliseconds
noTone(PIEZO_PIN); // Stop the tone
delay(500); // Wait for 500 milliseconds
}
No Sound Output:
Distorted Sound:
Low Volume:
Overheating:
Q: Can I use the Piezo Speaker 2 with a 3.3V microcontroller?
A: Yes, the Piezo Speaker 2 can operate at 3.3V, but the sound output may be quieter compared to 5V operation.
Q: How do I produce different tones?
A: Vary the frequency of the input signal. For example, in Arduino, you can use the tone() function with different frequency values.
Q: Can I use the Piezo Speaker 2 for playing music?
A: Yes, you can generate musical notes by programming a sequence of frequencies and durations.
Q: Is the Piezo Speaker 2 waterproof?
A: No, the Piezo Speaker 2 is not waterproof. Avoid exposing it to moisture or water.
By following this documentation, you can effectively integrate the Piezo Speaker 2 into your projects and troubleshoot any issues that arise.