Sound Pressure Measurement Using Weighting Filters
This example shows how to apply weighting filters to measure sound pressure. A user interface (UI) allows the user to control various parameters while the simulation is running.
Sound Pressure Measurement
In many applications involving acoustic measurements, the final sensor is the human ear. Thus, most acoustic measurements try to represent the ear's subjective perception of a sound. Instrumentation devices are built to provide a linear response, but the ear is a nonlinear sensor. Special filters, known as weighting filters, are used to account for these non-linearities.
This example uses the splMeter System object to measure sound pressure level. The pressure is computed in reference to a sound pressure of 20e-6 Pascals.
You can perform live sound pressure measurements with a microphone if you have one available. The measurements are performed using a default calibration factor.
You can select the weighting filter (none/A/C) to use for the measurements. For more details on these audio weighting filters, see Audio Weighting Filter example.
soundPressureMeasurementExampleApp is the function containing the algorithm's implementation. It instantiates, initializes and steps through the components forming the algorithm.
Execute soundPressureMeasurementExampleApp to run the simulation and plot the results on scopes. Note that the simulation runs for as long as the user does not explicitly stop it.
soundPressureMeasurementExampleApp opens a UI designed to interact with the simulation. The interface allows you to select an audio source and a filter, and the results are reflected in the simulation instantly. For example, selecting a filter changes the sound pressure level. Notice how the corresponding plot in the TimeScope reflects this change. There is also a Stop button on the UI that ends the simulation.