Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 1261

Python • Using a Raspberry Pi 4 to make a bleep type noise

$
0
0
As my family are constantly leaving a door open, I have added a Raspberry Pi 4, running a tkinter program under Python 3. This is activated using a standard Magnetic door switch as used in a Burglar alarm etc and works quite well and I can see the status on my Android phone via Real VNC.
However, I want to make it more obvious that the door is open by introducing a regular noise. Bleeping or anything else that is so annoying they close the door.
I have one of those PAM8302A audio amplifiers and a sugar cube speaker that I could use but I am unsure about how to create the sound to play.
Or could the speaker be connected directly to the 3.5mm Audio output of the Pi and if so how do I create the sound. (preferred option)
I can add any new code into my existing tkinter program.
I would appreciate any help,
Thank you

Statistics: Posted by RDS — Sun Sep 08, 2024 1:28 pm



Viewing all articles
Browse latest Browse all 1261

Trending Articles