As mentioned above piezo devices are of two types.
One is the bare transducer - which is just a wafer of piezo material with contacts either side. It reacts to an applied voltage like this:
|
(One set of these + and - signs needs to be reversed!) |
... and if you apply DC voltage, then it will just bend in one direction and stay there. To get an audible tone, you need to apply a voltage that varies.
Which leads us to the second type - an active device, which has an oscillator circuit built in.
Advantages of piezo transducers:
- low power consumption for high output
- no back EMF problems
- lightweight
and when you have access to the oscillator circuitry:
- can control volume easily
- can change frequency easily
Electromechanical buzzers are essentially relays wired up to repeatedly turn on and off and they only have one real advantage that I can think of at this moment - you only need a suitable DC power source for them to work.