buzzer driver
buzzer — buzzer driver
The buzzer module is used to control the amplitude and frequency of a buzzer onboard your OpenMV Cam.
Note
The buzzer (and this module) is not present on all OpenMV Cam models.
Functions
buzzer.freq
buzzer.freq(freq: int) -> NoneSets the buzzer frequency independently of the volume.
freq any frequency to drive the buzzer at.
buzzer.duty
buzzer.duty(duty: int) -> NoneSets the buzzer duty cycle independently of the frequency.
duty any PWM duty cycle percentage (0-255 for 0-100%).
Constants
buzzer.RESONANT_FREQ
buzzer.RESONANT_FREQ: intConstant definting the highest volume frequency of the buzzer (typically 4000 Hz).
