Using arduino to calculate and display Decibel values

never mind

This has been discussed & done before and if you search the forum for "SPL" you should get some good hits.

much like this one: http://www.oddwires.com/sound-detector/

Not that one. :wink: That only has a digital-binary output that tells you if the sound level is above or below the preset (but undefined) level.

I would like to ultimately be able to use an SPL meter to calibrate it.

That's normally how it's done. You are not going to get accurate results if you simply go by calculations. ...You may not be able to find the microphone sensitivity specs, and if you do there usually aren't any tolerances given.

My knowledge of audio etc is pretty comprehensive however I am fairly new to arduino and C++ programming.

The programming shouldn't to too hard. The hardest part would be if you do the DSP (A-Weighting) in software. The LCD programming might get a little tricky but there is an LCD library.

I also understand that integrating an a-weighted filter into the device would be preferable.

Then you understand how difficult it is to make a "useful" SPL meter. It's probably impossible to make one for anything other than experimental/hobby/fun use.* A homemade SPL meter probably can't be used for legal or regulatory purposes, and you probably can't find an independent lab that will calibrate a homemade meter.

Would this be best done via programming or by using a circuit?

What's easier for you? Are you better at programming or designing/building analog circuits? (I'm actually not sure if the Arduino is fast enough to do the required DSP.)

  • I've made a VU meter lighting effect, but it doesn't measure 'dB' or anything meaningful and it's intentionally uncalibrated because it continuously re-calibrates itself for lots of "meter action" no matter how loud the music is playing. (And it works from a line-level signal so there's no microphone.)