This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Simplified Explanation of DRC

Other Parts Discussed in Thread: TAS3108

We are using a TAS3108 in an application which would benefit from using the DRC as a distortion limiter.  I've read the "DRC help" section within TI's PurePath Studio, as well as searched the forums here - including the SLOA148 DRC application note for the TAS57XX.  But, I'm still a bit uncertain of how the available parameters impacts the audio processing. 

 

1) Measurement of Peak or RMS.  I would assume a distortion limiter should use "Peak" as opposed to RMS?  It seems this variable, in conjuction with t_energy, would create a time-averaged/filtered version of the input signal - is that right?

2) Compression Ratio. I'm assuming you would want to set this to the amount of max compression needed for a prescribed amount of distortion with a maximum input? 

3)   Threshold.  Is this used relative to the Peak/RMS measurement version of the signal?  What is 0dB related to, the max output of the DSP (0 dBFS)?  Does it make sense that one could adjust this until the maximum amount of desired distortion was determined using sine waves?

4) t_energy.  Is this the size of the time window for averaging the input signal?  So, for a limiter application, one would want this shorter (100-200 ms) - rather than longer (1000-2000 ms), right?

5) t_decay.  While I understand this would dictact the rate of attack, I am unsure how to determine the attack "slope" (dB/ms) if you will.  Can the slope be calculate based on this variable and the Compression rato?  Thus, 10 dB of compression and 10 ms attack time gives 1 dB/ms rate of limiting?

6) t-release. Same as #5, but with respect to limiter release

 

In general, it seems to create a distortion limiter, I would want to input a signal level where output distortion begins.  I would then lower the DRC threshold to determine where to initiate the limiter at the desired amount of distortion.  I would then increase compression ratio until that distortion is reached through maximum input.  Then attack/release controls the "dynamic agressiveness" of the limiter. 

 

Any other insight or suggestions would be appreciated.

  • Rob,

    It is a very simple 2-knee gain curve that we implemented for TAS3x DRC, which most of the parameters T1,T2, O1, O2, compression ratio are used to control the shape of the curve.  And the gain curve is used to determin the gain that would be used by the signal that falls into that range.  Using peak or RMS is just a different method of estimate signal energy and set the threshold, it won't affect the overall outcome, of course the numbers would be different.

    Have you tried the DRC GUI that comes with the component, since it's very easy to adjust all the parameters using the GUI and then listen to the result, you will have an idea what all the parameters are doing in no time.

    I don't have details about how the parameters work on top of my head, please let me know if you need more info, I could look it up for you.

    regards,

    Susan

  • Hi Susan.  Thanks for the response.  The thresholds and offsets are simple enough.  The dynamic behavior is not. 

    The help file is describing things in terms of parameters that are derived from the variables (?).  I've been working with audio, EQ, and limiters for 15 years, and it was not very clear to me at all how to get what I wanted with the parameters in TI's GUI.  I spent several days experimenting with it on an actual product, using the GUI.

    An example would be t_energy.  You say it doesn't really matter?  If I input a sinusoid signal 10 dB above clipping, t_energy seems to drastically affect the time it takes to get from start of output clipping to low-distortion (limited) audio.  My take away was that t_energy must be averaging the peaks.  The help file says t_energy=-1/((Fs*ln(1-ae)) seconds.  Maybe I'm too far removed from algebra and geometry, but I did not find this explanation all the useful. ;)

    Maybe this forum is not the place to get these sort of answers?  I need to fully understand all the details of these timing variables, in a practical sense.

  • Rob,

    I understand now that there is something that not very explainable from what you observed.  Let me try to explain t_energy.

    TAS uses the averaged absolute value of the incoming signal to estimate the energy, t_energy is the time constant used to calculate this value, so changing it will affect the result of this estimation.  When you use peak, it's the result of the estimation, when you use RMS, it's the result -3dB, just a scaling, that's why I say when using peak or RMS, it won't affect the overall effect.

    ae is a number that is actually used in TAS to calculate the running average: Ex = abs(input)*ae +Ex *(1-ae), which user could put in the number directly from GDE interface, don't need to use GUI.  the equation you listed above, just telling the user how t_energy is used to calculate ae  or visa versa.  In the GUI, user need to input t_energy, then the GUI will calculate the ae and tell TAS how to estimate the energy.

    I am not sure whether I explained clear enough, since it's late, my brain may not function as I presumed.  If there is anything I could help to clarify, feel free to ask.

    Susan

  • To continue our discussion.  If we use "peak", then the DRC is comparing the selected numerical "Threshold" in the DRC GUI to a number which represents the input signal.  That input signal representation is calculated by taking the absolute value of all samples in a time window which starts at t0 and has a width equal to t_energy.  Right?  Which means that the larger t_energy is, the more "averaged" the representation will be, and the slower the limiter will react.  So considering we want a limiter which catches transient peaks of music, one would want to use a fairly small t_energy, right?  A window of one second, seems too long.  A window of 5-30 ms seems more reasonable.  Any expert suggestions from TI on typical limiter settings?

    In an attempt to get beyond t_energy, please help me understand how to determine the attack and release RATE of the limiter, in dB/ms, per my original questions.  Is it fair to say the rate/slope of the DRC's attack is created by the amount of compression and the size of t_attack?  If I want an attack rate of 1 dB/ms, I could use 10dB of compression and 10 ms for t_attack?  Similarly, if I use 20dB of compression, and a 20 ms for t_attack, I get the same RATE of attack, right? 

    The RATE of attack could be approximated on a scope by monitoring the amount of time it takes the output signal to go from visually clipped to unclipped.  Consider a scenario where I have my GUI set to 10dB compression and 10ms for t_attack.   If I input a sin wave known to be 10dB above visual output clipping, then the signal output should return to unclipped within 10ms, right?

    Appreciate your patience.  Honestly, this is probably a 15 minute conversation if I could talk to someone.

  • Rob,

    I think there is something that we need to clarify before going into the details of each parameter:

    TAS3x is a sample based processor, it can't process a block a data, so all the algorithm in TAS3x is sample based, it means that one sample goes into the algorithm, it's processed and produced the result.

    So, based on the above, there is no "window", the estimation of the input power is done using the running average, as I mentioned in the previous post, and t_energy is the time constant to control the decay/attack speed of the estimation. You're right that the short the t_energy, then it's faster for it to be closer to the current signal level, but it would be vulnerable for certain noise, such as a pop or click.  How much it should be set depends on the kind of signal you're working on, the typical frequency range, you know the running average is like LPF the signal, I usually set it at the hundreds of ms range, especially for music, you don't want it to be too small.

    The same goes to t_attack and t_decay, which are used to control the gain application.  the gain is calculated based on the gain curve and the input signal power and then t_attack/t_delay will control the time how fast the calculated gain will ramp in.

    About your scenario, whether it could return to the unclipping level depends on the input signal level into the DRC module and how good you set up the gain curve, if everything is correct, then yes, it should return to the unclipped level about the t_attack time.

    I hope this helps.

    Susan

     

  • Yes, I realize there is no "window" per say - but there is a cumulative average of present and past audio data.  Which is conceptually, a window of data.

    Can you please describe the resulting change of attenuation in terms of a "slope" or "rate?"  This would have units of dB/ms.  I assume the x-axis is time defined by t_attack or t_release.  What is the y-axis?  Amount of compression set in the GUI?  Input signal level - Thresold? 

  • Rob,

    I am not sure I understand your question.   You're right that the resulting change of gain is controled by t_attack and t_release, but I don't know what x-axis and y-axis you referred to.  Do you mean the x and y-axis on the gain curve plot?  x-axis is the input signal power relative to the full scale and y-axis is the gain.

    Please let me know if I answered the wrong question.

    regards,

    Susan

  • If I could post a picture, I would try to better explain.

    Please reference TI's own SLOA148.  Page 3.  Block labeled "Cut Attack/Decay Control".  X-axis is time (ta is attack time).  What DRC parameter controls the y-axis (labeled "Volume")?  Amout of compression? Is the rate of attack really exponential as the drawing suggests?

    Again, this has nothing to do with the regions or thresholds on the GUI.  There is a dynamic aspect to the limiter which I need to understand.  Thanks for your patience.

     

     

     

  •  

    Rob,

    Now, I know what you're refering to.  Sloa148 is the DRC for TAS57xx,  not for TAS3x, I don't know which chip you're using, I assume though the implementation could be different, the theory behind it is the same.

    The figure you're talking about, x-axis is time, y-axis is the actual gain applied to the signal, i.e. as what you said, the volume, it is the resulting gain after the DRC module.  This is how DRC works: you input a signal, you design a gain curve and you get the final gain based on your signal level and the gain curve and then you apply the gain to the signal and that is the output signal you get after the DRC module either you just want a gain control or a limiter for the signal, it all depends on the gain curve you designed.

    I hope this could help.

    Susan

  • I think I forgot to answer another question of yours. you asked whether the rate of attack really exponential as the drawing suggested.

    Let me try to explain: the final gain is calculated based on the target gain ( the target gain is the gain calculated based on the input signal level and the gain curve) and the attack/decay rate (attack rate is used when the signal is too big and we need to give it attenuation), if the target gain is unchanged during this attacking period, then it would be exponential, but in reality, it's very likely the target gain will change during the period, since the target gain is calculated every sample in TAS3x (or maybe every block of samples on other chips), then it won't show you an exponential curve as the drawing suggetsted.