Reply by Tim Wescott June 16, 20152015-06-16
On Tue, 16 Jun 2015 00:19:55 -0500, Kathy_pdx wrote:

>>Tim Wescott <tim@seemywebsite.com> wrote: >> >>>On Mon, 15 Jun 2015 15:54:46 -0500, Kathy_pdx wrote: >> >>>> It is an IIR filter. Since the EQ coefficients need be upsampled, the >>>> splines linear interpolation is not available since there is no end >>>> point. >>>> Due to the DSP processor constraints, the equalizer design has to be >>>> operated at 16 kHz/s. >> >>>Wait, wait. In your original post you said that the ASIC was equipped > to >>>do equalization, now you're saying that no, the equalization must >>>happen > >>>in the DSP. >> >>>What? >> >>I interpret this to mean that some black box being called "the DSP" is >>constrained to emit a set of filter coefficients computed for a filter >>running at 16 ks/sec, while some other box called "the ASIC" >>is being created to (presumably among other things) use them at 192 >>ks/sec. >> >>Ideally the OP will clarify. >> >>Steve > > Hi, Steve > > You are right. The EQ coefficients were calculated from 16 ks/s data by > DSP and the real EQ operation in 192 ks/s is done in the ASIC. The EQ > coefficients needs be up-sampled from 16 ks/s to 192 ks/s. It is a trade > off between the system complexity and cost in the overall system design.
Oooh, boy. Now, where did I put my portrait of Diogenes of Sinope? I need inspiration for this next bit. If your boss is making you do this, expecting perfection, then brush up your resume. If you're that boss and _your_ boss is competent, then brush up your resume. In the mean time, I would take the equalizer coefficients, reverse- engineer them into their continuous-time equivalents assuming something simple like a bilinear transformation with frequency warping, then forward-engineer them for a sampling rate of 192 ks/s. If you're lucky there's an easy path to doing all of this in one step. I would _not_ expect perfection, but if you're lucky it'll work at least as well as the old equalizer. Ideally the coefficients that are available to you are already separated into 2nd-order transfer functions. When you do all of this, you may wish to double-check that your ASIC has sufficiently wide data paths. You're going up in sampling rate by a factor of 12. If you are using 2nd order filters (you probably are, and they're probably biquads), then the minimum required width of your data paths and coefficient precisions has gone up by a little bit more than 7 bits. That's because the required width increase is roughly proportional to the square of the sampling rate increase, and 12^2 = 144 is closest to 128 = 2^7. -- Tim Wescott Wescott Design Services http://www.wescottdesign.com
Reply by Steve Pope June 16, 20152015-06-16
robert bristow-johnson  <rbj@audioimagination.com> wrote:

>On 6/15/15 2:51 PM, Kathy_pdx wrote:
>> The audio system sample rate is 192 kbits/s. The DSP audio processing >> involves the ASIC hardware and DSP processor. Due to the real-time >> constrains, the equalizer need be implemented at 16 kbits/s by a DSP >> processor. The routine way is to first down sample the audio signal to 16 >> kbits/s, design an equalizer, then apply the equalizer to the audio signal >> at 16 kbits. Then the equalized audio signal is up sampled to 192 kbits/s. >> However, since our system has a ASIC hardware to support the equalizer >> operation at 192 kbits/s, it is more efficient to upsample the equalizer >> coefficients from 16 kbits/s to 192 kbits/s. Is there better way to >> upsample the equalizer coefficients from 16 kbits/s to 192 kbits/s except >> to repeat the equalizer coefficient 12 times?
>it's hard for me to believe that the computational burden of >downsampling, EQing at 16 kHz, and upsampling is less than just EQing at >192 kHz.
I believe the two of your just said the exact same thing. Steve
Reply by robert bristow-johnson June 16, 20152015-06-16
On 6/15/15 2:51 PM, Kathy_pdx wrote:
> The audio system sample rate is 192 kbits/s. The DSP audio processing > involves the ASIC hardware and DSP processor. Due to the real-time > constrains, the equalizer need be implemented at 16 kbits/s by a DSP > processor. The routine way is to first down sample the audio signal to 16 > kbits/s, design an equalizer, then apply the equalizer to the audio signal > at 16 kbits. Then the equalized audio signal is up sampled to 192 kbits/s. > However, since our system has a ASIC hardware to support the equalizer > operation at 192 kbits/s, it is more efficient to upsample the equalizer > coefficients from 16 kbits/s to 192 kbits/s. Is there better way to > upsample the equalizer coefficients from 16 kbits/s to 192 kbits/s except > to repeat the equalizer coefficient 12 times?
it's hard for me to believe that the computational burden of downsampling, EQing at 16 kHz, and upsampling is less than just EQing at 192 kHz. how many bands or what order is your EQ? -- r b-j rbj@audioimagination.com "Imagination is more important than knowledge."
Reply by Marcel Mueller June 16, 20152015-06-16
On 15.06.15 22.54, Kathy_pdx wrote:
> It is an IIR filter. Since the EQ coefficients need be upsampled, the > splines linear interpolation is not available since there is no end point. > Due to the DSP processor constraints, the equalizer design has to be > operated at 16 kHz/s.
You won't get too happy with this EQ, since it is bandwidth limited to about 7,5kHz. The IIR filter at 16 kHz can't process higher frequencies. So you do not have a adjusted response function for higher frequencies. I.e. phone quality. However, you cannot simply upsample IIR coefficients. You need to keep the poles and zeros in place. This is normally a task for a Z transformation. But if your IIR is just a series of biquads (i.e. IIR filters of second order, not more) then it is quite easy. You can calculate the f0 and Q of each stage and calculate the new coefficients at the higher sampling rate from that. Marcel
Reply by Kathy_pdx June 16, 20152015-06-16
>Tim Wescott <tim@seemywebsite.com> wrote: > >>On Mon, 15 Jun 2015 15:54:46 -0500, Kathy_pdx wrote: > >>> It is an IIR filter. Since the EQ coefficients need be upsampled, the >>> splines linear interpolation is not available since there is no end >>> point. >>> Due to the DSP processor constraints, the equalizer design has to be >>> operated at 16 kHz/s. > >>Wait, wait. In your original post you said that the ASIC was equipped
to
>>do equalization, now you're saying that no, the equalization must happen
>>in the DSP. > >>What? > >I interpret this to mean that some black box being called "the DSP" >is constrained to emit a set of filter coefficients computed for >a filter running at 16 ks/sec, while some other box called "the ASIC" >is being created to (presumably among other things) use them at 192 >ks/sec. > >Ideally the OP will clarify. > >Steve
Hi, Steve You are right. The EQ coefficients were calculated from 16 ks/s data by DSP and the real EQ operation in 192 ks/s is done in the ASIC. The EQ coefficients needs be up-sampled from 16 ks/s to 192 ks/s. It is a trade off between the system complexity and cost in the overall system design. Thanks Kathy --------------------------------------- Posted through http://www.DSPRelated.com
Reply by Steve Pope June 15, 20152015-06-15
Tim Wescott  <tim@seemywebsite.com> wrote:

>On Mon, 15 Jun 2015 15:54:46 -0500, Kathy_pdx wrote:
>> It is an IIR filter. Since the EQ coefficients need be upsampled, the >> splines linear interpolation is not available since there is no end >> point. >> Due to the DSP processor constraints, the equalizer design has to be >> operated at 16 kHz/s.
>Wait, wait. In your original post you said that the ASIC was equipped to >do equalization, now you're saying that no, the equalization must happen >in the DSP.
>What?
I interpret this to mean that some black box being called "the DSP" is constrained to emit a set of filter coefficients computed for a filter running at 16 ks/sec, while some other box called "the ASIC" is being created to (presumably among other things) use them at 192 ks/sec. Ideally the OP will clarify. Steve
Reply by Tim Wescott June 15, 20152015-06-15
On Mon, 15 Jun 2015 15:54:46 -0500, Kathy_pdx wrote:

>>On Mon, 15 Jun 2015 13:51:08 -0500, Kathy_pdx wrote: >> >>> The audio system sample rate is 192 kbits/s. >> >>I assume you mean ks/s. >> >>> The DSP audio processing involves the ASIC hardware and DSP processor. >>> Due to the real-time constrains, the equalizer need be implemented at >>> 16 kbits/s by a DSP processor. The routine way is to first down sample >>> the audio signal to 16 kbits/s, design an equalizer, then apply the >>> equalizer to the audio signal at 16 kbits. Then the equalized audio >>> signal is up sampled to > 192 >>> kbits/s. >>> However, since our system has a ASIC hardware to support the equalizer >>> operation at 192 kbits/s, it is more efficient to upsample the > equalizer >>> coefficients from 16 kbits/s to 192 kbits/s. Is there better way to >>> upsample the equalizer coefficients from 16 kbits/s to 192 kbits/s >>> except to repeat the equalizer coefficient 12 times? >> >>The equalizer is a FIR? >> >>There are lots of better ways, of varying degrees of "goodness", but >>what > >>is good depends on what you need. >> >>In the absence of any further information, I suggest that you use >>splines > >>to interpolate the points. That may be too fancy, in which case using >>linear interpolation almost has to be better than just applying a zero- >>order hold. >> >>Best would be to design your equalizer taps for 192ks/s in the first >>place. >> >>PDX = Portland? I'm east of Oregon City. >> >>-- >>www.wescottdesign.com > > Yes, You are right, It should be 16 kHz. My bad. I am in Portland. > PDX=Portland. > > It is an IIR filter. Since the EQ coefficients need be upsampled, the > splines linear interpolation is not available since there is no end > point. > Due to the DSP processor constraints, the equalizer design has to be > operated at 16 kHz/s.
Wait, wait. In your original post you said that the ASIC was equipped to do equalization, now you're saying that no, the equalization must happen in the DSP. What? -- www.wescottdesign.com
Reply by Kathy_pdx June 15, 20152015-06-15
>On Mon, 15 Jun 2015 13:51:08 -0500, Kathy_pdx wrote: > >> The audio system sample rate is 192 kbits/s. > >I assume you mean ks/s. > >> The DSP audio processing >> involves the ASIC hardware and DSP processor. Due to the real-time >> constrains, the equalizer need be implemented at 16 kbits/s by a DSP >> processor. The routine way is to first down sample the audio signal to >> 16 kbits/s, design an equalizer, then apply the equalizer to the audio >> signal at 16 kbits. Then the equalized audio signal is up sampled to
192
>> kbits/s. >> However, since our system has a ASIC hardware to support the equalizer >> operation at 192 kbits/s, it is more efficient to upsample the
equalizer
>> coefficients from 16 kbits/s to 192 kbits/s. Is there better way to >> upsample the equalizer coefficients from 16 kbits/s to 192 kbits/s >> except to repeat the equalizer coefficient 12 times? > >The equalizer is a FIR? > >There are lots of better ways, of varying degrees of "goodness", but what
>is good depends on what you need. > >In the absence of any further information, I suggest that you use splines
>to interpolate the points. That may be too fancy, in which case using >linear interpolation almost has to be better than just applying a zero- >order hold. > >Best would be to design your equalizer taps for 192ks/s in the first >place. > >PDX = Portland? I'm east of Oregon City. > >-- >www.wescottdesign.com
Yes, You are right, It should be 16 kHz. My bad. I am in Portland. PDX=Portland. It is an IIR filter. Since the EQ coefficients need be upsampled, the splines linear interpolation is not available since there is no end point. Due to the DSP processor constraints, the equalizer design has to be operated at 16 kHz/s. --------------------------------------- Posted through http://www.DSPRelated.com
Reply by Steve Pope June 15, 20152015-06-15
Kathy_pdx <59507@DSPRelated> wrote:

>Hi, Steve
>Thanks for your suggestion. I have a preliminary idea how to implement >the upsample of the EQ coefficients.
>The 16 kbis/s EQ coefficients should be first converted to the continuous >time filter by using the inverse bi-linear transform with the sample rate >at 16 kbits/s. After that, the continuous time filter coefficients will be >converted back to the discrete time EQ coefficient with the bi-linear >transform with the sample rate at 192 kbits/s.
This sounds good, if you have the cycles to do it. I'd verify that the resulting magnitude response is flat, or flat-ish, between your high EQ band (somewhat lower than 8 KHz) and 20 KHz, and if not, look for some minimal modification to the coefficients and/or filter that achieves this. Then you're in business. Steve
Reply by Tim Wescott June 15, 20152015-06-15
On Mon, 15 Jun 2015 13:51:08 -0500, Kathy_pdx wrote:

> The audio system sample rate is 192 kbits/s.
I assume you mean ks/s.
> The DSP audio processing > involves the ASIC hardware and DSP processor. Due to the real-time > constrains, the equalizer need be implemented at 16 kbits/s by a DSP > processor. The routine way is to first down sample the audio signal to > 16 kbits/s, design an equalizer, then apply the equalizer to the audio > signal at 16 kbits. Then the equalized audio signal is up sampled to 192 > kbits/s. > However, since our system has a ASIC hardware to support the equalizer > operation at 192 kbits/s, it is more efficient to upsample the equalizer > coefficients from 16 kbits/s to 192 kbits/s. Is there better way to > upsample the equalizer coefficients from 16 kbits/s to 192 kbits/s > except to repeat the equalizer coefficient 12 times?
The equalizer is a FIR? There are lots of better ways, of varying degrees of "goodness", but what is good depends on what you need. In the absence of any further information, I suggest that you use splines to interpolate the points. That may be too fancy, in which case using linear interpolation almost has to be better than just applying a zero- order hold. Best would be to design your equalizer taps for 192ks/s in the first place. PDX = Portland? I'm east of Oregon City. -- www.wescottdesign.com