This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Making piezo buzzer sound melodious and smoother using pwm and timer programming

 what parameters should be adjusted for making piezo buzzer sound smoother?

Parents
  • Hi,

    I'm not sure what you mean by "sound smoother"? 

    If you want the piezo buzzer to make different sounds/notes, you will have to change the PWM freq and a PWM output with preferably 50% duty cycle.

    Also, since you are driving a piezo from a PWM, even at the desired frequency, you will probably not get the sound that you want because you are driving a square wave. 

Reply
  • Hi,

    I'm not sure what you mean by "sound smoother"? 

    If you want the piezo buzzer to make different sounds/notes, you will have to change the PWM freq and a PWM output with preferably 50% duty cycle.

    Also, since you are driving a piezo from a PWM, even at the desired frequency, you will probably not get the sound that you want because you are driving a square wave. 

Children
Related