Jump to content

How do I make a dBA meter in Python?

38034580

Here's my GUI frontend:

from tkinter import *
from tk_tools import *
p = pyaudio.PyAudio()
root=Tk()
root.title('Decibel Meter')
gauge = Gauge(root, max_value=120.0, label='loudness', unit=' dBA', red=83, yellow=67)
gauge.pack()
led = Led(root, size=50)
led.pack()
led.to_red(on=False)
Label(root, text='Too Loud').pack()
root.mainloop()

The red LED will turn on when ambient sound exceeds 85dBA.

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×