Forums

ADSP21364: 8kHz sampling rate?

Started by Nicholas January 12, 2006
Hello,

I am running the "talkthru"-example on ADSP21364 EZ-KIT.

The sampling rate is 48kHz.

Is it possible to reconfigure the sampling rate to 8kHz?

Thanks.



"Nicholas" <nicholas@nospam.please> wrote in message 
news:43c638b7$0$67258$157c6196@dreader2.cybercity.dk...
> Hello, > > I am running the "talkthru"-example on ADSP21364 EZ-KIT. > > The sampling rate is 48kHz. > > Is it possible to reconfigure the sampling rate to 8kHz? > > Thanks.
Hello Nicholas: The ADDS-21364-EZLITE is populated with an AD1835 codec. This one is primarily targeted at high quality audio apps (as well as the DSP, too). Reading from its datasheet, it seems like it can only be configured for 48, 96 or 192 kHz sampling rate. Regards, -- Jaime Andres Aranguren Cardona jaac@sanjaac.com SanJaaC Electronics Soluciones en DSP www.sanjaac.com
> > The ADDS-21364-EZLITE is populated with an AD1835 codec. This one is > primarily targeted at high quality audio apps (as well as the DSP, too). > Reading from its datasheet, it seems like it can only be configured for > 48, 96 or 192 kHz sampling rate.
Hi Jaime Appreciate the fast reply. I also read the datasheet for the AD1835A so I guess it's not possible with a 8kHz sample rate. However, I could just downsample the incoming signal to 8kHz, do what ever signal processing I have to do, and then resample the result up to 48kHz, right? The reason that I want to do this is because my algorithm is targeted (designed) for 8kHz signals. Is there a simple way to resample such that the resampled signal x(n) sounds just a nice as the 8kHz processed signal? Interpolating with zeros gives horrible results.
Nicholas wrote:
> > > > The ADDS-21364-EZLITE is populated with an AD1835 codec. This one is > > primarily targeted at high quality audio apps (as well as the DSP, too). > > Reading from its datasheet, it seems like it can only be configured for > > 48, 96 or 192 kHz sampling rate. > > Hi Jaime > > Appreciate the fast reply. > > I also read the datasheet for the AD1835A so I guess it's not possible with > a 8kHz sample rate. > > However, I could just downsample the incoming signal to 8kHz, do what ever > signal processing I have to do, and then resample the result up to 48kHz, > right? > > The reason that I want to do this is because my algorithm is targeted > (designed) for 8kHz signals. > > Is there a simple way to resample such that the resampled signal x(n) sounds > just a nice as the 8kHz processed signal? > > Interpolating with zeros gives horrible results.
Nicolas, the 21365 has on-board sample-rate converters. Check out the manual! Regards, AndoR
I did the following in matlab:

resampled_signal=filtfilt(bbb,aaa,u)

where

[bbb,aaa]=butter(7,0.22)

and 'u' is the upsampled signal (zeros between samples).

It seems that it works fine...

Any problems in this approach??





> Nicolas, the 21365 has on-board sample-rate converters. Check out the > manual! > > Regards, > AndoR
Hi Andor Thanks for the tip. Which manual are you referring to? I am checking out the "talkthru"-example that came along with the board. Is it possible to change some registers or something such that it samples at 8kHz? Cheers, Nico
"Nicholas" <nicholas@nospam.please> wrote in
news:43c6ce62$0$78284$157c6196@dreader1.cybercity.dk: 

>> Nicolas, the 21365 has on-board sample-rate converters. Check out the >> manual! >> >> Regards, >> AndoR > > > Hi Andor > > Thanks for the tip. > > Which manual are you referring to? > > I am checking out the "talkthru"-example that came along with the > board. Is it possible to change some registers or something such that > it samples at 8kHz? > > Cheers, > Nico > > >
No, You could scale the AD183x by changing the MCLK, but I don't remember what's involved. I think you might just need to replace a clock oscillator. The anti-imaging filters will not be optimum and you may see some high frequency clock noise (The AD183x is a sigma delta converter) As I believe Andor mentioned earlier, the ADSP-21364 has very good sample rate converters built in. This is the easiest approach. You could also use one of our dspstak systems. We have boards that include the EZ-Kit debugger (and therefore work like an EZ-Kit). Many of our I/O boards support 8k sampling -- Al Clark Danville Signal Processing, Inc. -------------------------------------------------------------------- Purveyors of Fine DSP Hardware and other Cool Stuff Available at http://www.danvillesignal.com
Nicholas wrote:

   ...
> Interpolating with zeros gives horrible results.
Do you filter adequately after interpolating the zeros? Before downsampling and again after upsampling, you must low-pass to remove energy above 4 KHz. The actual cutoff must be below that. It may be simpler, and will certainly preserve bandwidth better, if you redesign the algorithm. Jerry -- Engineering is the art of making what you want from things you can get. &#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;&#2013266095;
Hi Jerry

> Do you filter adequately after interpolating the zeros?
Yes, in my previous post I wrote that I use the filtfilt-command in matlab.
> It may be simpler, and will certainly preserve bandwidth better, if you > redesign the algorithm.
Yes, but that will take time ....too much time.... Appreciate the advice. Thanks. //Nico
Nicholas wrote:
> > Nicolas, the 21365 has on-board sample-rate converters. Check out the > > manual! > > > > Regards, > > AndoR > > > Hi Andor > > Thanks for the tip. > > Which manual are you referring to?
The manual for the ADSP-21364. You can use its on-board sample-rate converters to convert the 48kHz IO stream to 8kHz for processing in the DSP, ie. you have 48kHz input -> downsample to 8kHz with the SRCs of the 21364 -> process -> upsample the 8kHz stream to 48kHz with the SRCs of the 21364 -> output the 48kHz stream.