Measuring noise and sound loudness

Measuring noise and sound loudness

A sound pressure sensor, or noise sensor, is one of those sensors that we've been asked for several times, but don't yet offer. The small on-board processors we use in our modules don't have the computing power to make this measurement, and until now we haven't found an external component we could integrate that met our quality criteria. But there is hope that this will change...



Let's start at the beginning: what exactly do we mean by a sound level sensor, and why is it complicated to measure loudness?

Sound pressure

The physical quantity corresponding to the loudness is called sound pressure. It is the amplitude of the sound wave, measured relative to the human audibility threshold, and given on a logarithmic scale, in decibels (dB): the sound power is multiplied by 10 each time 10 dB is added.

  • 0 dB corresponds to a pressure of 20 micropascals, the threshold of human sensitivity at a frequency of 1 kHz;
  • 40 dB is the sound pressure level in an almost silent room;
  • 80 dB is the noise level generated by road traffic;
  • 120 dB is typically the pain threshold, with a high risk of injury.

So far, so simple.

A microphone can be used to measure the amplitude of the sound wave. Where it gets complicated is that there is no such thing as a microphone with uniform sensitivity across all frequencies. The measured waveform must therefore be broken down by frequency, and a specific correction applied to each frequency band, based on a calibration carried out using reference instruments.

What's more, to ensure that the measurement is representative of human perception, the total amplitude of the sound wave is not considered, but frequencies are weighted according to the sensitivity of the human ear. A sound level meter therefore generally offers several measurements:

  • in dB(A), according to the classical weighting for the sensitivity of the human ear;
  • in dB(C), according to an extended weighting to take better account of low frequencies;
  • in dB(Z), for an unfiltered measurement.

This explains why the small 16-bit processors on board our transducers cannot by themselves perform the calculations required to implement a sound level meter.

However, we recently came across a small I2C module on the Internet that does just that: the I2C Decibel Sound Level Meter Module, manufactured by PCB Artists.

The I2C sound level meter module manufactured by PCB Artists
The I2C sound level meter module manufactured by PCB Artists


As it's an I2C module, it can easily be used with a Yocto-I2C. Let's see how...

Testing the I2C Decibel Sound Level Meter Module

The module operates on I2C 3.3V. There's no need to connect the INT pin, so you can connect the module to the Yocto-I2C like this:

Connection diagram
Connection diagram


There are several variants of the module, depending on the price you're prepared to pay, the use of an external microphone, etc. Let's start with a basic configuration of the Yocto-I2C parameters, which works with all variants:

Basic I2C settings
Basic I2C settings


The configured communication job is used to automatically poll the sensor. Given that the module's I2C address is 0x48 and the current decibel measurement is in register 0x0A, the job consists of a single task:

Task for reading current decibel value
Task for reading current decibel value


We found the Pro variant of the module particularly interesting:

  • it simultaneously provides measurements in dB(A), dB(C) and dB(Z)
  • it provides time-normalized values LApk, LAeq, etc.
  • it provides measurements with a resolution of 0.01 dB (rather than 1dB)
  • it provides an overview of frequency bands by octave
  • it has a better coverage for low frequencies (up to 20 Hz)

The Pro variant supports 400 kbit/s communication. The Yocto-I2C configuration can be changed accordingly. To read all three values in dB(A), dB(C) and dB(Z) at once, including their two decimal places, you can do a job with a custom protocol:

writeLine "@48:0Axxxxxxxxxxxx"
expect "48:{A}{A} 48:{A}($dBA:BYTE)($dBAdec:BYTE)
                           ($dBC:BYTE)($dBCdec:BYTE)
                           ($dBZ:BYTE)($dBZdec:BYTE).*"

compute $1 = dBA + (dBAdec / 100)
compute $2 = dBC + (dBCdec / 100)
compute $3 = dBZ + (dBZdec / 100)


You can then use Yocto-Visualization to obtain a real-time graph showing the evolution of sound pressure. Here's an example of measurements taken while playing an ascending and descending chromatic scale over a few octaves, using a Yocto-MaxiBuzzer placed a few tens of centimeters away:

Amplitude measurement on a chromatic scale
Amplitude measurement on a chromatic scale


We see that the sensor does a good job of showing amplitude variations due to the loudspeaker resonance frequencies, and that the measurements are consistent with the values given by a calibrated sound level meter placed next to the sensor.

Comparison with a calibrated sound level meter
Comparison with a calibrated sound level meter



Conclusion

This little sound level meter module is clearly a compact and affordable solution for measuring sound pressure and easily obtaining credible measurements. It won't replace a certified instrument for applications with legal requirements, but is a perfect example of a pragmatic solution that provides credible measurements for rapid assessment or continuous monitoring of a sound environment.

Add a comment No comment yet Back to blog












Yoctopuce, get your stuff connected.