What buzzer

I've put together a project with a arduino nano, a HC-SR04 and a piezo electric buzzer.
I've set the distance in the code/sketch to pick up any movement and sound the buzzer, which works fine.
But the buzzer sounds like a strangled chicken most of the time, and not very loud, so I would like to use something more solid, or better sound.

As there are many types of buzzers, what would be the best type for my project.


There are buzzers/beepers that have a built-in sound generating circuit. They make sound when you apply DC voltage. A piezo beeper usually puts-out a "clean" sound, but there are buzzers that make "buzz" sounds or sirens, etc.

And, there are speakers/transducers that convert electrical signals to sound. The Arduino (mostly) puts-out "pure-clean" tones (square waves) but a piezo transducer can play music, and there are piezo tweeters.

If you are using a buzzer with the tone() function you could get "odd" results.

Yes i know that there are many types, but which one would be best for use with an Arduino nan and the HC-SR04.

What I find is that the closer to the HC-SR04 the object is, the buzzer beeps / buzzes in a reasonable tone, but the further away it is, then the tone sounds like a strangled chiken.


The hardware people will tell you it's a software problem.


So you are saying it is the sketch that is causing the problem, and needs to be changed somewhere.

If so I'll post the said problem in the appropriate section.