• sales

    +86-0755-88291180

The Buzzer - It's just clicking

2024-11-29 21:05:42 Ask

Hi,


I'm trying to get the buzzer to sound, but all I can achieve is a faint clicking noise.

Could you please provide a sample code that would produce a buzzer noise?  

Thanks  

2answers
SpotPearGuest9a52c
Answer time:
2024-11-30 10:39:44

Demo_download

Call lv_timer_handler to have LVGL handle graphical interface tasks;
Read the status of the input pin, and perform debouncing processing;
Based on the state of the button (pressed or released) and the time interval, determine whether it is a single click, double click, or long press event, and update the label text on the display to show the corresponding event information;
At the same time, for the long press event, the buzzer will be triggered, and when released, the buzzer will be stopped and the specific output pin will be set to a low level.

Like0

report

Price: $13.9
Part Number: ESP32-S3-LCD-1.69
Brand: SpotPear