From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to record audio in decibels?

The USB microphone is in fact its own sound card. And the values it returns are almost certainly "related" to voltage but not voltages. Most sound cards won't even give you a value that is in anything near voltages and even if it would, the voltage of what? It depends a lot what type of microphone you have if it produces microvolt, millivolt or something else. And then there is an amplifier needed that increases the level of the signal in order that it can be processed by an AD converter. If you are lucky you can find out the microphone sensitivity AND that amplification factor AND the ADC range so that you can calculate some meaningful sound pressure from the returned value.

 

https://mynewmicrophone.com/microphone-sensitivity/ explains a bit about the microphone sensitivity. Do you have such a value like the "32 dB re 1 Volt/Pascal" for your USB microphone? Do you know the amplification inside the microphone? And the voltage range of the ADC and the number of bits of the used ADC?

 

Generally you will probably receive integer values that correspond to the ADC bit numbers. If it is a 16 bit ADC you would receive numbers of +-32535 that correspond to the voltage input range of the ADC which could be for instance +-2.5V.

 

The data sheet for your Blue Yeti micropone does specify a sensitivity of 4.5mV/Pa and that it uses 24 bit ADCs. But it does not state anywhere what amplification is used between the microphone and the ADC and neither what the range of the ADC is nor if the numbers you receive from the Windows audio driver are scaled in voltage, cheese or ADC bit units and even if it is in voltage, which voltage? That at the microphone, at the ADC input? Or something else?

 

Even if all these informations are known (for professional pistophones for instance which cost quite a bit more than this Blue Yeti), if you really want to do real measurements you still need a calibrated sound source and place it in a known distance from your microphone and then measure the analog signal, relate it to the Pressure Level of the source in Pa and also adjust for the distance to the microphone and then you can calculate a calibration value that allows you to calculate Sound Pressure Level (SPL) in respect to the measurement in ADC bits that your sound input gives you. Treating those digitized numbers from the sound API as voltage or millivolt or Pascal is simply guessing with a several 100% margins.

 

Also note that your microphone specifies a maximum SPL of 120dB, and that is the sound of a jet engine at about 100 m distance. And yes that definitely hurts.

 

SPL is usually calculated as:

 

SPL(dB) = 10 * log(p^2/p0^2)

 

p0 is the reference pressure which is usually chosen as 20 uPa, which is considered the minimum value humans can still hear.

 

Not all standards use this exact same reference pressure though. It depends a bit on the type of measurement you want to do and the standardization body that determines the methods to measure a specific sound. Underwater measurements have often different scales, since water has different acoustic properties.

 

Anyways if you talk into your microphone with a normal voice and your calculated signal results in much more than 60 dB SPL, your (nonexisting) calibration is definitely wrong.

Rolf Kalbermatter
My Blog
Message 11 of 11
(292 Views)