## How to calculate the level of an "AUDIO IN" in dBA?

Aug 14, 2011 at 5:40pm

# How to calculate the level of an "AUDIO IN" in dBA?

Just this. I would like to know how to calculate the level of an AUDIO IN in dBA. I would like to see the values in third octave 125hz – 20khz and graphically.

Its possible??

thanxxxx!

#58475
Aug 15, 2011 at 12:51am

to get A-weighting you need to filter the input using biquad with these arguments:
{biquad~ 0.49735 0. -0.49735 -1.041289 0.109858]

then get the rms value over 125ms

#210127
Aug 15, 2011 at 10:13am

Terry how do you know the arguments of the biquad object?

Is this the global value?? i would like to know the values in a multislider object like the screen of a sonometer.

My object is create a sonometer.

I have searched a sonometer patch but i haven’t find.

#210128
Aug 16, 2011 at 10:22am

nobody?

#210129
Aug 16, 2011 at 11:46am

well I just derived them empirically– you can test the coefficients yourself by plugging the values into filtergraph and see what sort of a curve you get. I did test the filter against a class-A spl meter to see how accurate it was and it seemed to be within less than 1 dB margin of error, which was adequate for my purposes at the time.

as for the other question, you could design a set of cascading fft modules using pfft~, each of which only samples bins 4 to 6 of a different window-size (ie 4096, 2048 ……128, 64), one for each octave

T

#210130
Aug 16, 2011 at 12:52pm

i have seen this post http://www.cycling74.com/forums/topic.php?id=13899

but i dont know what is “af Tf Lu” from the patch.

#210131
Aug 16, 2011 at 1:44pm

that code is about equal loudness, not A-weight which are completely different things, and it’s also written in matlab, which I don’t know…af probably refers to amplitude (a) at corresponding frequency (f), but that’s just a guess

btw my previous post should read ‘bins 3 to 5″, not ’4 to 6″, if you want pseudo 1/3 octave analysis

#210132
Aug 16, 2011 at 2:02pm

But if you use 40 fones you are on A-weight, isnt it?

#210133

You must be logged in to reply to this topic.